-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ASLPrep hangs when changing dseg datatype #310
Comments
Can you fill in all of the fields of the bug report template? Also, I'm not sure what the traceback you posted refers to. Why did you share that section of the log? Is that the part that ASLPrep gets stuck at? |
hank you very much for your guidance and I have filled in most the fields of the bug report template. Yes, that is the part that ASLPrep gets stuck at and there is no information after that. |
Thank you for the updated info. You are just using Docker directly now, right? Not within a virtual box? Can you update the top comment with the command you used to call ASLPrep as well? |
Thanks for your guidance. Yes, in fact, I ran ASLprep with both the direct call and the virtualbox separately, but both had the same result. |
I think maybe you're referring to the settings in your ASLPrep call. Docker can't be run without any limits, as far as I know. If you open your Docker dashboard, you can go to the Settings page and then go to the Resources tab. You should be able to see how many CPUs, how much memory, and how much swap you've allowed Docker to have. |
Thanks for your guidance. I checked the memory (512GB) and CPU (128) through Docker Info -- format, without any restrictions |
I'm quite stumped then. Are these data shareable? Would you be able to upload the failing data to something like Box or Dropbox and share that with me so I can debug locally? |
https://1drv.ms/u/s!AoMxHEmbgddFreMAx5vtK3nYimtzqQ?e=o2hQzQ
Here is the data, you could test it with confidence
从 Windows 版邮件<https://go.microsoft.com/fwlink/?LinkId=550986>发送
发件人: Taylor ***@***.***>
发送时间: 2023年6月28日 1:41
收件人: ***@***.***>
抄送: ***@***.***>; ***@***.***>
主题: Re: [PennLINC/aslprep] multi-PLD ASL data from GE scans (Issue #310)
I'm quite stumped then. Are these data shareable? Would you be able to upload the failing data to something like Box or Dropbox and share that with me so I can debug locally?
―
Reply to this email directly, view it on GitHub<#310 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AP6RAU7OEFYXOPNMN3HRNLLXNMLN5ANCNFSM6AAAAAAZUFULBE>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Thanks @Luoyu-Wang. I was able to download the data and start debugging. I wasn't able to run ASLPrep all the way through yesterday, but one thing I noticed is that ASLPrep's heuristic to switch between GE-specific processing and general processing uses the number of volumes in the ASL file. Any ASL file with <= 5 volumes is run through the GE processing pipeline, but your data have 6 volumes (5 PLDs, plus the M0 scan), so the general processing pipeline is being called incorrectly. I think I will need to add parameters to explicitly control this behavior (e.g., I don't know for sure that this is causing your problem, since my run didn't stall one the step you reported, but it should help. |
Thanks for your guidance. This error disappeared when I used 3PLD's ASL analysis, but a new errer appeared. Node: aslprep_wf.single_subject_S0001_wf.asl_preproc_asl.compute_cbf_wf.compute_cbf Node inputs: cbf_only = False Traceback (most recent call last): Traceback: |
That makes sense. You must not have modified the |
In fact, I started out using PostLabelingDelay:[1000, 2000, 3000], but ASLprep reported errors before start:
Later I changed PostLabelingDelay to [1000, 2000, 3000, 0], ASLprep can start running, but then it reports an error
|
PostLabelingDelay is in seconds, rather than milliseconds.
It sounds like you missed one or more of the files that need to be modified. You would need to modify However, dropping some PLDs seems like a bad idea. I'm going to merge #313 soon and it will be available via the |
I am very sorry for the error earlier, in fact I was using the unit seconds. I have modified the PostLabelingDelay in JSON to [1,2,3,0], NIFTI contains 3 Δ files and one m0 file, total 4 volumes, aslcontest,tsv I changed to This is the data: Thanks for your patience, in fact I scanned the ASL of 3 PLDs and 7 PLDs respectively, I will test it later and expect good results. |
The unstable version just deployed to DockerHub. Please give that a try with the |
I had a try with the --force-ge option,reoprt the same error also. ValueError: Number of PostLabelingDelays (4) does not match number of delta-M volumes (3). |
Sorry for the confusion. I meant run the new version of ASLPrep with your original data (i.e., without any modifications). The only reason you wanted to modify your dataset, as far as I know, was to trick ASLPrep into using the GE-specific workflow. Since the new ASLPrep version has the I took a quick look at your modified data, although I don't think you should use it because it's not the full data. I noticed that you have an extra |
Thanks for your patient guidance. But similar error was reported:Number of PostLabelingDelays (8) does not match number of delta-M volumes (7). Could the data run in your computer successful? |
I just wanted to add on that I am having the same issue as the original post for single delay, non-GE data. Namely, the processing hangs at the float64 to int16 conversion for the dseg image. Here are the last few outputs:
and the command:
|
@adcohen2 thanks for sharing your traceback. It seems like there are two issues here. The first issue is the hanging problem. It looks like this came up before in fMRIPrep (nipreps/fmriprep#2652 and nipreps/fmriprep#2725). @adcohen2, I'm not sure what causes that problem, but one thing that would be really helpful would be if you could clear out the working directory and re-run your job with The second issue is that there is a bug in ASLPrep when it comes to multi-PLD GE data. I'm working on that and will hopefully have a fix around Wednesday of next week (Monday and Tuesday are holidays for me). I'll probably open a separate issue for this problem so we don't continue to clutter up the hanging issue thread with talk about multi-PLD GE data. |
Per your suggestion, I reran the job with --nprocs 1 --omp-nthreads 1 -vvv.
I can't seem to find an actual crash log or anything. |
Thank you @adcohen2. That's really helpful. It looks like that the hanging problem stemmed from a bug in the motion correction, rather than the datatype conversion step you and @Luoyu-Wang were seeing. I will try to reproduce the problem locally today. |
I think I see the problem. @adcohen2, how many M0 volumes do you have in your dataset? Are they in the ASL file, rather than stored in a separate |
Good news! There is one M0 volume and it is the last volume in the asl file. I have is labeled in the aslcontext.txt file. |
Ah, that makes sense. The issue is that the MCFLIRT interface is returning a string for the single M0 volume that is being motion corrected, rather than a list as expected. This would only arise when there's a single M0 scan inside the ASL file. I will work on a fix today. |
@adcohen2 I think I've fixed the problem. It will probably take about an hour and a half for the updated version to deploy to DockerHub. Once that happens, would you mind pulling the new |
Hi, thank you for updating the code! I encountered the same "stuck forever in dtype change" problem. And I tried the unstable docker version. Good news is that it no longer got stuck on date type change. Bad news is it got stuck later on some "apply_mask" step (or step after that). After I split sub-01_asl.nii.gz into sub-01_asl.nii.gz and sub-01_m0scan.nii.gz, everything went fine. I think this can be a temporary solution before a new version is available. :) |
Hello! we are having the same problem with version 0.4.0 |
@lucsanara please use |
Summary
Thank you very much for your previous guidance. We used the unstable version of ASLPREP to process multi-PLD ASL data from GE scans and found that we got stuck at this step several days, we found the cpu was running very inefficiently(about 3%), while processing single-PLD ASL data normally, what is the reason for this?
Additional details
What were you trying to do?
We used the unstable version of ASLPREP to process multi-PLD ASL data from GE scans
docker run -ti --rm -v /media/sf_data1/wly/ASL/BIDS:/data:ro -v /media/sf_data1/wly/ASL/derivatives:/out:rw -v /media/sf_data1/wly/ASL/wd_temp:/work:rw -v /home/wly/softwares/freesurfer/license.txt:/opt/freesurfer/license.txt -v /home/wly/softwares/templateflow:/home/aslprep/.cache/templateflow/ pennlinc/aslprep:unstable /data /out participant -w /work --ignore fieldmaps --output-spaces MNI152NLin2009cAsym:res-2
What did you expect to happen?
What actually happened?
We got stuck at this step several days, we found the cpu was running very inefficiently(about 3%),
Reproducing the bug
The text was updated successfully, but these errors were encountered: