into: test foo <- CSV

It's a good suggestion and, until yesterday, was perfectly valid :)


On Wed, Aug 13, 2014 at 8:36 AM, Phillip Cloud <notifications@github.com>
wrote:

> In blaze/api/into.py:
>
> > +
> > +
> > +@dispatch((np.ndarray, DataFrame, ColumnDataSource, ctable), DataDescriptor)
> > +def into(a, b, **kwargs):
> > +    return into(a, into(nd.array(), b), **kwargs)
> > +
> > +
> > +@dispatch((np.ndarray, DataFrame, ColumnDataSource, ctable), CSV)
> > +def into(a, b, **kwargs):
> > +    return into(a, into(DataFrame(), b), **kwargs)
> > +
> > +
> > +@dispatch(np.ndarray, CSV)
> > +def into(a, b, **kwargs):
> > +    return into(a, into(DataFrame(), b, **kwargs))
> > +    return np.loadtxt(b.path, dtype=datashape.to_numpy_dtype(b.schema),
>
> ah ok yep sorry, should've looked
> … <#147d00345a513547_>
> -- Best, Phillip Cloud
> On Wed, Aug 13, 2014 at 11:34 AM, Matthew Rocklin <
> notifications@github.com> wrote: In blaze/api/into.py: > + > + > +
> @dispatch <https://github.com/dispatch>((np.ndarray, DataFrame,
> ColumnDataSource, ctable), DataDescriptor) > +def into(a, b, **kwargs): > +
> return into(a, into(nd.array(), b), **kwargs) > + > + > +@dispatch
> <https://github.com/dispatch>((np.ndarray, DataFrame, ColumnDataSource,
> ctable), CSV) > +def into(a, b, **kwargs): > + return into(a,
> into(DataFrame(), b), **kwargs) > + > + > +@dispatch
> <https://github.com/dispatch>(np.ndarray, CSV) > +def into(a, b,
> **kwargs): > + return into(a, into(DataFrame(), b, **kwargs)) > + return
> np.loadtxt(b.path, dtype=datashape.to_numpy_dtype(b.schema), @dispatch
> <https://github.com/dispatch> <https://github.com/dispatch>(np.ndarray,
> DataFrame) def into(a, df): return df.to_records(index=False) …
> <#147d001efc2ca10d_> On Wed, Aug 13, 2014 at 8:32 AM, Phillip Cloud <
> notifications@github.com> wrote: In blaze/api/into.py: > + > + > +
> @dispatch <https://github.com/dispatch> <
> https://github.com/dispatch>((np.ndarray, DataFrame, ColumnDataSource,
> ctable), DataDescriptor) > +def into(a, b, **kwargs): > + return into(a,
> into(nd.array(), b), **kwargs) > + > + > +@dispatch
> <https://github.com/dispatch> <https://github.com/dispatch>((np.ndarray,
> DataFrame, ColumnDataSource, ctable), CSV) > +def into(a, b, **kwargs): > +
> return into(a, into(DataFrame(), b), **kwargs) > + > + > +@dispatch
> <https://github.com/dispatch> <https://github.com/dispatch>(np.ndarray,
> CSV) > +def into(a, b, **kwargs): > + return into(a, into(DataFrame(), b,
> **kwargs)) > + return np.loadtxt(b.path,
> dtype=datashape.to_numpy_dtype(b.schema), also i think the into(ndarray,
> DataFrame) calls values whereas here you would want a recarray — Reply to
> this email directly or view it on GitHub <
> https://github.com/ContinuumIO/blaze/pull/465/files#r16182698>. — Reply
> to this email directly or view it on GitHub <
> https://github.com/ContinuumIO/blaze/pull/465/files#r16182882>.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/ContinuumIO/blaze/pull/465/files#r16183164>.
>