I'm also trying to solve a similar problem. The best way to solve the problem would be change the equations to use a generalized robust Cholesky with pivoting, unluckily, I don't know how to do this to my problem.
But here's a simpler method to convert the matrix to a positive definite one and it seems to be better at reconstructing the original matrix than the one you pointed out:
Test with a matrix that is already positive definite:
Before:
1.00114 0.0015438 0.0055613 0.0083755 0.0114398 0.0271191
0.0015438 1.00209 0.00751505 0.0113179 0.0154588 0.0366463
0.0055613 0.00751505 1.02707 0.0407709 0.0556878 0.132013
0.0083755 0.0113179 0.0407709 1.0614 0.0838676 0.198815
0.0114398 0.0154588 0.0556878 0.0838676 1.11455 0.271555
0.0271191 0.0366463 0.132013 0.198815 0.271555 1.64375
After, using the method you mentioned:
1 0.00154131 0.00548439 0.00812499 0.0108298 0.0211402
0.00154131 1 0.00740762 0.0109742 0.0146276 0.0285536
0.00548439 0.00740762 1 0.039049 0.0520486 0.101601
0.00812499 0.0109742 0.039049 1 0.0771088 0.150519
0.0108298 0.0146276 0.0520486 0.0771088 1 0.200628
0.0211402 0.0285536 0.101601 0.150519 0.200628 1
After using the simpler method:
1.00114 0.0015438 0.0055613 0.0083755 0.0114398 0.0271191
0.0015438 1.00209 0.00751505 0.0113179 0.0154588 0.0366463
0.0055613 0.00751505 1.02707 0.0407709 0.0556878 0.132013
0.0083755 0.0113179 0.0407709 1.0614 0.0838676 0.198815
0.0114398 0.0154588 0.0556878 0.0838676 1.11455 0.271555
0.0271191 0.0366463 0.132013 0.198815 0.271555 1.64375
Test done using C++ Eigen library with double precision.