按照文档https://modelbox-ai.com/modelbox-book/cases/emotion-detection.html进行了表情识别的样例的实践,在开发环境中通过打包应用,生产了一个deb安装包和一个tar包;然后将deb文件和tar包文件拷贝到modelbox/modelbox-runtime-libtorch_1.9.1-cuda_10.2-ubuntu-x86_64:latest此镜像启动的容器内进行部署,部署步骤如下:
1、dpkg -i modelbox-application-1.0.0-Linux-emotion.deb
2、tar -xzvf modelbox-application-1.0.0-Linux.tar.gz
3、modelbox-tool -verbose INFO flow -run /opt/modelbox/application/emotion/graph/emotion.toml
结果在执行3时报错:
[2022-11-08 06:29:15,497][ INFO][ flow.cc:97 ] run flow /opt/modelbox/application/emotion/graph/emotion.toml
[2022-11-08 06:29:15,500][ INFO][ driver.cc:152 ] wait for subprocess 67 process finished
[2022-11-08 06:29:15,974][ INFO][ driver.cc:61 ] scan process log:
[2022-11-08 06:29:15.500][ INFO][ driver.cc:889 ] Scan dir: /opt/modelbox/application/emotion/flowunit
[2022-11-08 06:29:15.500][ INFO][ driver.cc:889 ] Scan dir: /usr/local/lib
[2022-11-08 06:29:15.506][ WARN][ driver.cc:1112] /usr/local/lib/libmodelbox-common-cpu-iam_auth.so : dlsym DriverDescription failed, /usr/local/lib/libmodelbox-common-cpu-iam_auth.so: undefined symbol: DriverDescription
[2022-11-08 06:29:15.509][ WARN][ driver.cc:1112] /usr/local/lib/libmodelbox-drivers-common-filerequester.so.1.0.0 : dlsym DriverDescription failed, /usr/local/lib/libmodelbox-drivers-common-filerequester.so.1.0.0: undefined symbol: DriverDescription
[2022-11-08 06:29:15.510][ WARN][ driver.cc:1112] /usr/local/lib/libmodelbox-drivers-common-fuse.so.1.0.0 : dlsym DriverDescription failed, /usr/local/lib/libmodelbox-drivers-common-fuse.so.1.0.0: undefined symbol: DriverDescription
[2022-11-08 06:29:15.560][ WARN][ driver.cc:1112] /usr/local/lib/libmodelbox-unit-cpu-obs_client.so : dlsym DriverDescription failed, /usr/local/lib/libmodelbox-unit-cpu-obs_client.so: undefined symbol: DriverDescription
[2022-11-08 06:29:15.576][ WARN][ driver.cc:1097] /usr/local/lib/libmodelbox-unit-cpu-python.so.1.0.0 : dlopen failed, libpython3.7m.so.1.0: cannot open shared object file: No such file or directory
[2022-11-08 06:29:15,976][ INFO][ driver.cc:764 ] Gather scan info success, drivers count 45
[2022-11-08 06:29:15,976][ INFO][ driver.cc:1010] begin scan virtual drivers
[2022-11-08 06:29:15,978][ INFO][virtualdriver_inference.cc:80 ] Add virtual driver /opt/modelbox/application/emotion/flowunit/face_detect/face_detect.toml success
[2022-11-08 06:29:15,981][ INFO][virtualdriver_inference.cc:80 ] Add virtual driver /opt/modelbox/application/emotion/flowunit/emotion_infer/emotion_infer.toml success
[2022-11-08 06:29:15,985][ WARN][ driver.cc:1045] virtual driver init failed, code: Not found, errmsg: can not find python flowunit
[2022-11-08 06:29:15,986][ INFO][virtualdriver_python.cc:86 ] Add virtual driver /opt/modelbox/application/emotion/flowunit/draw_emotion/draw_emotion.toml success
[2022-11-08 06:29:15,987][ INFO][virtualdriver_python.cc:86 ] Add virtual driver /opt/modelbox/application/emotion/flowunit/face_post/face_post.toml success
[2022-11-08 06:29:15,988][ INFO][virtualdriver_python.cc:86 ] Add virtual driver /opt/modelbox/application/emotion/flowunit/collapse_emotion/collapse_emotion.toml success
[2022-11-08 06:29:15,989][ INFO][virtualdriver_python.cc:86 ] Add virtual driver /opt/modelbox/application/emotion/flowunit/custom_resize/custom_resize.toml success
[2022-11-08 06:29:15,990][ INFO][virtualdriver_python.cc:86 ] Add virtual driver /opt/modelbox/application/emotion/flowunit/expand_box/expand_box.toml success
[2022-11-08 06:29:15,999][ INFO][ driver.cc:1012] end scan virtual drivers
[2022-11-08 06:29:16,346][ WARN][virtualdriver_python.cc:308 ] the key group type is empty, so classify it into Undefined.
[2022-11-08 06:29:16,346][ WARN][ flowunit.cc:515 ] is not match, you can use a-z, A-Z, 1-9, _ and uppercase the first character.
[2022-11-08 06:29:16,346][ WARN][ flowunit.cc:396 ] check group type failed , your group_type is , the right group_type is a or a/b , for instance input or input/http.
[2022-11-08 06:29:16,347][ WARN][virtualdriver_python.cc:308 ] the key group type is empty, so classify it into Undefined.
[2022-11-08 06:29:16,347][ WARN][ flowunit.cc:515 ] is not match, you can use a-z, A-Z, 1-9, _ and uppercase the first character.
[2022-11-08 06:29:16,347][ WARN][ flowunit.cc:396 ] check group type failed , your group_type is , the right group_type is a or a/b , for instance input or input/http.
[2022-11-08 06:29:16,348][ WARN][virtualdriver_python.cc:308 ] the key group type is empty, so classify it into Undefined.
[2022-11-08 06:29:16,348][ WARN][ flowunit.cc:515 ] is not match, you can use a-z, A-Z, 1-9, _ and uppercase the first character.
[2022-11-08 06:29:16,348][ WARN][ flowunit.cc:396 ] check group type failed , your group_type is , the right group_type is a or a/b , for instance input or input/http.
[2022-11-08 06:29:16,348][ WARN][virtualdriver_python.cc:308 ] the key group type is empty, so classify it into Undefined.
[2022-11-08 06:29:16,348][ WARN][ flowunit.cc:515 ] is not match, you can use a-z, A-Z, 1-9, _ and uppercase the first character.
[2022-11-08 06:29:16,348][ WARN][ flowunit.cc:396 ] check group type failed , your group_type is , the right group_type is a or a/b , for instance input or input/http.
[2022-11-08 06:29:16,349][ WARN][virtualdriver_python.cc:308 ] the key group type is empty, so classify it into Undefined.
[2022-11-08 06:29:16,349][ WARN][ flowunit.cc:515 ] is not match, you can use a-z, A-Z, 1-9, _ and uppercase the first character.
[2022-11-08 06:29:16,349][ WARN][ flowunit.cc:396 ] check group type failed , your group_type is , the right group_type is a or a/b , for instance input or input/http.
[2022-11-08 06:29:16,352][ INFO][ graph_manager.cc:353 ] graph.format : graphviz
[2022-11-08 06:29:16,353][ INFO][ graph.cc:116 ] Build graph name:emotion_detection, id:faa75409-0052-417e-856c-81735f04d805
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : collapse_emotion
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : confidence
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : predicts
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : custom_resize
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : draw_emotion
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_emotion
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_face
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : emotion_infer
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : input
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : confidence
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : predicts
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : expand_box
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : roi_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : face_detect
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : input
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_cls
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_conf
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_loc
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : face_mean
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : face_normalize
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : face_post
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_cls
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_conf
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_loc
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : has_face
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : no_face
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : face_resize
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : face_transpose
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : image_transpose
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_image
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : mean
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : normalize
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_data
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : video_input
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_video_url
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : videodecoder
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_video_packet
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_video_frame
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : videodemuxer
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_video_url
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:271 ] output port : out_video_packet
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:260 ] node name : videoencoder
[2022-11-08 06:29:16,353][ INFO][ graph_manager.cc:265 ] input port : in_video_frame
[2022-11-08 06:29:16,353][ INFO][ graph.cc:641 ] begin build node collapse_emotion
[2022-11-08 06:29:16,354][ WARN][virtualdriver_python.cc:308 ] the key group type is empty, so classify it into Undefined.
[2022-11-08 06:29:16,354][ WARN][ flowunit.cc:515 ] is not match, you can use a-z, A-Z, 1-9, _ and uppercase the first character.
[2022-11-08 06:29:16,354][ WARN][ flowunit.cc:396 ] check group type failed , your group_type is , the right group_type is a or a/b , for instance input or input/http.
[2022-11-08 06:29:16,354][ WARN][flowunit_manager.cc:342 ] CreateFlowUnit: collapse_emotion failed, code: Not found, errmsg: not found flowunit collapse_emotion
[2022-11-08 06:29:16,354][ERROR][ graph.cc:644 ] code: Not found, errmsg: create flowunit 'collapse_emotion' failed.
[2022-11-08 06:29:16,354][ERROR][ flow.cc:537 ] build graph failed, Not found, build graph failed, please check graph config. -> create flowunit 'collapse_emotion' failed. -> not found flowunit collapse_emotion
[2022-11-08 06:29:16,354][ERROR][ flow.cc:106 ] build flow failed, Not found, build graph failed, please check graph config. -> create flowunit 'collapse_emotion' failed. -> not found flowunit collapse_emotion
想知道是什么原因,该如何成功部署这个服务?谢谢!