Skip to content

Commit

Permalink
Rendering some of the new linkouts and datasets, with some fixture up…
Browse files Browse the repository at this point in the history
…dates
  • Loading branch information
SeriousHorncat committed Dec 11, 2024
1 parent 2215466 commit 55cbc0b
Show file tree
Hide file tree
Showing 6 changed files with 101 additions and 6 deletions.
2 changes: 1 addition & 1 deletion backend/src/core/annotation_unit.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ def delay_count_exceeds(self):
Checks if the annotation unit has exceeded the delay count within the queue.
Delay count is set as a magic number (10).
"""
if self.dataset['delay_count'] < 10:
if self.dataset['delay_count'] < 15:
return False
return True

Expand Down
49 changes: 47 additions & 2 deletions etc/fixtures/initial-seed/annotations-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -231,13 +231,22 @@
{
"data_set": "gnomAD_variant_url",
"data_source": "Rosalution",
"genomic_unit_type": "gene",
"genomic_unit_type": "hgvs_variant",
"annotation_source_type": "forge",
"base_string": "https://gnomad.broadinstitute.org/variant/{ensembl_vep_vcf_string}?dataset=gnomad_r4",
"attribute": "{ \"gnomAD_variant_url\": .gnomAD_variant_url }",
"dependencies": ["ensembl_vep_vcf_string"],
"versioning_type": "rosalution"
},
{
"data_set": "COSMIC_gene_url",
"data_source": "Rosalution",
"genomic_unit_type": "gene",
"annotation_source_type": "forge",
"base_string": "https://cancer.sanger.ac.uk/cosmic/gene/analysis?ln={gene}",
"attribute": "{ \"COSMIC_gene_url\": .COSMIC_gene_url }",
"versioning_type": "rosalution"
},
{
"data_set": "HPO_NCBI_GENE_ID",
"data_source": "HPO",
Expand Down Expand Up @@ -474,7 +483,7 @@
"attribute": ".[].transcript_consequences[] | { consequence_terms: .consequence_terms, transcript_id: .transcript_id }",
"dependencies": ["hgvs_variant_without_transcript_version"],
"versioning_type": "rest",
"version_url": "https://rest.ensembl.org/info/data/?content-type=application/json",
"version_url": "https://rest.ensembl.org/info/data/?content-type=application/json",
"version_attribute": ".releases[]"
},
{
Expand All @@ -489,6 +498,42 @@
"version_url": "https://rest.ensembl.org/info/data/?content-type=application/json",
"version_attribute": ".releases[]"
},
{
"data_set": "alphamissense_pathogenicity",
"data_source": "Ensembl",
"genomic_unit_type": "hgvs_variant",
"annotation_source_type": "http",
"url": "https://rest.ensembl.org/vep/human/hgvs/{hgvs_variant_without_transcript_version}?content-type=application/json;AlphaMissense=1;refseq=1;",
"attribute": ".[].transcript_consequences[] | select( .transcript_id | contains(\"{transcript}\") ) | { alphamissense: .alphamissense.am_pathogenicity }",
"dependencies": ["transcript","hgvs_variant_without_transcript_version"],
"versioning_type": "rest",
"version_url": "https://rest.ensembl.org/info/data/?content-type=application/json",
"version_attribute": ".releases[]"
},
{
"data_set": "alphamissense_classification",
"data_source": "Ensembl",
"genomic_unit_type": "hgvs_variant",
"annotation_source_type": "http",
"url": "https://rest.ensembl.org/vep/human/hgvs/{hgvs_variant_without_transcript_version}?content-type=application/json;AlphaMissense=1;refseq=1;",
"attribute": ".[].transcript_consequences[] | select( .transcript_id | contains(\"{transcript}\") ) | { alphamissense: .alphamissense.am_class }",
"dependencies": ["transcript","hgvs_variant_without_transcript_version"],
"versioning_type": "rest",
"version_url": "https://rest.ensembl.org/info/data/?content-type=application/json",
"version_attribute": ".releases[]"
},
{
"data_set": "revel",
"data_source": "Ensembl",
"genomic_unit_type": "hgvs_variant",
"annotation_source_type": "http",
"url": "https://rest.ensembl.org/vep/human/hgvs/{hgvs_variant_without_transcript_version}?content-type=application/json;AlphaMissense=1;refseq=1;",
"attribute": ".[].transcript_consequences[] | select( .transcript_id | contains(\"{transcript}\") ) | { revel: .revel }",
"dependencies": ["transcript","hgvs_variant_without_transcript_version"],
"versioning_type": "rest",
"version_url": "https://rest.ensembl.org/info/data/?content-type=application/json",
"version_attribute": ".releases[]"
},
{
"data_set": "Impact",
"data_source": "Ensembl",
Expand Down
30 changes: 29 additions & 1 deletion etc/fixtures/initial-seed/genomic-units.json
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,34 @@
}
]
},
{
"alphamissense_classification": [
{
"data_source": "Ensembl",
"version": 112,
"value": "ambiguous"
}
]
},
{
"alphamissense_pathogenicity": [
{
"data_source": "Ensembl",
"version": 112,
"value": 0.5303
}
]
},
{
"alphamissense": [{
"data_source": "Ensembl",
"version": 112,
"value": {
"am_class": "ambiguous",
"am_pathogenicity": "0.5303"
}
}]
},
{
"ClinVar_variant_url": [
{
Expand All @@ -480,7 +508,7 @@
{
"data_source": "Rosalution",
"version": "rosalution-manifest-00",
"value": "https://gnomad.broadinstitute.org/gene/X-151404916-G-T?dataset=gnomad_r4"
"value": "https://gnomad.broadinstitute.org/variant/X-151404916-G-T?dataset=gnomad_r4"
}
]
}
Expand Down
Binary file added frontend/src/assets/cosmic_logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 21 additions & 2 deletions frontend/src/models/analyses.js
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,13 @@ const annotationRenderingTemporary = [
'altText': 'National Center for Biotechnology Information Gene Linkout',
},
}, {
'dataset': 'COSMIC_gene_url',
'type': 'icon-linkout-dataset',
'props': {
'imageFilename': 'cosmic_logo.png',
'altText': 'Catalogue Of Somatic Mutations In Cancer, COSMIC',
},
},{

Check failure on line 326 in frontend/src/models/analyses.js

View workflow job for this annotation

GitHub Actions / nodejs-ci (20.8)

A space is required after ','
'dataset': 'gnomAD_gene_url',
'type': 'icon-linkout-dataset',
'props': {
Expand Down Expand Up @@ -423,10 +430,10 @@ const annotationRenderingTemporary = [
},
},
{
'dataset': 'AlphaMissense',
'dataset': 'alphamissense_pathogenicity',
'type': 'score-dataset',
'props': {
'label': 'AlphaMissense',
'label': 'AlphaMissense Score',
'minimum': 0,
'maximum': 1,
'bounds': {
Expand All @@ -436,6 +443,18 @@ const annotationRenderingTemporary = [
'cutoff': 1,
},
},
{
'dataset': 'alphamissense_classification',
'type': 'set-dataset',
'props': {
'label': 'AlphaMissense Pathogenicity',
'set': [
{'value': 'likely_benign', 'classification': 'Likely Benign', 'colour': 'Blue'},
{'value': 'ambiguous', 'classification': 'Ambiguous', 'colour': 'Yellow'},
{'value': 'likely_pathogenic', 'classification': 'Likely Pathogenic', 'colour': 'Red'}

Check failure on line 454 in frontend/src/models/analyses.js

View workflow job for this annotation

GitHub Actions / nodejs-ci (20.8)

Missing trailing comma
],
},
},
// {
// 'dataset': 'Phylop100',
// 'type': 'score-dataset',
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/views/AnnotationView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ import ClinvarDataset from '@/components/AnnotationView/ClinvarDataset.vue';
import IconLinkoutDataset from '@/components/AnnotationView/IconLinkoutDataset.vue';
import ImagesDataset from '@/components/AnnotationView/ImagesDataset.vue';
import ScoreDataset from '@/components/AnnotationView/ScoreDataset.vue';
import SetDataset from '@/components/AnnotationView/SetDataset.vue';
import TextDataset from '@/components/AnnotationView/TextDataset.vue';
import TranscriptDatasets from '@/components/AnnotationView/TranscriptDatasets.vue';
import InputDialog from '@/components/Dialogs/InputDialog.vue';
Expand All @@ -94,6 +95,7 @@ export default {
InputDialog,
NotificationDialog,
ScoreDataset,
SetDataset,
TextDataset,
TranscriptDatasets,
TagDataset,
Expand Down Expand Up @@ -300,6 +302,7 @@ app-header {
display: flex;
flex-direction: row;
justify-content: space-between;
flex-wrap: wrap;
}
.sidebar {
Expand Down

0 comments on commit 55cbc0b

Please sign in to comment.