What I meant here is that ones () is missing the dtype argument that is present on the previous lines.




Lähetetty Samsungin tablettitietokoneesta

-------- Alkuperäinen viesti --------
Lähettäjä: Blake Griffith <notifications@github.com> 
Päivämäärä: 13.06.2013  8.52  (GMT+02:00) 
Saaja: scipy/scipy <scipy@noreply.github.com> 
Kopio: Pauli Virtanen <pav@iki.fi> 
Aihe: Re: [scipy] Sum mean dtype (#2549) 
 
In scipy/sparse/base.py:

>          elif axis is None:
>              # sum over rows and columns
> -            return (self * np.asmatrix(np.ones((n, 1), dtype=self.dtype))).sum()
> +            res = (self * np.asmatrix(np.ones((n, 1)))).sum()
I don't think so. We are trying to mimic NumPy's .sum() dtype behavior, and here we are calling NumPy's .sum() on a matrix that should be the same dtype as self.dtype.

—
Reply to this email directly or view it on GitHub.