ksamuk / pixy

Software for painlessly estimating average nucleotide diversity within and between populations
https://pixy.readthedocs.io/
MIT License
115 stars 14 forks source link

Installation issue with pixy #95

Closed vinod1981 closed 6 months ago

vinod1981 commented 8 months ago

Hi, Just installed pixy with python3.8 and everything worked well but when testing it, it is causing error:

pixy --version
Traceback (most recent call last):
  File "/vol/cluster-data/vkumar/miniconda3/envs/pixy_pop/bin/pixy", line 7, in <module>
    from pixy.__main__ import main
  File "/vol/cluster-data/vkumar/miniconda3/envs/pixy_pop/lib/python3.8/site-packages/pixy/__main__.py", line 6, in <module>
    import allel
  File "/vol/cluster-data/vkumar/miniconda3/envs/pixy_pop/lib/python3.8/site-packages/allel/__init__.py", line 5, in <module>
    from .model.ndarray import *
  File "/vol/cluster-data/vkumar/miniconda3/envs/pixy_pop/lib/python3.8/site-packages/allel/model/ndarray.py", line 17, in <module>
    from allel.opt.model import genotype_array_pack_diploid, genotype_array_unpack_diploid, \
  File "allel/opt/model.pyx", line 1, in init allel.opt.model
ImportError: numpy.core.multiarray failed to import (auto-generated because you didn't call 'numpy.import_array()' after cimporting numpy; use '<void>numpy._import_array' to disable if you are certain you don't need it).

Tried various versions of numpy but can't solve the issue. Thanks

seanharrington256 commented 7 months ago

I ran into a similar issue recently, I posted my fix as an issue here: https://github.com/ksamuk/pixy/issues/94

Installing numpy=1.21 and samtools=1.9 after installing pixy worked for me.

ksamuk commented 6 months ago

I believe this should now be solved in the newest release, please update with conda install --yes -c conda-forge pixy and let me know if you still have this issue. Thanks for reporting!