目前一个pytorch的pt模型有两个输入 分别是 3 256 256 和 256 6 6 第一步转换已经成功了,但是第二步用以前的命令报错 -ValueError: Input layer “input_of_graph/out1_47” tensor is not set. Vim3 应该是缺少输入 不知道如何在使用 tensorzonex 的时候用两个输入
…/…/khadas/aml_npu_sdk_6.4.0.10/acuity-toolkit/bin/tensorzonex --action quantization --quantized-dtype asymmetric_affine-u8 --channel-mean-value ‘0 0 0 1’ --source text --source-file …/source_template/source.txt --model-input template.json --model-data template.data --quantized-rebuild
可以加你的微信吗?微信上面说 我微信:18781975483
不是归一化的问题,是现在 我的网络有两个 input 第一步我用这个 命令…/…/khadas/aml_npu_sdk_6.4.0.10/acuity-toolkit/bin/convertpytorch --pytorch-model detection.pt --data-output detection.data --net-output detection.json --input-size-list ‘3,287,287#256,6,6’
已经生成了对应 的 data和 json 第二步我执行上面那个脚本就报错了,因为上面那个脚本只设置了一个 source-file 但是网络有两个输入所以会报错
输入输出节点名称 我没有设置,之前我转换网络的时候也没设置过呢。
好的 thanks…
./bin/convertpytorch -h
usage: convertpytorch [-h] --pytorch-model PYTORCH_MODEL [--inputs INPUTS]
[--input-size-list INPUT_SIZE_LIST]
[--size-with-batch SIZE_WITH_BATCH] [--outputs OUTPUTS]
[--net-output NET_OUTPUT] [--data-output DATA_OUTPUT]
pytorch convert tool.
optional arguments:
-h, --help show this help message and exit
--pytorch-model PYTORCH_MODEL
pytorch traced model file
--inputs INPUTS Model Inputs, default query from model, only support
nodes which with one output tensor as input node.
--input-size-list INPUT_SIZE_LIST
Set each input tensor size list, each input size split
by #, each size split by ,Each entry in the list
should match an entry in '--inputs'
--size-with-batch SIZE_WITH_BATCH
Set each input tensor size if contain batch dim or
not, each input batch split by #,
--outputs OUTPUTS Model Outputs, default query from model, only support
nodes which with one output tensor as output node.
--net-output NET_OUTPUT
Acuity net output file
--data-output DATA_OUTPUT
Acuity net data output file
这个pytroch的转换工具本身是有inputs参数的,你可以按照tensorflow的设置看看?
./bin/convertpytorch 这个命令我已经执行成功了,
./bin/tensorzonex 这个命令我执行的时候失败了。
重点是 现在 source-file 只能配置一个 source.txt 而我有两个输入,另外一个输入没有配置 source.txt
这个是哪个版本的文档呢? 6.4.0.10版本的SDK支持吗?
嗯嗯,刚刚找到了,Vim3支持 batch 推理吗?
执行这个:aml_npu_sdk_6.4.0.10/acuity-toolkit/bin/pegasus generate inputmeta --model detection.json --separated-database True
报错了。
pegasus: error: unrecognized arguments: --separated-database True