mobiusklein / brainpy

A Python implementation of Baffling Recursive Algorithm for Isotopic distributioN calculations
http://mobiusklein.github.io/brainpy
Apache License 2.0
19 stars 10 forks source link

No module named 'brainpy._c.composition' #5

Closed yhu39 closed 3 years ago

yhu39 commented 3 years ago

I downloaded the code from github and tried to install it by using python setup.py install When I tried to use "from brainpy import isotopic_variants", the error message is "No module named 'brainpy._c.composition'". I don't know how to deal with this. Please help. Thanks!

mobiusklein commented 3 years ago

Thank you for reporting this. It reminds me I didn't put the note about requiring Cython to install from source. brainpy has two C-based implementations, a Cython-ized version of the pure Python implementation, and a pure C implementation with Python bindings, both built with Cython.

To install from source, please install a recent version of Cython and have a C compiler appropriate to your Python version installed. Alternatively, if you're on Windows where it's difficult to obtain a C compiler, you can install this package using the prebuilt wheels available on PyPI using pip install brain-isotopic-distribution for Python versions 3.5-3.8. The package name brainpy was already taken.

mobiusklein commented 3 years ago

I've updated the documentation to reflect this.

mobiusklein commented 3 years ago

@yhu39 Have I solved the issue and can close this?

yhu39 commented 3 years ago

Sure. Thank you very much!