This is a test version of Biostars. For the public version, visit https://www.biostars.org.
python Mac run vcf ModuleNotFoundError: No module named 'model'

Usded conda install to install pyvcf,used -p option

(base) MacBook-Pro-2:python3.6 haozheng$ conda install -c bioconda -p /anaconda3/lib/python3.7/site-packages pyvcf

Then run in jupyter the following command:

import vcf 
---------------------------------------------------------------------------
ModuleNotFoundError                       Traceback (most recent call last)
<ipython-input-17-876da46299c7> in <module>()
      8 #import sys
      9 #sys.path.insert(0, '/anaconda3/lib/python2.7/site-packages')
---> 10 import vcf

/anaconda3/lib/python2.7/site-packages/vcf/__init__.py in <module>()
      7 
      8 
----> 9 from vcf.parser import Reader, Writer
     10 from vcf.parser import VCFReader, VCFWriter
     11 from vcf.filters import Base as Filter

/anaconda3/lib/python2.7/site-packages/vcf/parser.py in <module>()
     23     cparse = None
     24 
---> 25 from model import _Call, _Record, make_calldata_tuple
     26 from model import _Substitution, _Breakend, _SingleBreakend, _SV
     27 

**ModuleNotFoundError: No module named 'model'**

how to solve this No module named 'model' issue? thanks.

pyvcf vcf

I see this:

MacBook-Pro-2:python3.6

While you are installing in

/anaconda3/lib/python3.7/

and jupyter is loading from

/anaconda3/lib/python2.7/

I suspect you have some issues with multiple python installations.

0 answers

No answers yet.

Log in to answer this question.