Skip to content
This repository was archived by the owner on Nov 17, 2023. It is now read-only.
This repository was archived by the owner on Nov 17, 2023. It is now read-only.

Ndarray construction can't import zero-dimensional numpy arrays #12672

@arogozhnikov

Description

@arogozhnikov

Description

See example below

Environment info (Required)

Ubuntu 18, python 3.6, pip-installed CPU-only version
MXNet 1.3.0

Minimum reproducible example

mxnet.ndarray.array( numpy.arange(1).reshape([1, 1, 1]) ) # ok
mxnet.ndarray.array( numpy.arange(1).reshape([1, 1]) ) # ok
mxnet.ndarray.array( numpy.arange(1).reshape([1]) ) # ok
mxnet.ndarray.array( numpy.arange(1).reshape([]) )
# last one fails: ValueError: Shape inconsistent: expected () vs got (1,)

MXNet does support zero-dimensional arrays, so this is the problem of importing.

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