Skip to content

Deprecation error #36

@araikes

Description

@araikes

I'm using the Docker image (via singularity) for v0.1.4 and am attempting to write fixel stats and get the following:

singularity exec --containall -B $PWD:$PWD /groups/adamraikes/singularity_images/modelarray_confixel_0.1.4.sif fixelstats_write --index-file fixel_stats/fd_smooth/index.mif --directions-file fixel_stats/fd_smooth/directions.mif --cohort-file modelarray_inputs/full_dataset_fd.csv --relative-root $PWD --input-hdf5 modelarray_output/interaction_models/full_dataset_fd.h5 --output-dir modelarray_output/interaction_models/full_dataset_fd --analysis-name results
WARNING: Output directory exists
Traceback (most recent call last):
  File "/usr/local/bin/fixelstats_write", line 8, in <module>
    sys.exit(h5_to_fixels())
  File "/usr/local/lib/python3.8/dist-packages/confixel/fixels.py", line 306, in h5_to_fixels
    h5_to_mifs(example_mif, h5_input, analysis_name, out_fixel_dir)
  File "/usr/local/lib/python3.8/dist-packages/confixel/fixels.py", line 247, in h5_to_mifs
    nifti2_img, _ = mif_to_nifti2(example_mif)
  File "/usr/local/lib/python3.8/dist-packages/confixel/fixels.py", line 45, in mif_to_nifti2
    data = nifti2_img.get_data().squeeze()
  File "/usr/local/lib/python3.8/dist-packages/nibabel/deprecator.py", line 185, in deprecated_func
    raise error_class(message)
nibabel.deprecator.ExpiredDeprecationError: get_data() is deprecated in favor of get_fdata(), which has a more predictable return type. To obtain get_data() behavior going forward, use numpy.asanyarray(img.dataobj).

Only index.mif and directions.mif are written to the output folder.

EDIT: Outputs are created using v0.1.3. Also, this error does not occur for volumestats_write

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions