Skip to content

.all() and .any() fail for arrays of type 'S' and 'U' (Trac #1314) #1912

Closed
@thouis

Description

@thouis

Original ticket http://projects.scipy.org/numpy/ticket/1314 on 2009-12-07 by @mdboom, assigned to unknown.

In [3]: x = np.array(['abc', 'def', ''], 'S')

In [4]: x.all()
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)

/wonkabar/data1/builds/betadrizzle/<ipython console> in <module>()

TypeError: cannot perform reduce with flexible type

This is a sensible operation. I wonder if there's a way to make it work.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions