This may have been discussed already, but another option to represent the OME data model in RDF would be to actually port it wholesale, defining using entirely custom types/predicates. Then, you would find types from more common vocabularies and mark the OME equivalents as rdfs:subPropertyOf, owl:equivalentProperty to them.
For example, let's consider Pixels / @SizeX. In RDFS we could write this as:
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix schema: <https://schema.org/> .
@base <https://www.openmicroscopy.org/Schemas/Documentation/Generated/OME-2016-06/ome_xsd.html#> .
<sizeX> a rdf:Property ;
rdfs:label "sizeX" ;
rdfs:comment "Dimensional size of pixel data array" ;
rdfs:domain <Pixels> ;
owl:equivalentProperty schema:width .
This is easier than the current approach because:
- It's reasonably easy to take the existing XML schema and convert it into an RDFS style of schema, because every class and attribute will map to exactly one new RDF entity (There is still some difficulty in mapping XML to RDF in the cases where XML has no predicates. For example when one entity is nested inside of the other.) I will probably do this myself anyway and am happy to contribute it
- It's therefore also simple to map an instance of the schema (for example an OME-TIFF) into RDF metadata
- It retains the precise meanings defined by OME-XML
- You then don't have to choose one vocabulary at all, you can make a knowledge graph that maps OME to Schema.org, and RDFS, and DCAT
If users need better compatibility with this vocabulary (which is understandable, because existing tools won't understand ome:sizeX), one option is to use an OWL reasoner or similar to expand the predicates. This means that owl:equivalentProperty gets realised into the graph and therefore the graph is now compatible with the other vocabularies. Thus
Gets expanded to:
foo ome:sizeX 10 ;
schema:width 10;
Alternatively, they can just write the schema.org version directly and we can infer back the other way:
This may have been discussed already, but another option to represent the OME data model in RDF would be to actually port it wholesale, defining using entirely custom types/predicates. Then, you would find types from more common vocabularies and mark the OME equivalents as
rdfs:subPropertyOf,owl:equivalentPropertyto them.For example, let's consider
Pixels / @SizeX. In RDFS we could write this as:This is easier than the current approach because:
If users need better compatibility with this vocabulary (which is understandable, because existing tools won't understand
ome:sizeX), one option is to use an OWL reasoner or similar to expand the predicates. This means thatowl:equivalentPropertygets realised into the graph and therefore the graph is now compatible with the other vocabularies. ThusGets expanded to:
Alternatively, they can just write the schema.org version directly and we can infer back the other way: