paddleDetection 基于paddle-serving 部署问题
环境 CUDA 11.6 cudnn 8.4.1 显卡:GTX 1080 python 3.6 paddle-bfloat 0.1.7 paddle-serving-app 0.9.0 paddle-serving-client 0.9.0 paddle-serving-server-gpu 0.9.0.post112 paddlelite 2.9 paddlepaddle-gpu 2.3.2.post116
用paddle训练的Picodet模型,通过python -m paddle_serving_client.convert --dirname --model_filename --params_filename --serving_server serving_server --serving_client serving_client命令将inference模型转为了server模型。 发现一个问题会出现lod报错。具体如下: 1、当我用pipeline方式部署,fetch_dict中没有fetch_name.lod这个键,{'transpose_7.tmp_0': array([[[ 2.0223362 , 1.5683302 , -0.40058073, ..., 0.0507356 , 0.8766475 , 0.8922676 ], [ 0.34861326, 1.7860167 , 1.4869571 , ..., 0.00460189, 0.7187939 , 0.8137586 ], [-0.44164556, -0.7165884 , 1.3838978 , ..., 0.16071278, 0.63282794, 0.6942027 ], ..., [-0.20754977, -0.4660724 , -0.4744862 , ..., -0.3195387 , 0.04248828, 0.16745234], [-0.13426918, -0.3694974 , -0.39638266, ..., -0.26385802, 0.04389518, 0.20333196], [-0.18678631, -0.376009 , -0.3708608 , ..., -0.18855351, 0.13031027, 0.27454522]]], dtype=float32)}
也就是没有lod信息,client与server通讯时,出现报错 Traceback (most recent call last): File "../../deploy/serving/test_client.py", line 49, in postprocess(fetch_map) File "/usr/local/lib/python3.6/site-packages/paddle_serving_app/reader/image_reader.py", line 427, in call self.clsid2catid) File "/usr/local/lib/python3.6/site-packages/paddle_serving_app/reader/image_reader.py", line 344, in _get_bbox_result lod = [fetch_map[fetch_name + '.lod']] KeyError: 'transpose_7.tmp_0.lod'
2、当我用非pipeline方式部署时, server通讯时可以正常启动, 客户端也是后处理部分报错{'err_no': 10000, 'err_msg': 'Log_id: 10000 Raise_msg: transpose_0.tmp_0 ClassName: Op._run_postprocess..postprocess_help FunctionName: postprocess_help', 'key': [], 'value': [], 'tensors': []}
请教下各位同学,第一次部署服务, 按照文档调整,不知道是什么问题导致的, 请各位帮忙看下