ValueError: Cannot parse blank node _b1l: unknown node type!

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

ValueError: Cannot parse blank node _b1l: unknown node type!

Citlalli
Hi,

I'm trying to a access the clases of the OGG and I get the ValueError in the subject. I would much appreciate if someone could help to access this ontology.

This is the link to OGG:

https://bitbucket.org/hegroup/ogg/raw/master/ogg-merged.owl


Best regards!
Reply | Threaded
Open this post in threaded view
|

Re: ValueError: Cannot parse blank node _b1l: unknown node type!

Jiba
Administrator
Hello,

I've tested your ontology with the script below, listing successfully all classes and their superclasses and equivalence, and all properties.

Could you send me a small script that causes the error, please?


from owlready2 import *

onto_path.append("/tmp")

onto = get_ontology("/tmp/ogg-merged.owl").load()

for Prop in onto.properties():
  print(Prop, Prop.is_a, Prop.equivalent_to, Prop.domain, Prop.range)

for Class in onto.classes():
  print(Class, Class.is_a, Class.equivalent_to)

Best regards,
Jean-Baptiste Lamy
MCF, LIMICS, Université Paris 13
Reply | Threaded
Open this post in threaded view
|

Re: ValueError: Cannot parse blank node _b1l: unknown node type!

Citlalli
Hi Jean-Baptiste,

Thanks for your quick reply. I could access the classes with your script.

The script that rose the error was this:


from owlready2 import *

onto = get_ontology('file:///Users/cma/Documents/GRO/ogg-merged.owl').load()
for clas in onto.classes():
print (clas)

I usually load ontologies this way. It works with GO.  Is the loading way the cause of the error?

Best regards,
Citlalli
Reply | Threaded
Open this post in threaded view
|

Re: ValueError: Cannot parse blank node _b1l: unknown node type!

Jiba
Administrator
Hello,

I've tested your version of the script, and I obtain the same result... Are you sure you were using the same version of Owlready ? The last version added support for some types of blank nodes, so using an older version might caused the error you obtained.

Best regards,
Jean-Baptiste Lamy
MCF, LIMICS, Université Paris 13

> Hi Jean-Baptiste,
>
> Thanks for your quick reply. I could access the classes with your script.
>
> The script that rose the error was this:
>
>
> from owlready2 import *
>
> onto = get_ontology('file:///Users/cma/Documents/GRO/ogg-merged.owl').load()
> for clas in onto.classes():
> print (clas)
>
> I usually load ontologies this way. It works with GO.  Is the loading way
> the cause of the error?
>
> Best regards,
> Citlalli
>
>
>
> _______________________________________________
> If you reply to this email, your message will be added to the discussion below:
> http://owlready.8326.n8.nabble.com/ValueError-Cannot-parse-blank-node-b1l-unknown-node-type-tp113p115.html
> To start a new topic under Owlready, email [hidden email]
> To unsubscribe from Owlready, visit
Reply | Threaded
Open this post in threaded view
|

Re: ValueError: Cannot parse blank node _b1l: unknown node type!

Citlalli
Hi Jean-Baptiste,

I made another script, loading the ontology the way I usually do and the same owlready2 version, and the bnode error didn't arise . Maybe it was because I have many calculated stuff in the kernel.

Best regards.