rknn-toolkit2 icon indicating copy to clipboard operation
rknn-toolkit2 copied to clipboard

ArgMax可以转换,但运行返回None

Open AllentDan opened this issue 1 year ago • 0 comments

你好。在给 mmdeploy 支持rockchip, rk3588s 的时候,1.2版本的toolkit2中支持的op包括了ArgMax,但是用ONNX转模型OK,运行时产生如下错误:

I Connect to Device success!
I NPUTransfer: Starting NPU Transfer Client, Transfer version 2.1.0 (b5861e7@2020-11-23T11:50:36)
D NPUTransfer: Transfer spec = local:transfer_proxy
D NPUTransfer: Transfer interface successfully opened, fd = 18
D RKNNAPI: ==============================================
D RKNNAPI: RKNN VERSION:
D RKNNAPI:   API: 1.2.0 (4c3573e build: 2022-01-13 20:03:13)
D RKNNAPI:   DRV: rknn_server: 1.2.0 (4c3573e build: 2022-01-14 11:09:48)
D RKNNAPI:   DRV: rknnrt: 1.2.0 (1867aec5b@2022-01-14T15:16:40)
D RKNNAPI: ==============================================
D NPUTransfer: The connection has been closed, socket read fd = 18
D NPUTransfer: Transfer client closed, fd = 18
E RKNNAPI: __pthread_recv_msg,  recv(MsgHeader) fail, -9(ERROR_PIPE) < 108!
E RKNNAPI: rknn_outputs_get,  p_ctx->queue_output.size() = 0!
E inference: Catch exception when getting outputs.
E inference: Traceback (most recent call last):
E inference:   File "rknn/api/rknn_base.py", line 2122, in rknn.api.rknn_base.RKNNBase.inference
E inference:   File "rknn/api/rknn_runtime.py", line 491, in rknn.api.rknn_runtime.RKNNRuntime.get_outputs
E inference: Exception: E Get outputs failed, error code: RKNN_ERR_FAIL

直接将模型放到C++中运行,报错如下:

model input num: 1, output num: 1
input tensors:
  index=0, name=input, n_dims=4, dims=[1, 512, 512, 3], n_elems=786432, size=3145728, fmt=NHWC, type=FP32, qnt_type=AFFINE, zp=0, scale=1.000000
output tensors:
E RKNN: [01:31:19.504] input dtype is undefine!
E RKNN: [01:31:19.504] Unknow dtype to get bytes: 0
  index=0, name=output, n_dims=4, dims=[1, 1, 512, 512], n_elems=262144, size=-262144, fmt=NCHW, type=UNKNOW, qnt_type=AFFINE, zp=0, scale=1.000000
E RKNN: [01:31:20.113] output dtype is undefine!

希望得到贵司的快速响应。

AllentDan avatar Sep 27 '22 09:09 AllentDan