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

RE2022-232: Add biolog endpoints to service #420

Merged
merged 1 commit into from
Aug 16, 2023
Merged
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
33 changes: 33 additions & 0 deletions src/common/storage/collection_and_field_names.py
Original file line number Diff line number Diff line change
Expand Up @@ -302,3 +302,36 @@

FLD_KB_SAMPLE_ID = "kbase_sample_id"
""" Key name for KBase sample id """


### biolog

_BIOLOG_COLL_PREFIX = COLLECTION_PREFIX + "biolog_"

COLL_BIOLOG_META: Annotated[
str,
COLL_ANNOTATION,
{
COLL_ANNOKEY_DESCRIPTION: "A collection holding Biolog heatmap metadata.",
COLL_ANNOKEY_SUGGESTED_SHARDS: 1,
}

] = _BIOLOG_COLL_PREFIX + "meta"

COLL_BIOLOG_DATA: Annotated[
str,
COLL_ANNOTATION,
{
COLL_ANNOKEY_DESCRIPTION: "A collection holding Biolog heatmap data.",
COLL_ANNOKEY_SUGGESTED_SHARDS: 3,
}
] = _BIOLOG_COLL_PREFIX + "data"

COLL_BIOLOG_CELLS: Annotated[
str,
COLL_ANNOTATION,
{
COLL_ANNOKEY_DESCRIPTION: "A collection holding Biolog heatmap cell detail data.",
COLL_ANNOKEY_SUGGESTED_SHARDS: 3,
}
] = _BIOLOG_COLL_PREFIX + "cells"
1 change: 1 addition & 0 deletions src/service/data_product_specs.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
"src.service.data_products.taxa_count": "TAXA_COUNT_SPEC",
"src.service.data_products.genome_attributes": "GENOME_ATTRIBS_SPEC",
"src.service.data_products.microtrait": "MICROTRAIT_SPEC",
"src.service.data_products.biolog": "BIOLOG_SPEC",
"src.service.data_products.samples": "SAMPLES_SPEC",
}

Expand Down
16 changes: 16 additions & 0 deletions src/service/data_products/biolog.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
"""
The Biolog data product.
"""

import src.common.storage.collection_and_field_names as names
from src.service.data_products.heatmap import HeatMapController

_BIOLOG_CONTROLLER = HeatMapController(
"biolog",
"Biolog",
names.COLL_BIOLOG_META,
names.COLL_BIOLOG_DATA,
names.COLL_BIOLOG_CELLS,
)

BIOLOG_SPEC = _BIOLOG_CONTROLLER.get_data_product_spec()