Aiger to BDD bridge.
Project description
py-aiger-bdd
Installation
$ pip install py-aiger-bdd
For developers, note that this project uses the poetry python package/dependency management tool. Please familarize yourself with it and then run:
$ poetry install
Usage
This tutorial assumes familiarity with py-aiger and py-aiger-bv.
import aigerbv from aiger_bdd import to_bdd, from_bdd, count x = aigerbv.atom(3, 'x', signed=False) expr = x < 5 # Could be an AIG or AIGBV or BoolExpr. bdd, manager, input2var = to_bdd(expr) # Convert circuit encoded by expr into a BDD. expr2 = from_bdd(bdd) # Creates an Aiger Expression from a BDD. assert count(expr, fraction=True) == 5/8 assert count(expr, fraction=False) == 5
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size py_aiger_bdd-0.2.2-py3-none-any.whl (4.6 kB) | File type Wheel | Python version py3 | Upload date | Hashes View hashes |
Filename, size py-aiger-bdd-0.2.2.tar.gz (4.2 kB) | File type Source | Python version None | Upload date | Hashes View hashes |
Close
Hashes for py_aiger_bdd-0.2.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 101408b2791d9069067254c1f2e43b4b6b27ad7df84eca93179542ea9c3684ed |
|
MD5 | 64363d9a902c13fcd07fbeeddf65bd22 |
|
BLAKE2-256 | c87f3642532e3414353913910aa606a8ba3def1f1827bbd3ff02141ebdd2fdc3 |