load_vcf can't infer the build from common reference names (hs37d5, human_g1k_v37, Homo_sapiens_assembly19/38)
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 78/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- python
- Domain
- bioinformatics
Research direction
Start with varcode/reference.py, especially ensembl_reference_aliases and the resolver used by infer_genome and infer_reference_name. Check the Broad resource bundle documentation for the stated b37 and hg38 contig names, then add a test for each listed reference value. Done means these names resolve to the indicated builds and the tests pass.
Written by the indexing model from the issue text.
Description
Problem
load_vcf (through infer_genome and infer_reference_name) can't recognize the build in several widely used ##reference header values. It fails with Failed to infer genome assembly name, so the caller has to pass genome= by hand. load_vcf_samples/varcode check-samples now share this resolver (#691), so they need --assembly for the same files.
Checked on main at 6b444d5 (11.9.0):
##reference value |
Build | Result |
|---|---|---|
file:///refs/hs37d5.fa |
GRCh37 + decoy, 1000 Genomes phase 2 | fails |
/refs/human_g1k_v37.fasta |
GRCh37, 1000 Genomes phase 1 | fails |
file:///refs/Homo_sapiens_assembly19.fasta |
b37, Broad/GATK bundle | fails |
file:///refs/Homo_sapiens_assembly38.fasta |
hg38, Broad/GATK bundle | fails |
GRCh37-lite.fa, b37_decoy |
GRCh37 | recognized |
#207 fixed a hs37d5.fasta path only because its directory was named b37decoy-…; the file name alone still fails.
Suggested fix
Add these reference file names as aliases in varcode/reference.py (ensembl_reference_aliases, or a separate table of well-known FASTA names), with a test per name. The Broad names should be checked against the GATK resource bundle documentation: Homo_sapiens_assembly19 uses b37 contig names (1, MT), and Homo_sapiens_assembly38 uses hg38 names (chr1, chrM).
- Dominant language
- Python
- Stars
- 88
- Forks
- 28
- Avg merge
- 4h 47m
- Merged PRs (30d)
- 55
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from openvax/varcode
-
Align varcode with the openvax stack baseline (Python 2 __future__ imports)Possibly taken @iskandr claimed this today. Open
Difficulty 1/5 Under an hour Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 44/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 44/100
Maintainers usually reply within 1 day
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
igormcsouza/tether#278 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 91/100
aws-samples/sample-per-model-bedrock#803 ·
Maintainers usually reply within 1 day
-
documentation p1
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
huggingface/accelerate#4511 ·
Maintainers usually reply within 1 day
-
follow-up
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day