Skip to content

get warning when run peddy #31

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
liushuangmms opened this issue Sep 18, 2017 · 12 comments
Open

get warning when run peddy #31

liushuangmms opened this issue Sep 18, 2017 · 12 comments

Comments

@liushuangmms
Copy link

Hi,

When I try to run peddy, I always got warnings like the following.
"WARNING:
24 samples in vcf not in ped:"
Does this matter? The results looks fine.

Thanks very much!

@brentp
Copy link
Owner

brentp commented Sep 18, 2017

that means your VCF has samples that are not in the ped file. can you post the full output?

and the output of zgrep -m1 CHROM $vcf ?

@liushuangmms
Copy link
Author

Sure, here are the full output of the warnings
"WARNING:
41 samples in vcf not in ped:
Br5190,Br5481,Br5009,Br5310,Br5216,Br5006,Br5391,Br5392,Br2520,Br2469,Br5156,Br2355,Br2379,Br5263,Br5207,Br5249,Br5347,Br2272,Br524$

WARNING:
1 samples in ped not in vcf:
nan

^[[1;31mped_check^[[0m
plotting
ran in 16.6 seconds
^[[1;31mhet_check^[[0m
loaded and subsetted thousand-genomes genotypes (shape: (2504, 4604)) in 0.5 seconds
/ysm-gpfs/home/sl857/anaconda2/lib/python2.7/site-packages/sklearn/utils/deprecation.py:52: DeprecationWarning: Class RandomizedPCA$
warnings.warn(msg, category=DeprecationWarning)
ran randomized PCA on thousand-genomes samples at 4604 sites in 0.8 seconds
Projected thousand-genomes genotypes and sample genotypes and predicted ancestry via SVM in 0.0 seconds
/ysm-gpfs/home/sl857/anaconda2/lib/python2.7/site-packages/numpy/core/_methods.py:59: RuntimeWarning: Mean of empty slice.
warnings.warn("Mean of empty slice.", RuntimeWarning)
/ysm-gpfs/home/sl857/anaconda2/lib/python2.7/site-packages/numpy/core/_methods.py:82: RuntimeWarning: Degrees of freedom <= 0 for s$
warnings.warn("Degrees of freedom <= 0 for slice", RuntimeWarning)
ran in 9.9 seconds"

and here is the output of zgrep -m1 CHROM $vcf
"#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT Br2355 Br2379 Br2452 Br2469 Br2520 Br2294 Br5347 Br2309 Br2078 Br5374 Br2272 Br5321 Br5422 Br5391 Br5392 Br2071 Br5288 Br5006 Br5009 Br5010 Br5190 Br5207 Br5156 Br5243 Br5281 Br5310 Br5336 Br5481 Br5216 Br5230 Br5365 Br5437 Br5252 Br5263 Br5225 Br5249 Br2297 Br2328 Br2364 Br2477 Br2368"

I also checked the IDs in both ped and vcf and they seemed to match each other.

Thanks!

@brentp
Copy link
Owner

brentp commented Sep 18, 2017

This is odd.
There must be somethign odd about your ped file. Can you post it here or email it to me?
what is the output of cut -f 1 $ped ?

@liushuangmms
Copy link
Author

The ped file is very large. Actually I got the ped file by converting the plink bim, fam and bed file format.

@brentp
Copy link
Owner

brentp commented Sep 18, 2017

ok. the ped file for peddy only needs the first 6 columns. Seems like you might have an empty row (maybe at the end?)

@liushuangmms
Copy link
Author

ok, I will check the rows and columns. Thank you very much!

@liushuangmms
Copy link
Author

I used the first 6 columns in ped file and the warnings disappeared. Thanks very much!

@athitheo
Copy link

Hi,
I am getting the following warnings when trying to run peddy on exome vcf file (unfiltered):
(Python 2.7.6)

2018-09-17 16:01:16 mdrtc3611 peddy.cli[9666] INFO Running Peddy version 0.4.2
2018-09-17 16:01:16 mdrtc3611 peddy.cli[9666] WARNING 12 samples in vcf not in ped:
37675,40604,42667,43147,43146,39001,42666,40887,39002,40888,37676,42668

2018-09-17 16:01:16 mdrtc3611 peddy.cli[9666] WARNING 1 samples in ped not in vcf:
nan

2018-09-17 16:01:16 mdrtc3611 peddy.cli[9666] INFO ped_check
Traceback (most recent call last):
File "/usr/local/bin/peddy", line 11, in
load_entry_point('peddy', 'console_scripts', 'peddy')()
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 722, in call
return self.main(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 697, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 535, in invoke
return callback(*args, **kwargs)
File "/home/athinat/bin/peddy/peddy/cli.py", line 207, in peddy
in ("ped_check", "het_check", "sex_check")]):
File "/home/athinat/bin/peddy/peddy/cli.py", line 43, in run
prefix=prefix, **kwargs)
File "/home/athinat/bin/peddy/peddy/peddy.py", line 966, in ped_check
d = cyvcf2.par_relatedness(vcf_str,
AttributeError: 'module' object has no attribute 'par_relatedness'

the output for zgrep -m1 CHROM $vcf is:
#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT 37675 37676 39001 39002 40604 40887 40888 42666 42667 42668 43146 43147

and for cut -f 1 $ped is:

1 39001 0 42666 2 -9
1 39002 0 42666 2 -9
1 42666 0 0 2 -9
2 40887 42668 42667 1 -9
2 40888 42668 42667 1 -9
2 42668 0 0 1 -9
2 42667 0 0 2 -9
3 40604 43147 43146 1 -9
3 43147 0 0 1 -9
3 43146 0 0 2 -9
4 37676 0 0 1 -9
4 37675 0 0 2 -9

Is it by any chance obvious what I am doing wrong? the ped is space separated not tab
Thanks
Athina

@brentp
Copy link
Owner

brentp commented Sep 17, 2018

you should use tabs. and make sure you don't have any empty lines at the end of the file.

is it possible that you have a really old version of cyvcf2? you could update that as well.

@athitheo
Copy link

Thank you for the immediate reply.
I changed spaces for tabs that worked for the initial warnings but when trying to test with setup for cyvcf2 I get the following:

running test
Searching for nose
Best match: nose 1.3.7
Processing nose-1.3.7-py2.7.egg

Using /home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg
running egg_info
writing requirements to cyvcf2.egg-info/requires.txt
writing cyvcf2.egg-info/PKG-INFO
writing top-level names to cyvcf2.egg-info/top_level.txt
writing dependency_links to cyvcf2.egg-info/dependency_links.txt
writing entry points to cyvcf2.egg-info/entry_points.txt
reading manifest file 'cyvcf2.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'cyvcf2.egg-info/SOURCES.txt'
running build_ext
skipping 'cyvcf2/cyvcf2.c' Cython extension (up-to-date)
/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/config.py:264: RuntimeWarning: Option 'with-coverage' in config file 'setup.cfg' ignored: excluded by runtime environment
warn(msg, RuntimeWarning)
Failure: ImportError (/home/athinat/bin/cyvcf2-master/cyvcf2/cyvcf2.so: undefined symbol: EVP_sha1) ... ERROR

======================================================================
ERROR: Failure: ImportError (/home/athinat/bin/cyvcf2-master/cyvcf2/cyvcf2.so: undefined symbol: EVP_sha1)

Traceback (most recent call last):
File "/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/loader.py", line 418, in loadTestsFromName
addr.filename, addr.module)
File "/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/importer.py", line 47, in importFromPath
return self.importFromDir(dir_path, fqname)
File "/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/importer.py", line 94, in importFromDir
mod = load_module(part_fqname, fh, filename, desc)
File "/home/athinat/bin/cyvcf2-master/cyvcf2/init.py", line 1, in
from .cyvcf2 import (VCF, Variant, Writer, r_ as r_unphased, par_relatedness,
ImportError: /home/athinat/bin/cyvcf2-master/cyvcf2/cyvcf2.so: undefined symbol: EVP_sha1


Ran 1 test in 0.006s

FAILED (errors=1)
root@mdrtc3611:/home/athinat/bin/cyvcf2-master# sudo python setup.py test
running test
Searching for nose
Best match: nose 1.3.7
Processing nose-1.3.7-py2.7.egg

Using /home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg
running egg_info
writing requirements to cyvcf2.egg-info/requires.txt
writing cyvcf2.egg-info/PKG-INFO
writing top-level names to cyvcf2.egg-info/top_level.txt
writing dependency_links to cyvcf2.egg-info/dependency_links.txt
writing entry points to cyvcf2.egg-info/entry_points.txt
reading manifest file 'cyvcf2.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'cyvcf2.egg-info/SOURCES.txt'
running build_ext
skipping 'cyvcf2/cyvcf2.c' Cython extension (up-to-date)
/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/config.py:264: RuntimeWarning: Option 'with-coverage' in config file 'setup.cfg' ignored: excluded by runtime environment
warn(msg, RuntimeWarning)
Failure: ImportError (/home/athinat/bin/cyvcf2-master/cyvcf2/cyvcf2.so: undefined symbol: EVP_sha1) ... ERROR

======================================================================
ERROR: Failure: ImportError (/home/athinat/bin/cyvcf2-master/cyvcf2/cyvcf2.so: undefined symbol: EVP_sha1)

Traceback (most recent call last):
File "/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/loader.py", line 418, in loadTestsFromName
addr.filename, addr.module)
File "/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/importer.py", line 47, in importFromPath
return self.importFromDir(dir_path, fqname)
File "/home/athinat/bin/cyvcf2-master/.eggs/nose-1.3.7-py2.7.egg/nose/importer.py", line 94, in importFromDir
mod = load_module(part_fqname, fh, filename, desc)
File "/home/athinat/bin/cyvcf2-master/cyvcf2/init.py", line 1, in
from .cyvcf2 import (VCF, Variant, Writer, r_ as r_unphased, par_relatedness,
ImportError: /home/athinat/bin/cyvcf2-master/cyvcf2/cyvcf2.so: undefined symbol: EVP_sha1


Ran 1 test in 0.006s

FAILED (errors=1)

Any feedback on that?

@brentp
Copy link
Owner

brentp commented Sep 18, 2018

can you install the cyvcf2 from bioconda? otherwise, you'll need libcrypto and libcurl and likely liblzma

@athitheo
Copy link

Bioconda did the job!
Thank you Brent

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants