.IDX file

29 views
Skip to first unread message

Patryk Filipiak

unread,
Jun 16, 2021, 11:22:51 AM6/16/21
to DSI Studio
Hello,

I recently updated my copy of DSI Studio (by compiling the source code on Ubuntu) and noticed that it produces an auxiliary .idx file each time I open a .fib.gz file. Here's a scenario when this leads to a program crash:

(1) I generate a .fib.gz file using an external software.
(2) I open this .fib.gz file in DSI Studio, which results in creating an .idx file.
(3) Coming back to the external software, I generate a new .fib.gz file and save it under the same name.
(4) DSI Studio crashes, when I try to open this new .fib.gz file (unless I manually remove the .idx file).

This could be fixed, if DSI Studio verified which file is newer: .fib.gz or .idx. 
If .fib.gz file is newer then the .idx file, this means that the .idx file should be regenerated.

Best,
Patryk

Frank Yeh

unread,
Jun 16, 2021, 12:13:55 PM6/16/21
to dsi-s...@googlegroups.com
Thanks for reporting this problem.
Is it possible to send me a sample of fib.gz and idx file to fix this bug?

Best regards,
Frank
> --
> You received this message because you are subscribed to the Google Groups "DSI Studio" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to dsi-studio+...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/dsi-studio/99f924e6-2c57-479c-a482-e7d40a783d34n%40googlegroups.com.

Patryk Filipiak

unread,
Jun 17, 2021, 11:21:35 AM6/17/21
to DSI Studio
Hi again,

I managed to reproduce something similar on the HCP data. I've just sent you two ZIP archives via Dropbox.

First one (before.zip) contains a fib.gz file and the corresponding .idx file produced right after opening this .fib.gz in DSI Studio.
Meanwhile, I modified this .fib.gz file using external software and saved the changes under the same name. The archive "after.zip" contains this modified .fib.gz file and the same .idx file generated before by DSI Studio. When I try to open the modified .fib.gz file in DSI Studio, it looks like all the ODF peaks were facing in the same direction (see: peak_dirs.png).

I told you yesterday that DSI Studio crashes in such scenarios. It happens with other datasets which I sadly cannot share, but the thing that happened with HCP data is probably caused by the same mechanism. Note that when you remove the .idx file and open the modified .fib.gz, DSI Studio will produce new .idx file, for which all will be fine, so it's just a matter of checking which of these two files is newer (.fib.gz or .idx). If .fib.gz is newer then its corresponding .idx, then the .idx should be regenerated before opening.

Best,
Patryk

Frank Yeh

unread,
Jun 17, 2021, 12:11:51 PM6/17/21
to dsi-s...@googlegroups.com
Thanks a lot. I will see if I can come up with a solution to avoid this problem.
In the meantime, the only solution is to manually remove IDX so that
DSI Studio won't use it to speed up the gz file readings.
Best regards,
Frank
> To view this discussion on the web visit https://groups.google.com/d/msgid/dsi-studio/4dbdbca3-b63b-41fd-b5cc-2b8ff5f79f12n%40googlegroups.com.

Frank Yeh

unread,
Jun 23, 2021, 4:10:52 PM6/23/21
to dsi-s...@googlegroups.com
Hi Patryk,

I have checked and tested the file.

Unfortunately, there is no way to tell whether the idx has a
mismatch problem. I am afraid that the only solution is to delete idx
every time a new FIB is generated.

Hopefully, this won't cause too much trouble.

Best regards,
Frank
> To view this discussion on the web visit https://groups.google.com/d/msgid/dsi-studio/4dbdbca3-b63b-41fd-b5cc-2b8ff5f79f12n%40googlegroups.com.

Patryk Filipiak

unread,
Jun 23, 2021, 4:23:28 PM6/23/21
to DSI Studio
Hi Frank,

Thanks for coming back. OK, I'll keep deleting the IDX file on my side.

If you ever decide to give this issue another shot, you can do the classic trick that I suggested before. Since IDX file is derived from FIB file, then the file system modification date of IDX must always be newer than the FIB file's one:

Best,
Patryk

Frank Yeh

unread,
Jun 23, 2021, 4:30:13 PM6/23/21
to dsi-s...@googlegroups.com
This is brilliant.
I am implementing it now.
Frank
> To view this discussion on the web visit https://groups.google.com/d/msgid/dsi-studio/ba49e72e-005a-4688-824f-32762ca965bcn%40googlegroups.com.

Frank Yeh

unread,
Jun 23, 2021, 4:45:47 PM6/23/21
to dsi-s...@googlegroups.com
I have updated DSI Studio. The windows version and Github(Linux) is updated
If you are using Mac, please let me know. I will commit the update sooner.

Thanks a lot for the suggestion!
When you mentioned "checking which file is newer" in the first reply,
somehow I did not catch the idea (I was staying up too late that day).
Hope the update handles the issue.

Much appreciate your help!
Frank

Patryk Filipiak

unread,
Jun 23, 2021, 4:54:34 PM6/23/21
to DSI Studio
Thanks for reacting so fast! I'm using Linux, so it's OK.
Have a great day,
Patryk

Reply all
Reply to author
Forward
0 new messages