Skip to content

Latest commit

 

History

History
55 lines (36 loc) · 1.67 KB

File metadata and controls

55 lines (36 loc) · 1.67 KB

ThermalBits

ThermalBits logo

ThermalBits is a Python library for inspecting combinational digital circuits from Verilog netlists, transforming them as editable DAGs, and estimating their information loss through Shannon entropy.

It helps compare original and optimized circuit structures by parsing Verilog, exporting JSON or reconstructed Verilog, rendering DAG images, applying transformations, and computing Landauer-related entropy with a bundled Rust simulator.

The main advantages are a compact Python API, direct access to the internal pi, po, and node representation, reproducible optimization flows, visual inspection support, and batch CSV reporting for experiments across many netlists.

Installation

Install the Python dependencies from the repository root:

python -m pip install -r requirements.txt

For development dependencies:

python -m pip install -r requirements-dev.txt

The entropy simulator is a Rust binary bundled under thermalbits/iron_circuit_sim/. Build it once before calling update_entropy():

cd thermalbits/iron_circuit_sim
RUSTFLAGS="-C target-cpu=native" cargo build --release

To build package artifacts:

python -m build

Artifacts will be created in dist/.

Full Documentation

The complete documentation is in documentation/docs. Start with:

To serve the documentation locally:

python -m pip install -r documentation/requirements-docs.txt
mkdocs serve -f documentation/mkdocs.yml