Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[g2opy] Error when loading .g2o file using optimizer.load() function #793

Open
Lky0724 opened this issue May 15, 2024 · 1 comment
Open

Comments

@Lky0724
Copy link

Lky0724 commented May 15, 2024

I am trying to run notebook_slam2d.ipynb in pymem branch to learn to use g2o. But something went wrong when I try to load the pose graph, which was stored in a .g2o file under the same directory, into the optimizer. Even though no error was reported, it seems that the file is not successfully loaded (returned number of vertices and edges are 0), and the visualization of the data in the following part also shows nothing.

Below is the code and output.

optimizer.clear()
optimizer.load("manhattanOlson3500.g2o")
print(f"Number of vertices: {len(optimizer.vertices())}")
print(f"Number of edges {len(optimizer.edges())}")

Number of vertices: 0
Number of edges 0

What can I do with it? Besides, is there a detailed documentation of the avaliable functions in g2o and its python binding?
Thank you very much for your help!

@RainerKuemmerle
Copy link
Owner

Which version of g2o did you compile/use? It might be related to #764 - maybe there is yet another issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants