Skip to content

Commit

Permalink
Add a workaround for Numpy's ABI issue
Browse files Browse the repository at this point in the history
  • Loading branch information
r9y9 committed Aug 7, 2022
1 parent b8ead58 commit 0931978
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,4 +114,4 @@ Out[3]: 'コンニチワ'

## Acknowledgements

HTS Working Group for their dedicated efforts to develop and maintain Open JTalk.
HTS Working Group for their dedicated efforts to develop and maintain Open JTalk.
2 changes: 1 addition & 1 deletion docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Change log
v0.3.0 <2022-xx-xx>
-------------------

Newer numpy (>v1.20.0) is required to avoid ABI compatibility issues.
Newer numpy (>v1.20.0) is required to avoid ABI compatibility issues. Please check the updated installation guide.

* `#35`_: Fixes for Python 3.10.

Expand Down
18 changes: 18 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,24 @@ The latest release is availabe on pypi. You can install it by:
pip install pyopenjtalk
Workaround for ``ValueError: numpy.ndarray size changed, may indicate binary incompatibility``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

This type of errors comes from the Numpys' ABI breaking changes. If you see ``ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject`` or similar, please make sure to install numpy first, and then install pyopenjtalk by:

.. code::
pip install pyopenjtalk --no-build-isolation
or:

.. code::
pip install git+https://github.com/r9y9/pyopenjtalk --no-build-isolation
The option ``--no-build-isolation`` tells pip not to create a build environment, so the pre-installed numpy is used to build the packge. Hense there should be no Numpy's ABI issues.

.. toctree::
:maxdepth: 1
:caption: Notebooks
Expand Down

0 comments on commit 0931978

Please sign in to comment.