diff --git a/environments/pytom_full.yaml b/environments/pytom_full.yaml index c11847b3..401dca96 100644 --- a/environments/pytom_full.yaml +++ b/environments/pytom_full.yaml @@ -4,7 +4,7 @@ channels: dependencies: - python=3 - ipython -- numpy +- numpy<2 - lxml - scipy - boost diff --git a/pytom/pytomc/compile.py b/pytom/pytomc/compile.py index 64af4840..434e15a8 100755 --- a/pytom/pytomc/compile.py +++ b/pytom/pytomc/compile.py @@ -182,7 +182,7 @@ def check4specialchars(path): if include_numpy is None: try: import numpy - path = os.path.join(numpy.__path__[0], 'core/include/numpy') + path = numpy.get_include() includePaths = [path] + includePaths includeFile,include_numpy = find("ndarrayobject.h",includePaths) except Exception as e: diff --git a/setup.py b/setup.py index f1938f48..26dc81fe 100644 --- a/setup.py +++ b/setup.py @@ -62,7 +62,7 @@ def run(self): author='`FridoF', author_email='strubi.pytom@uu.nl', url='https://github.com/SBC-Utrecht/PyTom.git', - install_requires=['lxml', 'scipy', 'boost', 'numpy'], + install_requires=['lxml', 'scipy', 'boost', 'numpy>=1.18,<2'], extras_require={ 'gpu': ['cupy'], 'gui': ['PyQt5', 'pyqtgraph', 'mrcfile'],