Closed grafau closed 5 years ago
Hi there --
Thanks for reporting, hope we can sort this out quickly.
Is there any notable output before/when it segfaults?
Also, are you installing through conda or pip? If using pip, could you try installing with conda and report what happens? (or vice versa)
I'll try to see if I can reproduce this on a clean CentOS vm later this week.
Hi!
1) in version 2.1.14 when I was reading vcf's, import would get stuck at different positions but error message would look like the one on the bottom of the message.
2) in version 2.1.16 during import there are no additional error messages provided
3) I installed momi with Conda. I have never really used pip before, when I tried now I was unsuccessful with momi import. I received following message (even after multiple re-installations of numpy):
ImportError:
Importing the multiarray numpy extension module failed. Most
likely you are trying to import a failed build of numpy.
If you're working with a numpy git repo, try git clean -xdf
(removes all
files not under version control). Otherwise reinstall numpy.
Original error was: cannot import name multiarray
--------------- SEGFAULT 2.1.14 ---------------------
In [108]: %%sh
...:
...: for chrom in `seq 1 20`;
...: do
...: python -m momi.read_vcf \
...: tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt \
...: tutorial_datasets/$chrom.snpAlleleCounts.gz \
...: --bed tutorial_datasets/$chrom.bed
...: done
sh: line 2: 125617 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 125765 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 125822 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 125934 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126014 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126090 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126190 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126278 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126357 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126431 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126511 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126585 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126697 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126775 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126851 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 126925 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 127071 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 127182 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 127263 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
sh: line 2: 127341 Segmentation fault (core dumped) python -m momi.read_vcf tutorial_datasets/$chrom.vcf.gz tutorial_datasets/ind2pop.txt tutorial_datasets/$chrom.snpAlleleCounts.gz --bed tutorial_datasets/$chrom.bed
CalledProcessError Traceback (most recent call last)
Update:
PIP installation v2.1.16: 1) There is an issue with Python 3.7.1 numpy installation on my CentOS. When I installed Python 3.6.6, numpy compiled correctly, import of numpy and momi went smoothly.
2) with pip installation python3.6 -m momi.read_vcf
works without segfault.
CONDA installation v2.1.16: 1) I am still getting segfault; based on my search it might have something to do with numpy again. Apparently segfaults happen when numpy tries to imported twice. Not sure how would that work practically.
2) I made a new, clean momi-env. Momi imports, but during import shows following warning:
miniconda3/envs/momi-env/lib/python3.6/importlib/_bootstrap.py:219: RuntimeWarning: numpy.dtype size changed, may indicate binary incompatibility. Expected 96, got 88 return f(*args, **kwds)
During read.vcf:
miniconda3/envs/momi-env/lib/python3.6/importlib/_bootstrap.py:219: RuntimeWarning: numpy.dtype size changed, may indicate binary incompatibility. Expected 96, got 88 return f(*args, **kwds)
Sorry for all the chaos. I am quite new to managing virtual envs and I might be doing something wrong. With each of 3 creations of momi-env and installation through conda, I get different problems, but they all seem to be linked to numpy somehow.
HTH, Rafal
Thanks for the update, and sorry I have not yet had time to fully investigate this.
The RuntimeWarning is currently happening for momi conda builds on all linux systems, and while very annoying, it should be safe to ignore according to Anaconda devs (https://github.com/ContinuumIO/anaconda-issues/issues/6678#issuecomment-337276215). Probably we need to change the way we build momi for conda.
I'll leave this issue open until I figure out how to silence this warning, and also until we've sorted out what's going on with Python 3.7 on CentOS here.
Since you've managed to get momi installed (albeit with RuntimeWarnings which can be ignored), and since I don't use CentOS, I'm going to close this as part of issue cleanup. Please comment and/or reopen if this becomes a blocking issue again.
Hi!
I am trying to use momi2 on my lab server (distribution: CentOS Linux release 7.5.1804 (Core); Python: 3.6.6)
When I tried to go through the tutorial with momi-2.1.14, i got segfault when importing simulated vcf: _python -m momi.readvcf
Then, I updated momi to momi-2.1.16 and now I get segfault during import: import momi
Your suggestions for troubleshooting would be most valuable.
Best, Rafal