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

std::vector<>::_M_realloc_insert (segmentation fault) when try to optimize velodyne16 data #2

Open
xiaodidia opened this issue Sep 22, 2020 · 1 comment

Comments

@xiaodidia
Copy link

Hello@Michael. I am testing SSA on my own mapping system. I can successfully build ssa on Ubuntu18.04, generate vertex and edge smoothly. When come to ssa.graph().optimize(), it broke down with "segmentation fault". GDB shows below. I found out that function linearizeOplus() in edge_se3_xyzcov.h is not implemented. What is wrong with all this? Hope you can see this issue. Thank you.
// -----------------------------------------GDB bt ---------------------------------------------------------
(gdb) bt
#0 0x0000555555716229 in void std::vector<Eigen::Transform<double, 3, 1, 0>, Eigen::aligned_allocator<Eigen::Transform<double, 3, 1, 0> > >::_M_realloc_insert<Eigen::Transform<double, 3, 1, 0> const&>(__gnu_cxx::__normal_iterator<Eigen::Transform<double, 3, 1, 0>, std::vector<Eigen::Transform<double, 3, 1, 0>, Eigen::aligned_allocator<Eigen::Transform<double, 3, 1, 0> > > >, Eigen::Transform<double, 3, 1, 0> const&) ()
#1 0x00007ffff2d8f088 in g2o::SparseOptimizer::push(std::vector<g2o::OptimizableGraph::Vertex
, std::allocatorg2o::OptimizableGraph::Vertex* >&) ()
from /usr/local/lib/libg2o_core.so
#2 0x00007ffff2d983a3 in g2o::OptimizationAlgorithmLevenberg::solve(int, bool) () from /usr/local/lib/libg2o_core.so
#3 0x00007ffff2d9014d in g2o::SparseOptimizer::optimize(int, bool) () from /usr/local/lib/libg2o_core.so
#4 0x0000555555730a5f in ssa::SparseSurfaceAdjustmentT<g2o::EdgeSE3, ssa::EdgeSE3PointXYZCov, ssa::EdgePointXYZCovPointXYZCov>::optimize(int) ()
#5 0x00005555556d3676 in ssaSmooth(std::vector<boost::shared_ptr<pcl::PointCloudpcl::PointXYZI >, std::allocator<boost::shared_ptr<pcl::PointCloudpcl::PointXYZI > > >, std::vector<poseGraph::StampedTransform, std::allocatorposeGraph::StampedTransform >) ()
#6 0x00005555556c3965 in main ()
// -----------------------------------------GDB bt ---------------------------------------------------------

@RainerKuemmerle
Copy link

g2o's code changed in the past years. This might break SSA.
You might wanna try to use https://github.com/RainerKuemmerle/g2o/releases/tag/20140601_beforeMergeHierarchical when cloning g2o. Change https://github.com/MichaelRuhnke/ssa/blob/master/EXTERNAL/CMakeLists.txt accordingly.
Maybe @MichaelRuhnke has more infos :-)

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