ciftify icon indicating copy to clipboard operation
ciftify copied to clipboard

ModuleNotFoundError: No module named 'nibabel.gifti.giftiio'

Open debinz opened this issue 3 years ago • 9 comments

Hi there,

Many thanks for developing this awesome tool. I hope to use this tool to temporal filter my cifti fMRI data, but I found it cannot find the module 'nibabel.gifti.giftiio'. I checked the API info of nibabel (v 5.0.0) on this page: https://nipy.org/nibabel/reference/nibabel.gifti.html, and also did not find this module. Does this tool depend on an older version of nibabel? Can you please provide me with some suggestions to deal with this issue? Thank you very much.

Best regards, Debin

debinz avatar Feb 07 '23 10:02 debinz

Because I tried a .dtseries.nii file, I commented this import line out. However, I still encountered a new error: File PathtothePackage/ciftify/bin/ciftify_clean_img.py, line345, in clean_image_with_nilearn confounds=cofound_signals.values AttributeError: 'NoneType' object has no attribute 'values'

and I found the cofound_signals returned by the mangle_confounds function indeed does not have this attribute. Can you please provide me with some suggestions to deal with this issue? Thank you very much.

Debin

debinz avatar Feb 07 '23 10:02 debinz

Yes, you need an older version of nibabel such as version 3.2.0. The giftiio has been deprecated. See its changelog. https://github.com/nipy/nibabel/blob/504776c504fc8803d15fb444dd077ec91ec4f54d/Changelog

Hi there,

Many thanks for developing this awesome tool. I hope to use this tool to temporal filter my cifti fMRI data, but I found it cannot find the module 'nibabel.gifti.giftiio'. I checked the API info of nibabel (v 5.0.0) on this page: https://nipy.org/nibabel/reference/nibabel.gifti.html, and also did not find this module. Does this tool depend on an older version of nibabel? Can you please provide me with some suggestions to deal with this issue? Thank you very much.

Best regards, Debin

oliver-xie avatar Mar 16 '23 05:03 oliver-xie

Hi, I have the same issue and tried downgrading nibabel to 3.2.0. Then, the nibabel became incompatible with numpy >=1.20 due to type aliases. I tried downgrading numpy but it failed due to other dependencies. I tried both Python 3.8 and 3.9.

Can you provide a working set of requirements?

tiborauer avatar Sep 12 '23 16:09 tiborauer

@tiborauer , have you found a solution? I am running into the same issue with nibabel and then numpy incompatibilities. My environment is using the requirements.txt file given in ./cifitify/ciftify_requirements.txt. A working set of requirements would be great. Thanks!

blahner avatar Nov 03 '23 20:11 blahner

@edickie Thank you very much for this tool! Unfortunately I am running into the same issue mentioned in this thread. Is there a working set of package requirements by any chance? Thanks.

neurodenizen avatar Dec 29 '23 06:12 neurodenizen

Hi, @neurodenizen I had the same issue about "nibabel.gifti.giftiio". But I found this package of an older version containing only two function about reading and writing gifti file. So I change the functions of a new version and it works. import nibabel as nib gft = nib.load(giftiname) gft = nib.save(giftiname, 'new_image.nii.gz')

I hope it can help you.

lijin-coder avatar Jan 02 '24 02:01 lijin-coder

I am also having this problem. On first read the solution posted by @lijin-coder isn't making a lot of sense to me...

vpokorny123 avatar Jul 02 '24 19:07 vpokorny123

Hi all,

Due to the lack of support/development, I decided on another solution based on FreeSurfer and niworkflow. You can check out my implementation in reproanalysis extension.

tiborauer avatar Jul 03 '24 08:07 tiborauer