Skip to content
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

feat: use latest VRS Python annotator API + return logs #8

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions containers/base/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ RUN cd ~ && \
make install && \
export BCFTOOLS_PLUGINS=~/bcftools/plugins/

RUN pip install ga4gh.vrs[extras]==2.0.0a7 biocommons.seqrepo
RUN pip install ga4gh.vrs[extras]==2.0.0a11 biocommons.seqrepo

RUN sudo apt-get update && sudo apt-get install -y rsync

CMD ["/bin/bash"]
CMD ["/bin/bash"]
12 changes: 6 additions & 6 deletions vrs-annotator.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version 1.0
workflow VRSAnnotator {
input {
File input_vcf_path
String output_vcf_name
String output_vcf_name
File seqrepo_tarball
Boolean compute_for_ref = true
Boolean compute_vrs_attributes = true
Expand Down Expand Up @@ -67,27 +67,27 @@ task annotate {
else
REF_FLAG="--skip_ref"
fi

if ~{compute_vrs_attributes}; then
VRS_ATTRIBUTES_FLAG="--vrs_attributes"
else
VRS_ATTRIBUTES_FLAG=""
fi

# annotate and index vcf
python -m ga4gh.vrs.extras.vcf_annotation \
--vcf_in ~{input_vcf_path} \
vrs-annotate vcf ~{input_vcf_path} \
--vcf_out ~{output_vcf_name} \
--seqrepo_root_dir $SEQREPO_DIR/latest \
--assembly ~{genome_assembly} \
$REF_FLAG \
$VRS_ATTRIBUTES_FLAG

bcftools index -t ~{output_vcf_name}
>>>

output {
File annotated_vcf = "~{output_vcf_name}"
File annotated_vcf_index = "~{output_vcf_name}.tbi"
File vrs_annotation_log = "vrs-annotate.log"
}
}
}