用官方的PointNet网络编译pointnet_lib.so报错error: ‘GradOpPtr’ has not been declared
Created by: a178052771
- 版本、环境信息: 1)PaddlePaddle版本:1.7.1 2)CUDA:9.0 3)cuDNN:7.3 4)系统环境:Linux16.4、Python版本2.7
- 安装方式信息: 1)pip安装
- 复现信息:按github的步骤在~/models-develop/PaddleCV/3d_vision/PointNet++/ext_op/src里用sh make.sh编译
- 报错信息: (tensorflow) xz@xz:~/models-develop/PaddleCV/3d_vision/PointNet++/ext_op/src$ sh make.sh /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/libs gather_point_op.cc:97:14: error: ‘GradOpPtr’ has not been declared void Apply(GradOpPtr op) const override { ^ gather_point_op.cc:97:23: error: expected ‘,’ or ‘...’ before ‘<’ token void Apply(GradOpPtr op) const override { ^ gather_point_op.cc: In member function ‘void paddle::operators::GatherPointGradDescMaker::Apply(int) const’: gather_point_op.cc:99:5: error: ‘op’ was not declared in this scope op->SetType("gather_point_grad"); ^ gather_point_op.cc: In instantiation of ‘class paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc’: /usr/include/c++/4.8/type_traits:1287:12: required from ‘struct std::is_base_of<paddle::framework::OperatorBase, paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc >’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:74:25: required from ‘constexpr const bool paddle::framework::details::internal::IsMatchedBaseTypeImpl<paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc, 0, true>::kValue’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:86:63: required from ‘constexpr bool paddle::framework::details::internal::IsMatchedBaseType() [with T = paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc; int kPos = 0]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:118:54: required by substitution of ‘template using OpInfoFillTypeGetter = paddle::framework::details::internal::OpInfoFillTypeGetterImpl<T, 0, 8, false, IsMatchedBaseType<T, 0>()> [with T = paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:125:47: required from ‘static constexpr paddle::framework::details::OpInfoFillType paddle::framework::details::OpInfoFillTypeID::ID() [with T = paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:144:71: recursively required from ‘paddle::framework::details::OperatorRegistrarRecursive<I, false, ARGS ...>::OperatorRegistrarRecursive(const char*, paddle::framework::OpInfo*) [with long unsigned int I = 1ul; ARGS = {paddle::operators::GatherPointOp, paddle::operators::GatherPointOpMaker, paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc, paddle::operators::GatherPointGradDescMakerpaddle::imperative::OpBase}]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:144:71: required from ‘paddle::framework::details::OperatorRegistrarRecursive<I, false, ARGS ...>::OperatorRegistrarRecursive(const char*, paddle::framework::OpInfo*) [with long unsigned int I = 0ul; ARGS = {paddle::operators::GatherPointOp, paddle::operators::GatherPointOpMaker, paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc, paddle::operators::GatherPointGradDescMakerpaddle::imperative::OpBase}]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/op_registry.h:63:5: required from ‘paddle::framework::OperatorRegistrar::OperatorRegistrar(const char*) [with ARGS = {paddle::operators::GatherPointOp, paddle::operators::GatherPointOpMaker, paddle::operators::GatherPointGradDescMakerpaddle::framework::OpDesc, paddle::operators::GatherPointGradDescMakerpaddle::imperative::OpBase}]’ gather_point_op.cc:112:1: required from here gather_point_op.cc:97:8: error: ‘void paddle::operators::GatherPointGradDescMaker::Apply(int) const [with T = paddle::framework::OpDesc]’ marked override, but does not override void Apply(GradOpPtr op) const override { ^ group_points_op.cc:105:14: error: ‘GradOpPtr’ has not been declared void Apply(GradOpPtr op) const override { ^ group_points_op.cc:105:23: error: expected ‘,’ or ‘...’ before ‘<’ token void Apply(GradOpPtr op) const override { ^ group_points_op.cc: In member function ‘void paddle::operators::GroupPointsGradDescMaker::Apply(int) const’: group_points_op.cc:106:5: error: ‘op’ was not declared in this scope op->SetType("group_points_grad"); ^ group_points_op.cc: In instantiation of ‘class paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc’: /usr/include/c++/4.8/type_traits:1287:12: required from ‘struct std::is_base_of<paddle::framework::OperatorBase, paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc >’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:74:25: required from ‘constexpr const bool paddle::framework::details::internal::IsMatchedBaseTypeImpl<paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc, 0, true>::kValue’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:86:63: required from ‘constexpr bool paddle::framework::details::internal::IsMatchedBaseType() [with T = paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc; int kPos = 0]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:118:54: required by substitution of ‘template using OpInfoFillTypeGetter = paddle::framework::details::internal::OpInfoFillTypeGetterImpl<T, 0, 8, false, IsMatchedBaseType<T, 0>()> [with T = paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:125:47: required from ‘static constexpr paddle::framework::details::OpInfoFillType paddle::framework::details::OpInfoFillTypeID::ID() [with T = paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:144:71: recursively required from ‘paddle::framework::details::OperatorRegistrarRecursive<I, false, ARGS ...>::OperatorRegistrarRecursive(const char*, paddle::framework::OpInfo*) [with long unsigned int I = 1ul; ARGS = {paddle::operators::GroupPointsOp, paddle::operators::GroupPointsOpMaker, paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc, paddle::operators::GroupPointsGradDescMakerpaddle::imperative::OpBase}]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:144:71: required from ‘paddle::framework::details::OperatorRegistrarRecursive<I, false, ARGS ...>::OperatorRegistrarRecursive(const char*, paddle::framework::OpInfo*) [with long unsigned int I = 0ul; ARGS = {paddle::operators::GroupPointsOp, paddle::operators::GroupPointsOpMaker, paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc, paddle::operators::GroupPointsGradDescMakerpaddle::imperative::OpBase}]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/op_registry.h:63:5: required from ‘paddle::framework::OperatorRegistrar::OperatorRegistrar(const char*) [with ARGS = {paddle::operators::GroupPointsOp, paddle::operators::GroupPointsOpMaker, paddle::operators::GroupPointsGradDescMakerpaddle::framework::OpDesc, paddle::operators::GroupPointsGradDescMakerpaddle::imperative::OpBase}]’ group_points_op.cc:119:1: required from here group_points_op.cc:105:8: error: ‘void paddle::operators::GroupPointsGradDescMaker::Apply(int) const [with T = paddle::framework::OpDesc]’ marked override, but does not override void Apply(GradOpPtr op) const override { ^ three_interp_op.cc:120:14: error: ‘GradOpPtr’ has not been declared void Apply(GradOpPtr op) const override { ^ three_interp_op.cc:120:23: error: expected ‘,’ or ‘...’ before ‘<’ token void Apply(GradOpPtr op) const override { ^ three_interp_op.cc: In member function ‘void paddle::operators::ThreeInterpGradDescMaker::Apply(int) const’: three_interp_op.cc:121:5: error: ‘op’ was not declared in this scope op->SetType("three_interp_grad"); ^ three_interp_op.cc: In instantiation of ‘class paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc’: /usr/include/c++/4.8/type_traits:1287:12: required from ‘struct std::is_base_of<paddle::framework::OperatorBase, paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc >’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:74:25: required from ‘constexpr const bool paddle::framework::details::internal::IsMatchedBaseTypeImpl<paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc, 0, true>::kValue’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:86:63: required from ‘constexpr bool paddle::framework::details::internal::IsMatchedBaseType() [with T = paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc; int kPos = 0]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:118:54: required by substitution of ‘template using OpInfoFillTypeGetter = paddle::framework::details::internal::OpInfoFillTypeGetterImpl<T, 0, 8, false, IsMatchedBaseType<T, 0>()> [with T = paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:125:47: required from ‘static constexpr paddle::framework::details::OpInfoFillType paddle::framework::details::OpInfoFillTypeID::ID() [with T = paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:144:71: recursively required from ‘paddle::framework::details::OperatorRegistrarRecursive<I, false, ARGS ...>::OperatorRegistrarRecursive(const char*, paddle::framework::OpInfo*) [with long unsigned int I = 1ul; ARGS = {paddle::operators::ThreeInterpOp, paddle::operators::ThreeInterpOpMaker, paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc, paddle::operators::ThreeInterpGradDescMakerpaddle::imperative::OpBase}]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/details/op_registry.h:144:71: required from ‘paddle::framework::details::OperatorRegistrarRecursive<I, false, ARGS ...>::OperatorRegistrarRecursive(const char*, paddle::framework::OpInfo*) [with long unsigned int I = 0ul; ARGS = {paddle::operators::ThreeInterpOp, paddle::operators::ThreeInterpOpMaker, paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc, paddle::operators::ThreeInterpGradDescMakerpaddle::imperative::OpBase}]’ /home/xz/.conda/envs/tensorflow/lib/python2.7/site-packages/paddle/include/paddle/fluid/framework/op_registry.h:63:5: required from ‘paddle::framework::OperatorRegistrar::OperatorRegistrar(const char*) [with ARGS = {paddle::operators::ThreeInterpOp, paddle::operators::ThreeInterpOpMaker, paddle::operators::ThreeInterpGradDescMakerpaddle::framework::OpDesc, paddle::operators::ThreeInterpGradDescMakerpaddle::imperative::OpBase}]’ three_interp_op.cc:135:1: required from here three_interp_op.cc:120:8: error: ‘void paddle::operators::ThreeInterpGradDescMaker::Apply(int) const [with T = paddle::framework::OpDesc]’ marked override, but does not override void Apply(GradOpPtr op) const override {