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

is there any defined function that reads locally stored data or is all downloaded? I refer to nii or nifti files #1382

Closed
Dimitrievici opened this Issue Nov 26, 2017 · 4 comments

Comments

Projects
None yet
3 participants
@Dimitrievici

Dimitrievici commented Nov 26, 2017

Description

[Please provide a general introduction to the issue/proposal.]

[If reporting a bug, attach the entire traceback from Python and follow the way to reproduce below]
[If proposing an enhancement/new feature, provide links to related articles, reference examples, etc.]

Way to reproduce

[If reporting a bug, please include the following important information:]

  • Code example
  • Relevant images (if any)
  • Operating system and version (run python -c "import platform; print(platform.platform())")
  • Python version (run python -c "import sys; print("Python", sys.version)")
  • dipy version (run python -c "import dipy; print(dipy.__version__)")
  • dependency version (numpy, scipy, nibabel, h5py, cvxpy, vtk)
    • import numpy; print("NumPy", numpy.version)
    • import scipy; print("SciPy", scipy.version)
    • import nibabel; print("Nibabel", nibabel.version)
    • import h5py; print("H5py", h5py.version)
    • import cvxpy; print("Cvxpy", cvxpy.version)
    • import vtk; print(vtk.vtkVersion.GetVTKSourceVersion())

@Dimitrievici Dimitrievici changed the title from is there any defined function that reads locally stored data or is all downloaded? to is there any defined function that reads locally stored data or is all downloaded? I refer to nii or nifti files Nov 26, 2017

@arokem

This comment has been minimized.

Member

arokem commented Nov 26, 2017

@skoudoro

This comment has been minimized.

Member

skoudoro commented Nov 26, 2017

As @arokem said, Nibabel is a good call with more option, otherwise you can use :

from dipy.io.image import load_nifti, save_nifti

arr = load_nifti('/path/to/my_image.nii')

more info with dipy here

@skoudoro

This comment has been minimized.

Member

skoudoro commented Nov 28, 2017

Does it resolve your problem @Dimitrievici ?

@skoudoro

This comment has been minimized.

Member

skoudoro commented Jan 15, 2018

I'll close this for now, but feel free to reopen if you any other problem!

@skoudoro skoudoro closed this Jan 15, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment