You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We wanted to load a schema.org schema (https://schema.org/version/latest/schemaorg-current-https.ttl) using get_ontology().load(), but it returns an empty object. If we change the "Class" prefix to "owl" and the "rdfs:label" to "skos:prefLabel" it does load all the classes. The only difference with loading an emmo ontology is that the label has to be retrieved from get_preferred_label() instead of "prefLabel". Would be convenient if other ontologies could also be loaded directly from the original turtle files.
An example on what we had to change:
schema:AMRadioChannel a rdfs:Class ;
rdfs:label "AMRadioChannel" ;
to:
schema:AMRadioChannel a owl:Class ;
skos:prefLabel "AMRadioChannel" ;
The text was updated successfully, but these errors were encountered:
However I see the same thing that you do when trying to list all the classes etc.
Some digging into owlready2 shows that there itis hardcoded that it looks for owl:classes.
I have to think a little about how to circumvent that. Hopefully direct access as shown above is useful for you.
We wanted to load a schema.org schema (https://schema.org/version/latest/schemaorg-current-https.ttl) using
get_ontology().load()
, but it returns an empty object. If we change the "Class" prefix to "owl" and the "rdfs:label" to "skos:prefLabel" it does load all the classes. The only difference with loading an emmo ontology is that the label has to be retrieved fromget_preferred_label()
instead of "prefLabel". Would be convenient if other ontologies could also be loaded directly from the original turtle files.An example on what we had to change:
schema:AMRadioChannel a rdfs:Class ;
rdfs:label "AMRadioChannel" ;
to:
schema:AMRadioChannel a owl:Class ;
skos:prefLabel "AMRadioChannel" ;
The text was updated successfully, but these errors were encountered: