I have encounterd errors while running NODDI_mod_watson.fit,
Here is the error
NODDI_fit_watson = NODDI_mod_watson.fit(gtab_dmipy, data, mask=mask)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/core/modelingframework.py", line 1201, in fit
self, self.scheme, x0, Ns, N_sphere_samples)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/optimizers/brute2fine.py", line 76, in init
model, x0vector, Ns, N_sphere_samples)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/optimizers/brute2fine.py", line 168, in precompute_signal_grid
self.acquisition_scheme, self.parameter_grid)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/core/modeling_framework.py", line 1300, in simulate_signal
E_2d[i] = self(acquisition_scheme, parameters)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/core/modeling_framework.py", line 1370, in call
acquisition_scheme_or_vertices, parameters))
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distribute_models.py", line 390, in call
return self.sh_convolved_model(acquisition_scheme, kwargs)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distribute_models.py", line 482, in sh_convolved_model
distribution_parameters)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distributions.py", line 149, in spherical_harmonics_representation
watson_sf = self(hemisphere.vertices, mu=mu, odi=odi)
File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distributions.py", line 123, in call
mu_cart = utils.unitsphere2cart_1d(mu)
TypeError: expected dtype object, got 'numpy.dtype[float64]'
I have numpy=1.21.1 installed. The scripts ran fine using numpy< 1.18.0
It seems that API change in numpy has caused this issue, see
https://github.com/numba/numba/issues/6041
I wonder if you plan to upgrade dmipy for the current version of numpy.
Hi Rutger,
I have encounterd errors while running NODDI_mod_watson.fit,
Here is the error
NODDI_fit_watson = NODDI_mod_watson.fit(gtab_dmipy, data, mask=mask) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/core/modelingframework.py", line 1201, in fit self, self.scheme, x0, Ns, N_sphere_samples) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/optimizers/brute2fine.py", line 76, in init model, x0vector, Ns, N_sphere_samples) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/optimizers/brute2fine.py", line 168, in precompute_signal_grid self.acquisition_scheme, self.parameter_grid) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/core/modeling_framework.py", line 1300, in simulate_signal E_2d[i] = self(acquisition_scheme, parameters) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/core/modeling_framework.py", line 1370, in call acquisition_scheme_or_vertices, parameters)) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distribute_models.py", line 390, in call return self.sh_convolved_model(acquisition_scheme, kwargs) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distribute_models.py", line 482, in sh_convolved_model distribution_parameters) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distributions.py", line 149, in spherical_harmonics_representation watson_sf = self(hemisphere.vertices, mu=mu, odi=odi) File "/home/yehp/anaconda3/lib/python3.7/site-packages/dmipy/distributions/distributions.py", line 123, in call mu_cart = utils.unitsphere2cart_1d(mu) TypeError: expected dtype object, got 'numpy.dtype[float64]'
I have numpy=1.21.1 installed. The scripts ran fine using numpy< 1.18.0 It seems that API change in numpy has caused this issue, see https://github.com/numba/numba/issues/6041
I wonder if you plan to upgrade dmipy for the current version of numpy.
Thank you. Ping