yucao42 / g2o_pose_optimization Goto Github PK
View Code? Open in Web Editor NEWUse g2o to optimize the camera pose. Initial guess is from EPnP.
License: Other
Use g2o to optimize the camera pose. Initial guess is from EPnP.
License: Other
Hi, and thank you for making this code available. I realise this is an old repo, but it is exactly what I am trying to do (calculate very accurate extrinsics of two different cameras using pnp with a chessboard, and optimisation).
I use a checkerboard, however, instead of board with dots/circles.
I see in the g2o edge function:
g2o_pose_optimization/src/Optimizer.cpp
Line 184 in 59b1c34
you have:
e->Xw[0] = (float)( (i%7)* 8);//8mm each with 7 circles a row
e->Xw[1] = (float)(i%7?row:++row)*8;
e->Xw[2] = (float)(0);
I assume that I need to change this. My checkerboard is:
int grid_size_x = 7;
int grid_size_y = 5;
double squareSize = 0.045; //4.5 cm
for (int y = 0; y < grid_size_y; y++)
{
for (int x = 0; x < grid_size_x; x++)
{
object_points_.push_back(cv::Point3f(x * squareSize, y * squareSize, 0));
}
}
How would I go about changing your code to use this board?
Aside from the findCircles
to findChessboardCorners
, is there anything else that I should need to adjust?
Thanks again!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.