《视觉SLAM14讲》第七讲pose_estimation_3d2d程序运行报错

对苯醌不是酚 对苯醌不是酚 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区

在运行《视觉SLAM14讲》第七讲程序的时候,出现了报错,说

In file included from /usr/local/include/g2o/core/base_fixed_sized_edge.h:278:0,
                 from /usr/local/include/g2o/core/base_unary_edge.h:30,
                 from /home/zyf/zyf/slam14/slambook_zyf/ch7/pose_estimation_3d2d.cpp:8:
/usr/local/include/g2o/core/base_fixed_sized_edge.hpp: In instantiation of ‘void g2o::BaseFixedSizedEdge<D, E, VertexTypes>::linearizeOplusN() [with int N = 0; int D = 2; E = Eigen::Matrix<double, 2, 1>; VertexTypes = {VertexPose}]’:
/usr/local/include/g2o/core/base_fixed_sized_edge.hpp:191:41:   required from ‘void g2o::BaseFixedSizedEdge<D, E, VertexTypes>::linearizeOplusNs(std::index_sequence<Ints ...>) [with long unsigned int ...Ints = {0}; int D = 2; E = Eigen::Matrix<double, 2, 1>; VertexTypes = {VertexPose}; std::index_sequence<Ints ...> = std::integer_sequence<long unsigned int, 0>]’
/usr/local/include/g2o/core/base_fixed_sized_edge.hpp:199:19:   required from ‘void g2o::BaseFixedSizedEdge<D, E, VertexTypes>::linearizeOplus() [with int D = 2; E = Eigen::Matrix<double, 2, 1>; VertexTypes = {VertexPose}]’
/home/zyf/zyf/slam14/slambook_zyf/ch7/pose_estimation_3d2d.cpp:359:1:   required from here
/usr/local/include/g2o/core/base_fixed_sized_edge.hpp:165:14: error: ‘FixedArray {aka class ceres::internal::FixedArray<double, 6>}’ has no member named ‘fill’
   add_vertex.fill(0.);
   ~~~~~~~~~~~^~~~
/usr/local/include/g2o/core/base_fixed_sized_edge.hpp:172:30: error: ‘FixedArray {aka class ceres::internal::FixedArray<double, 6>}’ has no member named ‘data’
     vertex->oplus(add_vertex.data());
                   ~~~~~~~~~~~^~~~
/usr/local/include/g2o/core/base_fixed_sized_edge.hpp:178:30: error: ‘FixedArray {aka class ceres::internal::FixedArray<double, 6>}’ has no member named ‘data’
     vertex->oplus(add_vertex.data());
                   ~~~~~~~~~~~^~~~

我也不清楚是怎么回事,重新安装了一遍g2o的库也不行,大佬们给看看是怎么回事

...全文

相关推荐

评论 12
收藏 已收藏
分享
返回顶部
对苯醌不是酚
C++ 语言 65,214 成员 250,514 内容