Yes, we cannot use SphHarmFit because the csd is based on single voxel data
(uses your multivoxel decorator).
On Jun 7, 2013 2:44 PM, "MrBago" <notifications@github.com> wrote:

> In dipy/reconst/csdeconv.py:
>
> > +        # scale lambda to account for differences in the number of
> > +        # SH coefficients and number of mapped directions
> > +
> > +        self.Lambda = Lambda * self.R.shape[0] * r_rh[0] / self.B_regul.shape[0]
> > +        self.tau = 0.1
> > +        self.sh_order = sh_order
> > +
> > +    def fit(self, data):
> > +        s_sh = np.linalg.lstsq(self.B_dwi, data[self._where_dwi])[0]
> > +        shm_coeff, num_it = csdeconv(s_sh, self.sh_order, self.R, self.B_regul, self.Lambda, self.tau)
> > +        return ConstrainedSphericalDeconvFit(self, shm_coeff)
> > +
> > +
> > +class ConstrainedSphericalDeconvFit(OdfFit):
> > +
> > +    def __init__(self, model, fodf_sh):
>
> Is there any reason not to use SphHarmFit here? It seems like it could be
> a drop in replacement, or at least a subclass. That way this fit class
> would benefit from updates to SphHarmFit, for example the new gfa method.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/nipy/dipy/pull/173/files#r4594560>
> .
>