Skip to content

Commit

Permalink
feat: add support for functional elements (#14)
Browse files Browse the repository at this point in the history
  • Loading branch information
holtgrewe committed Nov 19, 2023
1 parent b96499c commit d5dd39e
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ name = "scarus"
path = "src/main.rs"

[dependencies]
annonars = "0.24.5"
annonars = "0.25.0"
anyhow = "1.0"
bio = "1.4"
biocommons-bioutils = "0.1.4"
Expand Down
2 changes: 1 addition & 1 deletion src/strucvars/eval/del/section2.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Implementation of evaluation of copy number loss section 2.

use annonars::{clinvar_minimal::pbs::ClinicalSignificance, clinvar_minimal::pbs::ReviewStatus};
use annonars::pbs::annonars::clinvar::v1::minimal::{ClinicalSignificance, ReviewStatus};
use bio::bio_types::genome::AbstractInterval;
use hgvs::data::interface::{Provider, TxExonsRecord, TxInfoRecord};

Expand Down
6 changes: 4 additions & 2 deletions src/strucvars/eval/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ pub mod result;

use std::{path::Path, sync::Arc};

use annonars::pbs::annonars::clinvar::v1::minimal::Record;
use hgvs::data::interface::Provider;
use itertools::Itertools as _;
use prost::Message as _;
Expand Down Expand Up @@ -102,6 +103,7 @@ impl Evaluator {
path_clinvar_minimal,
"clinvar",
"meta",
"clinvar_by_accession",
)
.map_err(|e| anyhow::anyhow!("failed to open 'minimal' ClinVar RocksDB: {}", e))?;

Expand Down Expand Up @@ -187,7 +189,7 @@ impl Evaluator {
chrom: &str,
start: u32,
stop: u32,
) -> Result<Vec<annonars::clinvar_minimal::pbs::Record>, anyhow::Error> {
) -> Result<Vec<Record>, anyhow::Error> {
tracing::trace!("starting clinvar query {}:{}-{}", &chrom, start, stop);
let start = start as i32;
let stop = stop as i32;
Expand Down Expand Up @@ -227,7 +229,7 @@ impl Evaluator {
}

// Otherwise, decode the value from the database.
let record = annonars::clinvar_minimal::pbs::Record::decode(value)?;
let record = Record::decode(value)?;
result.push(record);

// Proceed to the next database row.
Expand Down
6 changes: 5 additions & 1 deletion tests/data/strucvars/hi_ts/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,16 @@ RERE
LINCADL
"

wget -O /tmp/cdot-0.2.22.GCF_000001405.25_GRCh37.p13_genomic.105.20201022.gff.json.gz \
https://github.com/SACGF/cdot/releases/download/data_v0.2.22/cdot-0.2.22.GCF_000001405.25_GRCh37.p13_genomic.105.20201022.gff.json.gz

rm -rf $SCRIPTPATH/txs_example_hi.bin.zst
mehari db create \
-vvv \
--genome-release grch37 \
--path-mane-txs-tsv $SCRIPTPATH/tx-mane.tsv \
--path-out $SCRIPTPATH/txs_example_hi.bin.zst \
--path-cdot-json ~/mehari-data-tx/cdot-refseq-vep110~0+0.2.21.json.gz \
--path-cdot-json /tmp/cdot-0.2.22.GCF_000001405.25_GRCh37.p13_genomic.105.20201022.gff.json.gz \
--path-seqrepo-instance ~/mehari-data-tx/seqrepo/main \
$(for gene_symbol in $gene_symbols; do echo --gene-symbols $gene_symbol; done)

Expand Down
3 changes: 0 additions & 3 deletions tests/data/strucvars/hi_ts/txs_example_hi.bin.zst

This file was deleted.

3 changes: 0 additions & 3 deletions tests/data/strucvars/hi_ts/txs_example_hi.bin.zst.report
Git LFS file not shown

0 comments on commit d5dd39e

Please sign in to comment.