Official site of the hwloc library.
GitHub repository of the hwloc library.
Quick Start Example
from pyhwloc import from_this_system
# Create and load system topology
with from_this_system() as topo:
# Get basic system information
n_cores = topo.n_cores()
n_numa = topo.n_numa_nodes()
print(f"System has {n_cores} CPU cores")
print(f"System has {n_numa} NUMA nodes")
# Get the current CPU binding
cpuset = topo.get_cpubind()
print(f"Current CPU binding: {cpuset}")
Install
pip install pyhwloc
Supported platforms:
Linux distributions, tested with latest Ubuntu LTS.
Latest Windows.
The binaries on PyPI have optional support for CUDA 13 plugins.
Metadata
Release files for pyhwloc 3.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pyhwloc-3.0.1.tar.gz | 95.0 kB | Details |
Built distributions (wheels)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pyhwloc-3.0.1-py3-none-win_amd64.whl | Python 3 | none | Windows x86-64 | Details |
| pyhwloc-3.0.1-py3-none-manylinux_2_34_x86_64.whl | Python 3 | none | Linux glibc 2.34+ x86-64 | Details |
| pyhwloc-3.0.1-py3-none-manylinux_2_34_aarch64.whl | Python 3 | none | Linux glibc 2.34+ ARM64 | Details |
Total release size: 5.7 MB
Release files / pyhwloc-3.0.1.tar.gz
| Download URL | pyhwloc-3.0.1.tar.gz |
|---|---|
| Size | 95.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7a068f72d6ed15708bd507f062017c6f3da7d778d748958e3702a0759070cca8
|
|
BLAKE2b-256 checksum How to use checksums |
9667257e9f4744a21c9fe7136cc639aafce618bd675fa69377c7ba0e8c60e1b0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 12, 2026.
Transparency logRelease files / pyhwloc-3.0.1-py3-none-win_amd64.whl
| Download URL | pyhwloc-3.0.1-py3-none-win_amd64.whl |
|---|---|
| Size | 674.3 kB |
| Tags | Python 3 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
07ef6ffcde04c77c35c4184f6ef050864376b44f0a47af31e12817dc0b849673
|
|
BLAKE2b-256 checksum How to use checksums |
10f5ec8ec9e59c163912d7741d277eee7f4f31b82aa59574fe1611ce45def010
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 12, 2026.
Transparency logRelease files / pyhwloc-3.0.1-py3-none-manylinux_2_34_x86_64.whl
| Download URL | pyhwloc-3.0.1-py3-none-manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.5 MB |
| Tags | Linux glibc 2.34+ x86-64 Python 3 |
|
SHA-256 checksum How to use checksums |
527d297708238072453de68e73084545bf98ac0c2f07ce25176ceaf761fa19e6
|
|
BLAKE2b-256 checksum How to use checksums |
236bb6967a4d58f99e9ff2464753ab218df407e841534615624847130c40445e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 12, 2026.
Transparency logRelease files / pyhwloc-3.0.1-py3-none-manylinux_2_34_aarch64.whl
| Download URL | pyhwloc-3.0.1-py3-none-manylinux_2_34_aarch64.whl |
|---|---|
| Size | 2.4 MB |
| Tags | Linux glibc 2.34+ ARM64 Python 3 |
|
SHA-256 checksum How to use checksums |
4d27294f2b9a6930b46802b047a429786664ee13963557890afa6c9bce6deaff
|
|
BLAKE2b-256 checksum How to use checksums |
6bf60ac13a2c439ee79f63eb373bf3d6c81e549165523dc75a7168e180d79fff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.13
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 12, 2026.
Transparency log