GT-EmoryMINDlab/rodent-whole-brain-preprocessing-recipe

Unary Operator error

Closed this issue · 6 comments

Hi
I tried running my data set on the second script, and the following error was encountered.

./preproc_script_mouse2.sh: line 250: [: -eq: unary operator expected

Parse error: bad expression
:1

Is this something to worry about or does it change the final results? Is this bash-specific?
Please let me know
Thanks
Ned

Could you please inform which step this error occurs?
Another thing you might wanna check: If you use your own atlas, you will need to build your own template as well. Does your atlas match the template you built?

Thanks for your reply. I was able to figure it out (it was because of some alignment issue). I am running this on hamster brain, I do have hamster atlas and t2 image files and I am generating EPI hamster template from t2 file.

One quick question, I get these warnings when I run script 2, (I think this is because of type of data I used and orientation)
Is there anything to worry about, I simply just ignore them.

WARNING:: Inconsistent orientations for individual images in pipeline!
Will use voxel-based orientation which is probably incorrect - PLEASE CHECK!

*+ WARNING: If you are performing spatial transformations on an oblique dset,
such as /Volumes/2TBSSD/EmoryPairWiseAnalysis/Hamsters_RAS/data_hamster1/EPI_n4_mask.nii.gz,
or viewing/combining it with volumes of differing obliquity,
you should consider running:
3dWarp -deoblique

*+ WARNING: Input dataset ./data_hamster1/EPI_nuisance_brain.nii.gz grid mismatch from mask.

** WARNING: NIfTI file /Volumes/2TBSSD/EmoryPairWiseAnalysis/Hamsters_RAS/lib/tmp_hamster_128/hamsterEPIatlas.nii dimensions altered since AFNI extension was added

Glad that you figured that out!

The orientation issue is alarming. I would check the alignment/orientation of the atlas&template&t2 on fsleyes to make sure they have the same orientation. I think the following warnings might be all due to this misorientation issue:

  • WARNING:: Inconsistent orientations for individual images in pipeline!
    *+ WARNING: Input dataset ./data_hamster1/EPI_nuisance_brain.nii.gz grid mismatch from mask.

You could ignore this for now:
*+ WARNING: If you are performing spatial transformations on an oblique dset,
such as /Volumes/2TBSSD/EmoryPairWiseAnalysis/Hamsters_RAS/data_hamster1/EPI_n4_mask.nii.gz,
or viewing/combining it with volumes of differing obliquity,
you should consider running:
3dWarp -deoblique

This warning means your atlas and EPI template don't have the same resolution/dimension. For this, you need to double-check with your t2 and atlas files.
** WARNING: NIfTI file /Volumes/2TBSSD/EmoryPairWiseAnalysis/Hamsters_RAS/lib/tmp_hamster_128/hamsterEPIatlas.nii dimensions altered since AFNI extension was added

Yes, I did check both atlas, t2 and my func data and aligned them manually as well as in RAS orientation.

Only issue could be, my atlas was in high resolution and I downsampled it to match your rat atlas file. However, I was able to get a decent seed correlation matrix. Thanks for your suggestions.