PaddleCV/rcnn: Invoke operator conv2d error
Created by: CerrieJ
rcnn目录下执行命令:
python infer.py --pretrained_model=imagenet_resnet50_fusebn/bn2a_branch1_offset --image_path=dataset/coco/val2017/000000527784.jpg --draw_threshold=0.6
出现以下错误: `----------- Configuration Arguments ----------- MASK_ON: False anchor_sizes: [32, 64, 128, 256, 512] aspect_ratios: [0.5, 1.0, 2.0] batch_size_per_im: 512 class_num: 81 data_dir: dataset/coco dataset: coco2017 draw_threshold: 0.6 enable_ce: False im_per_batch: 1 image_path: dataset/coco/val2017/000000527784.jpg learning_rate: 0.01 log_window: 20 max_iter: 180000 max_size: 1333 model_save_dir: output nms_thresh: 0.5 padding_minibatch: False parallel: True pixel_means: [102.9801, 115.9465, 122.7717] pretrained_model: imagenet_resnet50_fusebn/bn2a_branch1_offset rpn_nms_thresh: 0.7 rpn_stride: [16.0, 16.0] scales: [800] score_thresh: 0.05 snapshot_stride: 10000 use_gpu: True use_profile: False use_pyreader: True variance: [1.0, 1.0, 1.0, 1.0]
loading annotations into memory... Done (t=0.55s) creating index... index created! W0805 17:37:38.763368 29134 device_context.cc:259] Please NOTE: device: 0, CUDA Capability: 61, Driver API Version: 10.0, Runtime API Version: 10.0 W0805 17:37:38.765338 29134 device_context.cc:267] device: 0, cuDNN Version: 7.5. Traceback (most recent call last): File "infer.py", line 96, in infer() File "infer.py", line 76, in infer return_numpy=False) File "/home/cambricon/anaconda3/lib/python3.7/site-packages/paddle/fluid/executor.py", line 651, in run use_program_cache=use_program_cache) File "/home/cambricon/anaconda3/lib/python3.7/site-packages/paddle/fluid/executor.py", line 749, in run exe.run(program.desc, scope, 0, True, True, fetch_var_name) paddle.fluid.core_avx.EnforceNotMet: Invoke operator conv2d error. Python Callstacks: File "/home/cambricon/anaconda3/lib/python3.7/site-packages/paddle/fluid/framework.py", line 1771, in append_op attrs=kwargs.get("attrs", None)) File "/home/cambricon/anaconda3/lib/python3.7/site-packages/paddle/fluid/layer_helper.py", line 43, in append_op return self.main_program.current_block().append_op(*args, **kwargs) File "/home/cambricon/anaconda3/lib/python3.7/site-packages/paddle/fluid/layers/nn.py", line 2181, in conv2d 'fuse_relu_before_depthwise_conv': False File "/home/cambricon/workSpace/paddlepaddleModels/models/PaddleCV/rcnn/models/resnet.py", line 71, in conv_affine_layer name=name + '.conv2d.output.1') File "/home/cambricon/workSpace/paddlepaddleModels/models/PaddleCV/rcnn/models/resnet.py", line 144, in add_ResNet50_conv4_body body_input, ch_out=64, filter_size=7, stride=2, padding=3, name="conv1") File "/home/cambricon/workSpace/paddlepaddleModels/models/PaddleCV/rcnn/models/model_builder.py", line 39, in build_model body_conv = self.add_conv_body_func(self.image) File "infer.py", line 49, in infer model.build_model(image_shape) File "infer.py", line 96, in infer() C++ Callstacks: holder should not be null Tensor not initialized yet when Tensor::type() is called. at [/paddle/paddle/fluid/framework/tensor.h:139] PaddlePaddle Call Stacks: 0 0x7f6ad524ee78p void paddle::platform::EnforceNotMet::Initstd::string(std::string, char const*, int) + 360 1 0x7f6ad524f1c7p paddle::platform::EnforceNotMet::EnforceNotMet(std::string const&, char const*, int) + 87 2 0x7f6ad524fbfbp paddle::framework::Tensor::type() const + 107 3 0x7f6ad567677bp paddle::operators::ConvOp::GetExpectedKernelType(paddle::framework::ExecutionContext const&) const + 299 4 0x7f6ad72db04bp paddle::framework::OperatorWithKernel::ChooseKernel(paddle::framework::RuntimeContext const&, paddle::framework::Scope const&, boost::variant<paddle::platform::CUDAPlace, paddle::platform::CPUPlace, paddle::platform::CUDAPinnedPlace, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_> const&) const + 235 5 0x7f6ad72dd1b8p paddle::framework::OperatorWithKernel::RunImpl(paddle::framework::Scope const&, boost::variant<paddle::platform::CUDAPlace, paddle::platform::CPUPlace, paddle::platform::CUDAPinnedPlace, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_> const&, paddle::framework::RuntimeContext*) const + 728 6 0x7f6ad72dd431p paddle::framework::OperatorWithKernel::RunImpl(paddle::framework::Scope const&, boost::variant<paddle::platform::CUDAPlace, paddle::platform::CPUPlace, paddle::platform::CUDAPinnedPlace, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_> const&) const + 529 7 0x7f6ad72daa2cp paddle::framework::OperatorBase::Run(paddle::framework::Scope const&, boost::variant<paddle::platform::CUDAPlace, paddle::platform::CPUPlace, paddle::platform::CUDAPinnedPlace, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_> const&) + 332 8 0x7f6ad53d973ep paddle::framework::Executor::RunPreparedContext(paddle::framework::ExecutorPrepareContext*, paddle::framework::Scope*, bool, bool, bool) + 382 9 0x7f6ad53dc7dfp paddle::framework::Executor::Run(paddle::framework::ProgramDesc const&, paddle::framework::Scope*, int, bool, bool, std::vector<std::string, std::allocatorstd::string > const&, bool) + 143 10 0x7f6ad523ffddp 11 0x7f6ad5281286p 12 0x564f8634d6e4p _PyMethodDef_RawFastCallKeywords + 612 13 0x564f8634d801p _PyCFunction_FastCallKeywords + 33 14 0x564f863a97aep _PyEval_EvalFrameDefault + 21374 15 0x564f862ea4f9p _PyEval_EvalCodeWithName + 761 16 0x564f8634ca27p _PyFunction_FastCallKeywords + 903 17 0x564f863a58fep _PyEval_EvalFrameDefault + 5326 18 0x564f862ea4f9p _PyEval_EvalCodeWithName + 761 19 0x564f8634ca27p _PyFunction_FastCallKeywords + 903 20 0x564f863a58fep _PyEval_EvalFrameDefault + 5326 21 0x564f862eadb9p _PyEval_EvalCodeWithName + 3001 22 0x564f8634ca27p _PyFunction_FastCallKeywords + 903 23 0x564f863a4846p _PyEval_EvalFrameDefault + 1046 24 0x564f862ea4f9p _PyEval_EvalCodeWithName + 761 25 0x564f862eb3c4p PyEval_EvalCodeEx + 68 26 0x564f862eb3ecp PyEval_EvalCode + 28 27 0x564f86403874p 28 0x564f8640db81p PyRun_FileExFlags + 161 29 0x564f8640dd73p PyRun_SimpleFileExFlags + 451 30 0x564f8640ee5fp 31 0x564f8640ef7cp _Py_UnixMain + 60 32 0x7f6b05686830p __libc_start_main + 240 33 0x564f863b4122p`