MNN icon indicating copy to clipboard operation
MNN copied to clipboard

Invalidate buffer to create MNN Module

Open HanGuangXin opened this issue 1 year ago • 6 comments

使用./GetMNNInfo my_model.mnn 报错 Invalidate buffer to create MNN Module

平台(如果交叉编译请再附上交叉编译目标平台): Linux

Platform(Include target platform as well if cross-compiling): Linux

Github版本: 2.9.1

Github Version: 2.9.1

直接下载ZIP包请提供下载日期以及压缩包注释里的git版本(可通过7z l zip包路径命令并在输出信息中搜索Comment 获得,形如Comment = bc80b11110cd440aacdabbf59658d630527a7f2b)。 git clone请提供 git commit 第一行的commit id

Provide date (or better yet, git revision from the comment section of the zip. Obtainable using 7z l PATH/TO/ZIP and search for Comment in the output) if downloading source as zip,otherwise provide the first commit id from the output of git commit

编译方式: git clone; mkdir build && cd build && cmake .. && make -j8

Compiling Method

请在这里粘贴cmake参数或使用的cmake脚本路径以及完整输出
Paste cmake arguments or path of the build script used here as well as the full log of the cmake proess here or pastebin

编译日志:

Build Log:

粘贴在这里
Paste log here or pastebin

HanGuangXin avatar Jun 04 '24 12:06 HanGuangXin

my_model.mnn 是如何得到的?

jxt1234 avatar Jun 05 '24 03:06 jxt1234

my_model.mnn 是如何得到的?

jxt1234 avatar Jun 05 '24 03:06 jxt1234

my_model.mnn 是如何得到的?

jxt1234 avatar Jun 05 '24 03:06 jxt1234

'mnnconvert -f ONNX --modelFile {} --MNNModel {} --bizCode MNN --keepInputFormat --testdir onnx'.format(onnx_path, mnn_path)

这个命令转的,先从Torch转onnx,然后onnx转mnn。 得到的mnn模型使用./GetMNNInfo my_model.mnn 报错 Invalidate buffer to create MNN Module @jxt1234

HanGuangXin avatar Jun 05 '24 08:06 HanGuangXin

另外onnx模型的推理结果是正确的,check过了

HanGuangXin avatar Jun 05 '24 08:06 HanGuangXin

看上去是 pymnn 的版本和 C++ 的 mnn 版本不一致,python 的更新。C++ 的更新并重编一下看看

jxt1234 avatar Jun 21 '24 01:06 jxt1234

Marking as stale. No activity in 60 days.

github-actions[bot] avatar Aug 20 '24 09:08 github-actions[bot]