Questions tagged [neuro-image]

25 questions
8
votes
1 answer

How to convert 3D numpy array to nifti image in nibabel?

From this question How to convert Nifti file to Numpy array? , I created a 3D numpy array of nifti image. I made some modifications to this array, like I changed depth of the array by adding padding of zeroes. Now I want to convert this array back…
Prvt_Yadav
  • 324
  • 1
  • 6
  • 20
4
votes
4 answers

How to get images intensity matrix from Nifti images with Nibabel?

i'm new with NiBabel. I want to know how to get intensity matrix from a Nifti images with this library. I use the following script to get voxels: import nibabel as ni example_img = ni.load('myImage.nii') data = example_img.get_data() I thought at…
chaw359
  • 505
  • 1
  • 5
  • 14
3
votes
2 answers

How can I reduce the number of channels in an MRI (.nii format) image?

I have been trying to feed a dataset of brain MRI images (IXI dataset) to a ConvNet, however, some of the images have 140 channels some others 150 channels. How can I make all the images have the same number of channels so that I won't run into…
2
votes
1 answer

How to Divide Relative Distance into Three Equidistant Regions in MATLAB?

I have two distance maps. One refers to the distance from one point to the outside (starting at 0, ending at a high number reflecting distance from one point). The other is basically equal and opposite (starts at a high number, ends at 0, reflecting…
2
votes
1 answer

How can I reshape a 3D nii gz image array to a 2D?

I have a lot of nii.gz images that I need to reshape from 3D to 2D, I'm trying to use the following code but it's not working due to the nii.gz extension: import nibabel as nib img = nib.load('teste01converted.nii.gz') img.shape newimg =…
1
vote
1 answer

Neuroimage MRI scan CNN model preparation

I would like to know a couple of things to clear my confusion. I want to work on a medical neuroimage MRI image scans dataset from the ADNI database. Each Alzheimer's Disease (AD) MRI image scan has multiple slices. Do I have to separate each image…
1
vote
0 answers

General Linear mode mri data

General Linear model analysis is usually done for fMRI data. I have applied the same analysis to MRI data and found the clusters which are linearly related to columns of behavioral scores(design matrix). I wanted to know if this analysis will give…
1
vote
1 answer

How to create mesh surface from segmentation MRI file using Python and VTK

I have a binary mask of 3D medical images in nifti format, "mask.nii.gz" which I would like to extract surface mesh from. I can load binary mask data into a numpy.ndarray as following import numpy as np import nibabel as nib filePath =…
user1304846
  • 415
  • 2
  • 5
  • 13
1
vote
4 answers

ImportError: No module named 'nilearn'

I'm trying to plot .nii data using nibabel and nilearn. I'm using python 3.5 and installed both packages successfully. But, when I'm trying to import the module, it's returning - ImportError: No module named 'nilearn'. What am I missing here ??
MD. Khairul Basar
  • 4,976
  • 14
  • 41
  • 59
0
votes
0 answers

Combine single .nii files into one 4D .nii file

Is there any possibility to combine many single 3D .nii files into one 4D .nii file using tools in Python? Simply example via Nilearn doesn't work: Reference shape: (64, 64, 35) Image shape: (64, 64, 35, 1)
0
votes
0 answers

Error "File too small" When using spm_slice_vol, Fieldtrip MATLAB

When I was trying to convert a CT scan file's coordinate system into an approximation of the ACPC coordinate system on Fieldtrip MATLAB for a tutorial, there was error prompting that: Warning: Cant get default Analyze orientation - assuming flipped…
0
votes
0 answers

How to extract segmentation data from NIFTI format file in javascript?

I'm dealing with nifti file currently, and I cannot find way to extract segmentation info (or data) from it. I have a {filename}.nii.gz file and read this file with NIFTI-Reader-JS package, render it into html canvas. enter image description…
mckim
  • 1
0
votes
0 answers

Dataset for task fMRI

I can't find any preprocessed dataset for task-fmri on which I can apply dynamic causal modeling (Friston et al. 2003). Does anyone know any dataset (other than the 3 region attention to motion dataset)? Thanks. Most papers use different datasets…
0
votes
0 answers

How can create a 3d model of a brain from a Nifti file

I have to render a 3d model from a nifti file for this I need to convert it into an object file ( wavefront or Mni ). How can I convert a nifti file to an obj file I am using brain browser a javascript library to render the 3d image on the…
0
votes
1 answer

Using aparcstats2table program in Freesurfer to extract the stats data for multiple subjects

I’m trying to extract the statical data for multiple subjects using the aparcstats2table program in freesurfer. I used this command to extract the statical data for one subject. aparcstats2table --subjects…
Ersaa
  • 5
  • 2
1
2