Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

concat() loads dask arrays if the first array is numpy #1588

Closed
crusaderky opened this issue Sep 24, 2017 · 0 comments
Closed

concat() loads dask arrays if the first array is numpy #1588

crusaderky opened this issue Sep 24, 2017 · 0 comments

Comments

@crusaderky
Copy link
Contributor

crusaderky commented Sep 24, 2017

duck_array_ops.concatenate and duck_array_ops.stack load dask variables if the first one is numpy-based:

xarray.concat([
    xarray.DataArray([1]).chunk(),
    xarray.DataArray([1]),
], dim='dim_0')

Out[1]:
<xarray.DataArray (dim_0: 2)>
dask.array<shape=(2,), dtype=int64, chunksize=(1,)>
Dimensions without coordinates: dim_0

xarray.concat([
    xarray.DataArray([1]),
    xarray.DataArray([1]).chunk(),
], dim='dim_0')

Out[2]:
<xarray.DataArray (dim_0: 2)>
array([1, 1])
Dimensions without coordinates: dim_0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant