[Simnibs-discuss] Error value “axes don't match array”
Schutter, D.J.L.G. (Dennis)
d.j.l.g.schutter at uu.nl
Wed Apr 21 22:07:58 CEST 2021
First of all, thank you for the amazing program.
I am struggling with creating a mesh (using headreco all) based on a NIFTI file that I converted from DICOM (with dicm2nii). While the first steps few steps in Matlab run successful, I get the error value “axes don't match array” at the start of Binarizing tissue probability maps and program terminates (see below for complete message). When I run headreco all with Ernie’s NIFTI file the headreco all it works fine, so I guess something went wrong with the conversion, but I cannot put my finger on the problem. The scan is a standard 3T scan: voxel dimensions: 1x1x1mm and image (XYZ) dimensions: 192x256x256, and the NIFTI scan looks fine in MRICRO and MANGO.
I hope you can help me. Thank you very much for your valuable time and I look forward to hearing from you.
Binarizing tissue probability maps
Creating unity.xfm and ref_FS.nii.gz
Traceback (most recent call last):
File "C:\Users\schut103\SimNIBS-3.2\simnibs_env\lib\site-packages\simnibs\cli\headreco.py", line 13, in <module>
File "C:\Users\schut103\SimNIBS-3.2\simnibs_env\lib\site-packages\simnibs\cli\headreco.py", line 10, in main
File "C:\Users\schut103\SimNIBS-3.2\simnibs_env\lib\site-packages\simnibs\msh\headreco.py", line 286, in headmodel
File "C:\Users\schut103\SimNIBS-3.2\simnibs_env\lib\site-packages\simnibs\msh\hmutils.py", line 3454, in write_ref_fs
data = np.transpose(np.zeros_like(vol.get_data()),(0,2,1))
File "C:\Users\schut103\SimNIBS-3.2\simnibs_env\lib\site-packages\numpy\core\fromnumeric.py", line 639, in transpose
return _wrapfunc(a, 'transpose', axes)
File "C:\Users\schut103\SimNIBS-3.2\simnibs_env\lib\site-packages\numpy\core\fromnumeric.py", line 56, in _wrapfunc
return getattr(obj, method)(*args, **kwds)
ValueError: axes don't match array
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Simnibs-discuss