Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

ml_dtypes

Unittests Wheel Build PyPI version

This is not an officially supported Google product.

ml_dtypes is a stand-alone implementation of several NumPy dtype extensions used in machine learning libraries, including:

  • bfloat16: an alternative to the standard float16 format
  • float8_*: several experimental 8-bit floating point representations including:
    • float8_e4m3b11
    • float8_e4m3fn
    • float8_e5m2

Installation

We will soon release pre-built wheels for this package at http://pypi.org/project/ml-dtypes, so this package can be easily pip installed.

To build locally, clone the repository and run:

$ git submodule init
$ git submodule update
$ pip install .

Example Usage

>>> from ml_dtypes import bfloat16
>>> import numpy as np
>>> np.zeros(4, dtype=bfloat16)
array([0, 0, 0, 0], dtype=bfloat16)

Importing ml_dtypes also registers the data types with numpy, so that they may be referred to by their string name:

>>> np.dtype('bfloat16')
dtype(bfloat16)
>>> np.dtype('float8_e5m2')
dtype(float8_e5m2)

Metadata

Release files for ml-dtypes 0.0.2rc4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ml-dtypes 0.0.2rc4
File Size Uploaded
ml_dtypes-0.0.2rc4.tar.gz 682.9 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for ml-dtypes 0.0.2rc4
File
ml_dtypes-0.0.2rc4-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
ml_dtypes-0.0.2rc4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
ml_dtypes-0.0.2rc4-cp311-cp311-macosx_10_9_universal2.whl CPython 3.11 CPython 3.11 macOS 10.9+ universal2 (ARM64, x86-64) Details
ml_dtypes-0.0.2rc4-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
ml_dtypes-0.0.2rc4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
ml_dtypes-0.0.2rc4-cp310-cp310-macosx_10_9_universal2.whl CPython 3.10 CPython 3.10 macOS 10.9+ universal2 (ARM64, x86-64) Details
ml_dtypes-0.0.2rc4-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
ml_dtypes-0.0.2rc4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details
ml_dtypes-0.0.2rc4-cp39-cp39-macosx_10_9_universal2.whl CPython 3.9 CPython 3.9 macOS 10.9+ universal2 (ARM64, x86-64) Details
ml_dtypes-0.0.2rc4-cp38-cp38-win_amd64.whl CPython 3.8 CPython 3.8 Windows x86-64 Details
ml_dtypes-0.0.2rc4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.8 CPython 3.8 Linux glibc 2.17+ x86-64 Details
ml_dtypes-0.0.2rc4-cp38-cp38-macosx_10_9_universal2.whl CPython 3.8 CPython 3.8 macOS 10.9+ universal2 (ARM64, x86-64) Details

Total release size: 3.4 MB

Release files / ml_dtypes-0.0.2rc4.tar.gz

Download URL ml_dtypes-0.0.2rc4.tar.gz
Size 682.9 kB
Tags Source
SHA-256 checksum
How to use checksums
2cfefe779e06ffaa330ae1d1e2ac1fbf3cef92206d0bd821fe4e651904bd8bed
BLAKE2b-256 checksum
How to use checksums
70d62207f173eeeae2adedffddbd46dda2f310f2bae86463f5ca75b6796036ef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp311-cp311-win_amd64.whl

Download URL ml_dtypes-0.0.2rc4-cp311-cp311-win_amd64.whl
Size 135.4 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
01529520c5382abb9abfcb5ea0fb57529f9b43bd2b7fc279078de60f5c26f3cf
BLAKE2b-256 checksum
How to use checksums
5337735ea2edf931790c86bfd7d00e7e3d7e5c17727cacef69c093659e9a9aaf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL ml_dtypes-0.0.2rc4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 231.0 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
212009a3f90e729a6a2852986549482425c3d5e271d9f5892ed5cbe8271bc9df
BLAKE2b-256 checksum
How to use checksums
625f16ce60b790a3c63215d50222a8b8ebf3772f8e3631076320661f422824d8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp311-cp311-macosx_10_9_universal2.whl

Download URL ml_dtypes-0.0.2rc4-cp311-cp311-macosx_10_9_universal2.whl
Size 312.0 kB
Tags CPython 3.11 macOS 10.9+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
b4d1d9863cea3794e7b6c46a9c67c12fef4f357398921e581722b8994f62290b
BLAKE2b-256 checksum
How to use checksums
081cf712baee9c938a4f95ac8ab4f3cbc9aa3c3a4fb00a1d49531764b1d34368
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp310-cp310-win_amd64.whl

Download URL ml_dtypes-0.0.2rc4-cp310-cp310-win_amd64.whl
Size 135.5 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
9246a5e42dfaa64d015d21d48101f503e63b335ba3f6f51973a3ef9d6bf9361a
BLAKE2b-256 checksum
How to use checksums
23d117dc1bb41836f6e4743e18cd7a4c2ce35ad50edaa8f7fd901bd685669d47
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL ml_dtypes-0.0.2rc4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 231.0 kB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
517c4496007a200766f625f9a693f67c0e3ad28b79d54ab67f4b6ec5b6b3278c
BLAKE2b-256 checksum
How to use checksums
4cb9687ec6525a0616175255a4a43f24c38431aaf0ba3f7c579298dd07ba33dd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp310-cp310-macosx_10_9_universal2.whl

Download URL ml_dtypes-0.0.2rc4-cp310-cp310-macosx_10_9_universal2.whl
Size 312.0 kB
Tags CPython 3.10 macOS 10.9+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
d12e05ff0ce313d4141ed49124a09d7a216d21957751adbf08f1054adce13d0a
BLAKE2b-256 checksum
How to use checksums
910ee2fa1b233205ca51b69154fc95ff381a09872c3653036cf30e607f1f0d2e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp39-cp39-win_amd64.whl

Download URL ml_dtypes-0.0.2rc4-cp39-cp39-win_amd64.whl
Size 135.4 kB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
a7b10caf83c652be1bb6d24f1a87ba69a433d23a98115df9a528d9a117257d7a
BLAKE2b-256 checksum
How to use checksums
449389343aca4e62a4d4c03256d9e167a719e3bfe15f501e88346b95c17b78f9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL ml_dtypes-0.0.2rc4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 231.1 kB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
c4ef24f64d62a63253a71b9ba848b4a4f15d5147a94db854d7e831fe570d2e64
BLAKE2b-256 checksum
How to use checksums
7a2df075e12882dd460126ec0318a77f70b1ddcca110b4887a74778b22b0c03c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp39-cp39-macosx_10_9_universal2.whl

Download URL ml_dtypes-0.0.2rc4-cp39-cp39-macosx_10_9_universal2.whl
Size 312.5 kB
Tags CPython 3.9 macOS 10.9+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
f99616f3304aaaf02ebe9b6912e4adf16b0e3364f35cb9df592617331744f773
BLAKE2b-256 checksum
How to use checksums
861f414656b9a29b094e4cbd1545b8a773e6eee99374188bb3570564d5c2ef05
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp38-cp38-win_amd64.whl

Download URL ml_dtypes-0.0.2rc4-cp38-cp38-win_amd64.whl
Size 134.8 kB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
59666a3f94d6831210e8e8ca97fa8948ba099854f3548ffabe52304eddc4c423
BLAKE2b-256 checksum
How to use checksums
574224710448676c0f6861d26bb7dfef273a99e2fc0fe937ea1def0218bb6653
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL ml_dtypes-0.0.2rc4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 231.0 kB
Tags CPython 3.8 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
299763c225f14e3f0ea9a01d5b40df556406d8be993aa4ea72aa4423347dc6f1
BLAKE2b-256 checksum
How to use checksums
a5f693946b8198bdc8b04b40f4a13f954f2757e4786f7b29b70960e41edba2c6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / ml_dtypes-0.0.2rc4-cp38-cp38-macosx_10_9_universal2.whl

Download URL ml_dtypes-0.0.2rc4-cp38-cp38-macosx_10_9_universal2.whl
Size 311.9 kB
Tags CPython 3.8 macOS 10.9+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
c2080ad4822d1c139a3bd8385e71f7930c7207b2b56bc69cbc2307efff80045b
BLAKE2b-256 checksum
How to use checksums
6cf291296d0113d393be9496ef025cb1fd283bd2b907abf24619361d36958e59
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page