Skip to content

problem for haplotype_plot input? #3

@liangyiye

Description

@liangyiye

I'm using the test data ("chr01.vcf") to test the command haplotype_plot, but it always return errors like following:
#############################################################
2021-02-01:19:24:59 DEBUG [reader.py:36] Converting VCF file 'haplotype_plot/tests/data/chr01.vcf'
2021-02-01:19:24:59 DEBUG [reader.py:38] File '/mnt/Data_disk/liangyiye/Qvari7/007genomescan/haplotype_plot/haplotype_plot-master/haplotype_plot/tests/data/chr01.h5' already exists. I will remove it.
2021-02-01:19:24:59 DEBUG [reader.py:41] HDF5 file stored in '/mnt/Data_disk/liangyiye/Qvari7/007genomescan/haplotype_plot/haplotype_plot-master/haplotype_plot/tests/data/chr01.h5'
2021-02-01:19:24:59 DEBUG [genotyper.py:118] Loading HDF5 file '/mnt/Data_disk/liangyiye/Qvari7/007genomescan/haplotype_plot/haplotype_plot-master/haplotype_plot/tests/data/chr01.h5'
2021-02-01:19:24:59 ERROR [genotyper.py:72] Sample 'SAMPLE1' is not found in VCF sample list '[b'SAMPLE1', b'SAMPLE4', b'SAMPLE5', b'SAMPLE2', b'SAMPLE3', b'SAMPLE8', b'SAMPLE9', b'SAMPLE6', b'SAMPLE7', b'SAMPLE10']'
Traceback (most recent call last):
File "/mnt/Data_disk/liangyiye/.local/lib/python3.7/site-packages/haplotype_plot/genotyper.py", line 66, in get_sample_index
parental_sample_index = sample_list.index(sample)
ValueError: 'SAMPLE1' is not in list

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/mnt/Data_disk/liangyiye/.local/bin/haplotype_plot", line 8, in
sys.exit(main())
File "/mnt/Data_disk/liangyiye/.local/lib/python3.7/site-packages/haplotype_plot/main.py", line 42, in main
haplotyper.Zygosity[args.zygosis])
File "/mnt/Data_disk/liangyiye/.local/lib/python3.7/site-packages/haplotype_plot/genotyper.py", line 121, in process
parental_sample_index = get_sample_index(sample_list, parental_sample)
File "/mnt/Data_disk/liangyiye/.local/lib/python3.7/site-packages/haplotype_plot/genotyper.py", line 73, in get_sample_index
raise ValueError(msg)
ValueError: Sample 'SAMPLE1' is not found in VCF sample list '[b'SAMPLE1', b'SAMPLE4', b'SAMPLE5', b'SAMPLE2', b'SAMPLE3', b'SAMPLE8', b'SAMPLE9', b'SAMPLE6', b'SAMPLE7', b'SAMPLE10']'
##########################################################
My command is: haplotype_plot -v "haplotype_plot/tests/data/chr01.vcf" -c "chr01" -p "SAMPLE1" -z HOM. I am very confused about this error and I look forward to your answer.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions