解密模型包到文件 - YoloDecryptModel
函数简介
解密加密包,写出明文主模型、可选 NCNN param 与类别名表。
接口名称
YoloDecryptModel
DLL 调用
int YoloDecryptModel(long ola, string packagePath, string password, string modelOutPath, string ncnnParamOutPath, string namesLabelOutPath, int* modelType, int* inferenceType);
参数说明
| 参数名 | 类型 | 说明 |
|---|---|---|
| ola | 长整数型 | OLAPlug 对象指针,由 CreateCOLAPlugInterFace 生成。 |
| packagePath | 字符串 | 加密包路径 |
| password | 字符串 | 解密密码 |
| modelOutPath | 字符串 | 明文主模型输出路径 |
| ncnnParamOutPath | 字符串 | NCNN .param 输出,可空 |
| namesLabelOutPath | 字符串 | 类别名表输出,可空 |
| modelType | 整数型* | 输出:模型类型 |
| inferenceType | 整数型* | 输出:推理类型 |
返回值
整数型:1 成功,0 失败。
注意事项
- 需要插件已开通 Yolos 模块权限。
| 值 | 含义 |
|---|---|
| 0 | TensorRT Engine(.engine) |
| 1 | ONNX(.onnx) |
| 2 | NCNN(.bin + .param 双文件) |
| 值 | 含义 |
|---|---|
| 0 | Detect 目标检测 |
| 1 | Classify 图像分类 |
| 2 | Segment 实例分割 |
| 3 | Pose 姿态估计 |
| 4 | Obb 旋转框检测 |
