Skip to content

Dask Array's constant pad coerces array to NumPy ndarray #4842

@jakirkham

Description

@jakirkham

Currently Dask Array's pad (when using the constant mode) may end up coercing array data of a different array type to a NumPy ndarray. For example, the following code will result in a NumPy ndarray.

a_gpu_pad = da.pad(a_gpu, 1, "constant")
a_gpu_pad.compute() 

This still happens if we try to set the constant_values differently. If we provide a 0-D array, we run into issue ( #4841 ).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions