Skip to content

Commit

Permalink
Added semdata.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
jesper-friis committed Oct 15, 2024
1 parent 69e4cdb commit 828e8ef
Show file tree
Hide file tree
Showing 2 changed files with 76 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/dataset/test_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
inputdir = testdir / "input"


# if True:
def test_save_and_load_dataset():
if True:
# def test_save_and_load_dataset():
"""Test save_dataset() and load_dataset()."""
# pylint: disable=too-many-locals,invalid-name

Expand All @@ -23,7 +23,8 @@ def test_save_and_load_dataset():
ts = Triplestore("rdflib")

# Load data documentation
datadoc = load_datadoc(inputdir / "datasets.yaml")
# datadoc = load_datadoc(inputdir / "datasets.yaml")
datadoc = load_datadoc(inputdir / "semdata.yaml")
assert isinstance(datadoc, dict)
assert "@context" in datadoc

Expand Down
72 changes: 72 additions & 0 deletions tests/input/semdata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
---
# This extends the list of prefixes that are already defined in the context
prefixes:
sem: "https://w3id.com/emmo/domain/sem/0.1#"
semdata: "https://he-matchmaker.eu/data/sem/"
sample: "https://he-matchmaker.eu/sample/"
mat: "https://he-matchmaker.eu/material/"
dm: "http://onto-ns.com/meta/characterisation/0.1/SEMImage#"
parser: "http://sintef.no/dlite/parser#"

# List of documented datasets
datasets:
- "@id": "semdata:SEM_cement_batch2/77600-23-001/77600-23-001_5kV_400x_m001"
"@type": "https://w3id.com/emmo/domain/sem/0.1#SEMImage"
title: SEM image of cement
description: |
Back-scattered SEM image of cement sample 77600 from Heidelberg,
polished with 1 µm diamond compound.
creator: Sigurd Wenner
contactPoint: "Sigurd Wenner <[email protected]>"
inSeries: "semdata:SEM_cement_batch2/77600-23-001"

datamodel: http://onto-ns.com/meta/characterisation/0.1/SEMImage
mappingURL: https://raw.githubusercontent.com/HEU-MatCHMaker/DataDocumentation/refs/heads/master/SEM/datamodels/SEMImage.ttl

# Contextual documentation of the dataset
statements:
- ["@id", "sem:fromSample", "sample:SEM_cement_batch2/77600-23-001"]
- ["@id", "emmo:isDescriptionOf", "mat:concrete1"]

distribution:
downloadURL: "file://SEM_cement_batch2/77600-23-001/77600-23-001_5kV_400x_m001.tif"
mediaType: image/tiff
parser: "parser:sem_hitachi"


- "@id": "semdata:SEM_cement_batch2/77600-23-001"
"@type": "https://w3id.com/emmo/domain/sem/0.1#SEMImageSeries"
title: Series of SEM image of cement sample 77600
description: Back-scattered SEM image of cement sample 77600, polished with 1 µm diamond compound.
creator: Sigurd Wenner
contactPoint: "Sigurd Wenner <[email protected]>"
inSeries: "semdata:SEM_cement_batch2"

distribution:
downloadURL: "file://SEM_cement_batch2/77600-23-001"
mediaType: inode/directory


- "@id": "semdata:SEM_cement_batch2"
"@type": "https://w3id.com/emmo/domain/sem/0.1#SEMImageSeries"
title: Series of SEM images of cement batch2
description: ...
creator: Sigurd Wenner
contactPoint: "Sigurd Wenner <[email protected]>"

distribution:
downloadURL: "file://SEM_cement_batch2"
mediaType: inode/directory


- "@id": "sample:SEM_cement_batch2/77600-23-001"
"@type": "chameo:Sample"
title:


parsers:
- "@id": "parser:sem_hitachi"
"@type": "oteio:Parser"
parserType: application/vnd.dlite-parse
configuration:
driver: hitachi

0 comments on commit 828e8ef

Please sign in to comment.