A library for creating and solving constrained randomization problems
Project description
constrainedrandom
A package for creating and solving constrained randomization problems.
Use this package to create SystemVerilog-style "declarative" randomizable objects in Python.
This is achieved by providing wrappers around the Python random
and constraint
packages, and aims to be as efficient as possible in a language like Python.
Installation
$ pip install constrainedrandom
Documentation
To build the documentation yourself:
$ cd docs
$ make html
The index page is at docs/_build/html/index.html
- you can open this in a web browser.
Contributions
Please feel free to contribute to the project, following these guidelines:
- Please contribute by creating a fork and submitting a pull request.
- Pull requests should be as small as possible to resolve the issue they are trying to address.
- Pull requests must respect the goals of the library, as stated in the documentation.
- Pull requests should maintain backwards compatibility at least as far as Python 3.8.
- Pull requests should pass all the tests in the
tests/
directory. Runpython -m tests
. - Pull requests should take care not to make performance worse except for cases which require bug fixes. Run
python -m tests
andpython -m benchmarks
. - Pull requests should update the documentation for any added/changed functionality.
TODO
- Add proper CI using tox or similar, testing Python versions 3.8..current
- Add equivalent SystemVerilog testcases for benchmarking.
Contact the author(s)
Will Keen - william.keen@imgtec.com
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
constrainedrandom-1.0.0.tar.gz
(40.4 kB
view hashes)
Built Distribution
Close
Hashes for constrainedrandom-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6a6e01e0332aa106ebbd2ac698d8ffcac2e6ffbc8a978383fb27a42beec663cc |
|
MD5 | 576add31941d24f67e0c551dac5266ed |
|
BLAKE2b-256 | dfbcab247b220f210cf4271c4261d163ea645c967a5696140cd399badfe2ba03 |