Skip to content

Commit

Permalink
Add docstrings to pybind bindings and add doctest examples to docstri…
Browse files Browse the repository at this point in the history
…ngs. Fixes #13
  • Loading branch information
oscarhiggott committed Sep 5, 2021
1 parent 96c0a75 commit e4fa28b
Show file tree
Hide file tree
Showing 6 changed files with 715 additions and 65 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ pip install -e ./PyMatching
```
The installation may take a few minutes since the C++ extension has to be compiled. If you'd also like to run the tests, first install [pytest](https://docs.pytest.org/en/stable/), and then run:
```
pytest ./PyMatching/tests
pytest ./PyMatching/tests ./PyMatching/src
```

## Usage
Expand Down
2 changes: 1 addition & 1 deletion src/pymatching/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

from pymatching._cpp_mwpm import (randomize, set_seed, rand_float)
from pymatching._cpp_mwpm import (randomize, set_seed, rand_float, BlossomFailureException)
from pymatching.matching import *

randomize() # Set random seed using std::random_device

0 comments on commit e4fa28b

Please sign in to comment.