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

A generally applicable whole-brain preprocessing toolbox for mice and rats
https://doi.org/10.52294/001c.85075
GNU General Public License v3.0
7 stars 3 forks source link

Unary Operator error #14

Closed nmskhan closed 1 year ago

nmskhan commented 1 year ago

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
imnanxu commented 1 year ago

Hi, please strictly follow the manual to specify the parameters to avoid such errors.Sent from my iPhoneOn Aug 27, 2023, at 12:11 PM, nmskhan @.***> wrote: 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

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.***>

nmskhan commented 1 year ago

Hi Thank you for your quick reply. I am strictly following the manual. Only issue I have, I am using my own atlas. This could be the reason for the error. The script does not give any errors for the sample data you provided. Thanks Ned

On Aug 27, 2023, at 12:35 PM, Nan Xu @.***> wrote:

Hi, please strictly follow the manual to specify the parameters to avoid such errors.Sent from my iPhoneOn Aug 27, 2023, at 12:11 PM, nmskhan @.***> wrote: 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

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.***> — Reply to this email directly, view it on GitHub https://github.com/imnanxu/rodent-whole-brain-preprocessing-recipe/issues/14#issuecomment-1694709601, or unsubscribe https://github.com/notifications/unsubscribe-auth/AI3HO4C5HIRRNRQCDONJH4TXXNZMJANCNFSM6AAAAAA4AM6IR4. You are receiving this because you authored the thread.

imnanxu commented 1 year ago

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?

nmskhan commented 1 year ago

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

imnanxu commented 1 year ago

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:

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

nmskhan commented 1 year ago

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.