-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #23 from chanzuckerberg/uermel/linkml
Add LinkML schema for metadata files and the ability to generate docs and pydantic classes from the schema.
- Loading branch information
Showing
138 changed files
with
18,414 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
.DEFAULT_GOAL := build | ||
|
||
.PHONY: clean | ||
clean: | ||
rm -rf metadata-docs | ||
rm -rf metadata_materialized.yaml | ||
rm -rf metadata_models.py | ||
|
||
.PHONY: build | ||
build: | ||
python schema.py materialize metadata.yaml common.yaml metadata_materialized.yaml | ||
gen-doc -d metadata-docs --no-mergeimports --hierarchical-class-view --stacktrace metadata_materialized.yaml | ||
gen-pydantic --pydantic-version 2 metadata_materialized.yaml > metadata_models.py | ||
black -l 88 metadata_models.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# cryoET data portal metadata schema | ||
|
||
This directory contains the metadata schema for the cryoET data portal. Browse contained classes [here](metadata-docs/index.md). | ||
|
||
Metadata file and directory layout specs: | ||
|
||
<pre> | ||
[dataset_identifier]/ | ||
|-- <a href="metadata-docs/Dataset.md">dataset_metadata.json</a> | ||
|-- [run_name]/ | ||
| |-- run_metadata.json | ||
| |-- Frames/ | ||
| | |-- [tiff|eer|mrc] | ||
| | |-- Gain_reference.mrc|dm4 | ||
| | |-- frame_acquisition_order.json | ||
| |-- TiltSeries/ | ||
| | |-- <a href="metadata-docs/TiltSeries.md">tiltseries_metadata.json</a> | ||
| | |-- [run_name].mrc | ||
| | |-- [run_name].zarr/ | ||
| | | |-- [subdirectories according to <a href="https://ngff.openmicroscopy.org/latest/">OME-NGFF spec</a> at 100%, 50% and 25% scale] | ||
| | |-- [run_name].mdoc [optional, sometimes] | ||
| | |-- [run_name].rawtlt [optional, sometimes] | ||
| | |-- [run_name].tlt [optional, sometimes] | ||
| |-- Tomograms/ | ||
| | |-- VoxelSpacing[xx.yyy] | ||
| | | |-- CanonicalTomogram | ||
| | | | |-- <a href="metadata-docs/Tomogram.md">tomogram_metadata.json</a> | ||
| | | | |-- neuroglancer_config.json | ||
| | | | |-- [run_name].mrc | ||
| | | | |-- [run_name].xf [optional, sometimes] | ||
| | | | |-- [run_name].zarr/ | ||
| | | | | |-- [subdirectories according to <a href="https://ngff.openmicroscopy.org/latest/">OME-NGFF spec</a> at 100%, 50% and 25% scale] | ||
| | | |-- Annotations/ | ||
| | | | |-- XXX_[object_name]_[version]_point.ndjson | ||
| | | | |-- <a href="metadata-docs/Annotation.md">XXX_[object_name]_[version].json</a> | ||
| | | | |-- YYY_[object_name]_[version]_segmentationmask.mrc | ||
| | | | |-- YYY_[object_name]_[version]_segmentationmask.zarr | ||
| | | | | |-- [subdirectories according to <a href="https://ngff.openmicroscopy.org/latest/">OME-NGFF spec</a> at 100%, 50% and 25% scale] | ||
| | | | |-- <a href="metadata-docs/Annotation.md">YYY_[object_name]_[version].json</a> | ||
|
||
</pre> | ||
|
||
## Building the schema and docs | ||
|
||
To build the schema, markdown docs and pydantic classes: | ||
|
||
```bash | ||
cd schema/v1.1.0 | ||
make build | ||
``` |
Oops, something went wrong.