Skip to content

Add f16 support #1550

@swfsql

Description

@swfsql

This is a feature request to add f16 support.
This can be useful for machine learning, including (I believe) for having ndarray with f16 on wasm.

Rust has an f16 primitive (nightly-only), but some crates from the ecosystem use half::f16 -- in which case also offers the half::bf16 also.

Taking a look at how ndarray supports f32 and f64, it appears to easily support it, requiring some minor changes (leaving tests and documentation aside).

I'll try having a draft PR as a showcase, if this gets considered for inclusion.

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