Giter Site home page Giter Site logo

Comments (4)

Rezenders avatar Rezenders commented on September 28, 2024

[pipeline_inspection_reasoner-1] [ERROR] [1673533577.337098677] [pipeline_inspection_reasoner]: Error in perform_reasoning: 'NoneType' object is not subscriptable

This error is also happening with lower rates, but less frequently. Unfortunately, I don't have any more info.
My guess is that is has something to do with reading/writing from/to the ontology.

from mc_mros_reasoner.

Rezenders avatar Rezenders commented on September 28, 2024
[pipeline_inspection_reasoner]: In Analyze, exception returned: 'NoneType' object is not subscriptable

from mc_mros_reasoner.

alexander-gabriel avatar alexander-gabriel commented on September 28, 2024

This looks like a concurrency error.
That should be easy enough to test.

If it is a concurrency error, there is some guidance:

https://owlready2.readthedocs.io/en/latest/sync.html?highlight=concurrent#synchronization
says:

  1. Open the quadstore in non-exclusive mode (exclusive = False in set_backend()).
  2. Perform each modification to an ontology inside a “with ontology:” block. Owlready maintain a lock for each quadstore, which prevents multiple writes at the same time. Thus, for improving performances, you should also avoid long computation inside “with ontology:” blocks.
  3. Call World.save() at the end of each “with ontology:” block, in order to commit the changes to the quadstore database.

that means you'd have to adjust

def load_kb_from_file(kb_file):

like so

world = World()
world.set_backend(filename = "/path/to/your/file.sqlite3", exclusive = False)

and also adjust the the rest that accesses the backend according to points 2 and 3...

from mc_mros_reasoner.

alexander-gabriel avatar alexander-gabriel commented on September 28, 2024

that still would not allow you to run the thing faster though, just with more waiting and fewer bugs.

Regardless of whether or not your current problem is caused by concurrency...in the context of ROS that's always a problem. So this should be concurrency safe anyway.

from mc_mros_reasoner.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.