Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

__array_namespace_info__ returns complex128 dtype when no fp64 #1977

Copy link
Copy link
@antonwolfy

Description

@antonwolfy
Issue body actions

It seems dpctl only checks if float64 is supported based on device capabilities when building a dictionary of all Array API data types:

import dpctl, dpctl.tensor as dpt

dpctl.__version__
# Out: '0.19.0dev0+480.g360ce45dc6'

info = dpnp.__array_namespace_info__()
info.dtypes()
# Out:
# {'bool': dtype('bool'),
#  'float32': dtype('float32'),
#  'complex64': dtype('complex64'),
#  'complex128': dtype('complex128'),
#  'int8': dtype('int8'),
#  'int16': dtype('int16'),
#  'int32': dtype('int32'),
#  'int64': dtype('int64'),
#  'uint8': dtype('uint8'),
#  'uint16': dtype('uint16'),
#  'uint32': dtype('uint32'),
#  'uint64': dtype('uint64')}

# no fp64 support by default device:
dpctl.select_default_device().has_aspect_fp64
# Out: False

As a result float64 is filtered out but complex128 is present in the output dictionary, which looks faulty.

Reactions are currently unavailable

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.