TNN icon indicating copy to clipboard operation
TNN copied to clipboard

Error: layer_interpreter nil name: type_from_str: type:0; Error: param is nil; Error Init layer LeakyRelu_3 (err: 4096 or 0x1000)

Open wwdok opened this issue 3 years ago • 2 comments

1. 环境(environment)

  • Build OS and Version: Windows 10
  • RunTime OS Version: Windows 10
  • RunTime DEVICE: Windows 10

2. Github版本

  • branch:master
  • commit(optional):2022/9/14克隆的

3. 编译方式(compile method) CMake完整编译参数(full cmake arguments) 参考 https://github.com/Tencent/TNN/blob/master/doc/cn/user/compile.md#%E5%85%ADwindows-%E7%8E%AF%E5%A2%83%E7%BC%96%E8%AF%91 ,就是执行了.\build_msvc_native.bat

4. 编译日志(build log)

将日志粘贴在这里
Paste log here or pastebin
**********************************************************************
** Visual Studio 2019 Developer Command Prompt v16.11.15
** Copyright (c) 2021 Microsoft Corporation
**********************************************************************
[vcvarsall.bat] Environment initialized for: 'x64'

C:\Program Files (x86)\Microsoft Visual Studio\2019\Community>D:

D:\>cd D:\AI\repos\TNN\scripts

D:\AI\repos\TNN\scripts>.\build_msvc_native.bat

D:\AI\repos\TNN\scripts>set TNN_DIR=D:\AI\repos\TNN\scripts\..\
D:\AI\repos\TNN\scripts\..\
ECHO 处于关闭状态。
-- The C compiler identification is MSVC 19.29.30145.0
-- The CXX compiler identification is MSVC 19.29.30145.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- The ASM compiler identification is MSVC
-- Found assembler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe
D:/AI/repos/TNN
D:/AI/repos/TNN
-- >>>>>>>>>>>>>
-- TNN BUILD INFO:
--      System: Windows
--      Processor:
--      Cpu:    ON
--      X86:    ON
--      Arm:    OFF
--      Arm82:  OFF
--      Metal:  OFF
--      OpenCL: OFF
--      CUDA:   OFF
--      DSP:    OFF
--      Atlas:  OFF
--      TensorRT:       OFF
--      AppleNPU:       OFF
--      HuaweiNPU:      OFF
--      RKNPU:  OFF
--      OpenVINO:       OFF
--      OpenMP: OFF
--      TEST:   ON
--      --Unit Test:    OFF
--      Quantization:   OFF
--      ModelCheck:     OFF
--      DEBUG:
--      PROFILE:        OFF
--      BENCHMARK:      OFF
--      BENCHMARK Layer:        OFF
--      Model Converter:        OFF
--      ONNX2TNN Converter:     OFF
--      TNN2MEM:        OFF
--      BENCHMARK Test Lib:     OFF
--      Dynamic Range Quantization:     OFF
-- Configuring done
-- Generating done
-- Build files have been written to: D:/AI/repos/TNN/scripts/build_win
[18/608] Building CXX object CMakeFiles\TNN.dir\source\tnn\core\blob_manager.cc.obj
省略,详见txt
[608/608] Linking CXX executable test\TNNTest.exe

log.txt

5. 详细描述bug 情况 (Describe the bug) 在加载模型时出现了如题所示这个报错,模型文件是用docker的tnn-convert:latest转换出来的: model.zip

6. 运行日志(runtime log)

将日志粘贴在这里
Paste log here or pastebin
E/tnn: tnn::ModelInterpreter::InterpretModel [File source\tnn\interpreter\tnn\model_interpreter.cc][Line 448] Error: layer_interpreter nil name: type_from_str: type:0
E/tnn: tnn::X86PReluLayerAcc::Init [File source\tnn\device\x86\acc\x86_prelu_layer_acc.cc][Line 67] Error: param is nil
E/tnn: tnn::DefaultNetwork::InitLayers [File source\tnn\core\default_network.cc][Line 333] Error Init layer LeakyRelu_3 (err: 4096 or 0x1000)
TNN init failed 4096

7. 截图(Screenshots)

将截图粘贴在这里
Paste screenshorts here or pastebin

image

wwdok avatar Sep 29 '22 09:09 wwdok

这个问题似乎是windows才有的问题,我在ubuntu上重新做了一遍就没有这个报错

wwdok avatar Oct 12 '22 07:10 wwdok

我在安卓上也遇到了類似的問題。err code 4096 or 0x1000 代表什麼在哪裡找得到? image

iamjoseph331 avatar Nov 16 '22 03:11 iamjoseph331