Skip to main content

Luwen

Named after Antonie van Leeuwenhoek, inventor of the microscope.

documentation crates.io pkg pypi bindings

About

Luwen is a user-mode abstraction layer for accessing Tenstorrent accelerator hardware, designed to be used as a common interface for tooling development across hardware generations. It runs on the host system and manages communication with lower-level drivers and firmware.

Design

There are three supported use cases:

  1. High-level interface to software tooling allowing all syseng diagnostics collectable via tt-smi and tt-mod to be read back and interacted with as a library.
    • Only supports PCIe connections and remote connections via PCI.
    • Ignores implementation details of using communication channels, such as TLB allocation and core selection.
  2. General chip discovery and initialization, replacing create-ethernet-map and tt-smi. Will probably also add the ability to issue resets.
  3. Low-level syseng-only debug capability (via Python bindings, as pyluwen; requires Python 3.10+).
    • To avoid needing to have multiple in-flight stacks, access the implemented communication APIs directly.
    • Direct access to the types defined in luwen-pci, allowing modification of TLBs and cores being used.

Installation

See the included INSTALL.md for detailed instructions on how to build and install Luwen.

Support

Hardware

Luwen officially supports the following Tenstorrent hardware:

  • Wormhole
  • Blackhole

Firmware

Please ensure you have a supported firmware version installed on your device. You can flash the firmware using tt-flash.

[!IMPORTANT]

The current minimum supported firmware version is: v18.

Driver (KMD)

Luwen communicates with your device through a kernel-mode driver. You can find instructions on installing the driver on the project homepage.

[!IMPORTANT]

The current minimum supported driver version is: v2.0.0.

Organization

Cargo — Rust's package manager — allows for a workspace of several crates to be specified within its manifest. Within this project, workspace crates are used with the structure as follows:

./
├── Cargo.lock       # cargo lockfile
├── Cargo.toml       # cargo manifest
├── README.md        # this document
├── ...
├── apps/            # use-case applications
├── bind/            # language bindings
│   ├── libluwen/    # bindings for C++
│   └── pyluwen/     # bindings for Python
├── crates/          # implementation crates
│   ├── luwen-api/   # core generalized API
│   ├── luwen-def/   # common definitions
│   ├── luwen-kmd/   # low-level driver API
│   └── luwen-pci/   # PCI implementation
├── examples/        # application examples
├── src/             # top-level library
└── tests/           # integration tests

License

This project is licensed under Apache License 2.0. You have permission to use this code under the conditions of the license pursuant to the rights it grants.

This software assists in programming Tenstorrent products. Making, using, or selling hardware, models, or IP may require the license of rights (such as patent rights) from Tenstorrent or others.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyluwen-0.9.0.tar.gz (154.0 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pyluwen-0.9.0-cp311-abi3-manylinux_2_28_x86_64.whl (754.0 kB view details)

Uploaded CPython 3.11+manylinux: glibc 2.28+ x86-64

pyluwen-0.9.0-cp310-cp310-manylinux_2_28_x86_64.whl (749.5 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

File details

Details for the file pyluwen-0.9.0.tar.gz.

File metadata

  • Download URL: pyluwen-0.9.0.tar.gz
  • Upload date:
  • Size: 154.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for pyluwen-0.9.0.tar.gz
Algorithm Hash digest
SHA256 b4ee8fedb3f9301a468f6749435c83413c8843fd841ea9b7871dabe65ac0e455
MD5 cfb0de4a393055812f581c47638f3d87
BLAKE2b-256 b2e31d979045664a52ba43dfce71045d3c301c8c2f4647515d21e063d32d722a

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyluwen-0.9.0.tar.gz:

Publisher: publish.yml on tenstorrent/luwen

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pyluwen-0.9.0-cp311-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for pyluwen-0.9.0-cp311-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 e09d9359599b01cd5d03866c61692a06d18e6fe9cddacf99f17d742f875b057c
MD5 e4d86c205f873933e3bcbcd41154e0c3
BLAKE2b-256 30446816c1dcc28c9110e867a7bdcec8f86c73b30694328e9a268060df2c22c7

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyluwen-0.9.0-cp311-abi3-manylinux_2_28_x86_64.whl:

Publisher: publish.yml on tenstorrent/luwen

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pyluwen-0.9.0-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for pyluwen-0.9.0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 4982ede98e7aa602e02cb4f3763bbe993f54ed470a5b26384bf653c696b943b3
MD5 e99897a92fe0437a3b7c5557c792aa6a
BLAKE2b-256 2c9ac5890520db3c33da8ef3eb086722af780af4d547e6f7aec5f393476c8080

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyluwen-0.9.0-cp310-cp310-manylinux_2_28_x86_64.whl:

Publisher: publish.yml on tenstorrent/luwen

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page