Tencent / ncnn

ncnn is a high-performance neural network inference framework optimized for the mobile platform
Other
20.13k stars 4.14k forks source link

how to use insight-face resnet50/100 models #3278

Open MyraBaba opened 2 years ago

MyraBaba commented 2 years ago

detail | 详细描述 | 詳細な説明

Hi, @nihui I try to convert buffalo model to ncnn model and try to get 512 feature but got error:

find_blob_index_by_name BatchNormalization_129 failed

Try ex.extract("683", out0);

Process returned -1073741819 (0xC0000005) execution time : 3.297 s

Question is : how we can use https://github.com/deepinsight/insightface/tree/master/model_zoo models in ncnn C++ ?

Screen Shot 2021-10-11 at 17 15 19
MyraBaba commented 2 years ago

@nihui I converted onnx to ncnn model. I wonder is there any accuracy lost in ncnn from original ingiht-face model run ?

Best

nihui commented 1 month ago

针对onnx模型转换的各种问题,推荐使用最新的pnnx工具转换到ncnn In view of various problems in onnx model conversion, it is recommended to use the latest pnnx tool to convert your model to ncnn

pip install pnnx
pnnx model.onnx inputshape=[1,3,224,224]

详细参考文档 Detailed reference documentation https://github.com/pnnx/pnnx https://github.com/Tencent/ncnn/wiki/use-ncnn-with-pytorch-or-onnx#how-to-use-pnnx