Code Monkey home page Code Monkey logo

Comments (9)

rbonneville avatar rbonneville commented on August 20, 2024 1

Although I have not yet been able to reproduce this issue, I suspect that this is the sequence of events:

  1. Calling python from the shell to run mantis.py triggers the bash alias to python3. As Python 3.5 runs with PYTHONPATH pointing to the 3.5 libraries, it runs fine.
  2. mantis.py calls a helper program kmer_repeat_counter.py. However, bash will only recognize alias if run through an interactive shell (as explained here). Therefore, Python 2.7 runs kmer_repeat_counter.py.
  3. PYTHONPATH is still pointing to the 3.5 libraries. Given syntactic differences between Python 2 and 3, Python 2.7 crashes upon attempting to import them.

This issue should be fixed by properly packaging MANTIS (see #20). Until then, this may be a potential workaround:

  1. Create a folder in your home directory.
  2. Softlink /usr/local/bin/python3.5 to a link named 'python' in that folder.
  3. Set PATH to contain that folder first (e.g. export PATH=/path/to/python_folder:$PATH)
  4. Keep using your PYTHONPATH variable.

from mantis.

rbonneville avatar rbonneville commented on August 20, 2024

What command are you using to run MANTIS? Also, please run 'python -V' and post the output.

from mantis.

jp3117 avatar jp3117 commented on August 20, 2024

Thanks for your help.

Here is the command:
python mantis.py --bedfile msi.test.bed --genome /Volumes/Data/References/HiSeqAnalysisSoftware_UCSC_hg19/Homo_sapiens/UCSC/hg19/Sequence/WholeGenomeFasta/genome.fa -n ./Sample-N1-EX-KD.bam -t ./Sample-T1-EX-KD.bam -o msi.txt

pgmserver01 ~/MANTIS-master -> python -V
Python 3.5.1

from mantis.

rbonneville avatar rbonneville commented on August 20, 2024

We are investigating this; we are currently requesting to borrow a Mac (from our department) to attempt to reproduce your error.

from mantis.

messersc avatar messersc commented on August 20, 2024

The only other reference to this error I can find is https://stackoverflow.com/questions/38124761/import-site-failed-use-v-for-traceback

Which python are you using? Can you also show the output of which python and which python3?

from mantis.

jp3117 avatar jp3117 commented on August 20, 2024

from mantis.

rbonneville avatar rbonneville commented on August 20, 2024

Try this version: https://github.com/rbonneville/MANTIS/tree/iss021

from mantis.

rbonneville avatar rbonneville commented on August 20, 2024

Hello @jp3117, do you have any further questions regarding this issue?

from mantis.

jp3117 avatar jp3117 commented on August 20, 2024

from mantis.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.