holgern / pyedflib

pyedflib is a python library to read/write EDF+/BDF+ files based on EDFlib.
http://pyedflib.readthedocs.org/
BSD 3-Clause "New" or "Revised" License
214 stars 121 forks source link

ValueError: numpy.ndarray size changed, may indicate binary incompatibility. #156

Closed YaohuaYang closed 2 years ago

YaohuaYang commented 2 years ago

Env macOS Monterey Apple M1 Pro python 3.9.9 Numpy 1.20.3 pyedflib v0.1.24, v0.1.19

All packages we installed through arch -arm64 pip install packagename==version

Shows below error while importing pyedflib ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject

Besides, I'm not able to install v0.1.20-v0.1.23 since the numpy version was limited to under 1.20. And I don't want to upgrade NumPy over 1.20 since I have another dependency. Can anyone help me on this issue? Thanks!

skjerns commented 2 years ago

have you tried the solutions from here?

https://github.com/holgern/pyedflib/issues/94

YaohuaYang commented 2 years ago

have you tried the solutions from here?

94

No, it doesn't work. Is it possible for you to compile a osx-arm64 version and upload to conda package manager? It would be supper helpful! https://anaconda.org/conda-forge/pyedflib

skjerns commented 2 years ago

@YaohuaYang is this resolved by #164 ? can you try installing from master?

YaohuaYang commented 2 years ago

@skjerns Thanks for suggesting. I solved it with rosetta 2 + conda.