ms-types 0.4.2 → 0.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/types/yolo.d.ts
CHANGED
|
@@ -47,6 +47,22 @@ declare namespace yolo {
|
|
|
47
47
|
*/
|
|
48
48
|
classId: number;
|
|
49
49
|
}
|
|
50
|
+
/**
|
|
51
|
+
* 加载YOLO模型
|
|
52
|
+
* @param paramPath ncnn模型的param文件的绝对路径
|
|
53
|
+
* @param binPath ncnn模型的bin文件绝对路径
|
|
54
|
+
* @param nc 模型的标签数量,可在标签集data.yaml中看到
|
|
55
|
+
* @param version 模型版本,默认11, 支持 8 11 26
|
|
56
|
+
* @returns 加载成功返回模型ID字符串,失败返回null
|
|
57
|
+
* @example
|
|
58
|
+
* const modelId = yolo.load("yolov8n.param", "yolov8n.bin", 80)
|
|
59
|
+
*/
|
|
60
|
+
function load(
|
|
61
|
+
paramPath: string,
|
|
62
|
+
binPath: string,
|
|
63
|
+
nc: number,
|
|
64
|
+
version?: number
|
|
65
|
+
): string | null;
|
|
50
66
|
/**
|
|
51
67
|
* 加载YOLOv11模型 (兼容 yolov8 模型)
|
|
52
68
|
* @param paramPath ncnn模型的param文件的绝对路径
|
|
@@ -50,6 +50,23 @@ declare namespace $YOLO {
|
|
|
50
50
|
classId: 数字;
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
+
/**
|
|
54
|
+
* 加载YOLO模型
|
|
55
|
+
* @param ncnn模型的param文件路径 ncnn模型的param文件的绝对路径
|
|
56
|
+
* @param ncnn模型的bin文件路径 ncnn模型的bin文件绝对路径
|
|
57
|
+
* @param 标签数量 模型的标签数量,可在标签集data.yaml中看到
|
|
58
|
+
* @param 模型版本 模型版本,默认11, 支持 8 11 26
|
|
59
|
+
* @returns 加载成功返回模型ID字符串,失败返回null
|
|
60
|
+
* @example
|
|
61
|
+
* const 模型ID = $YOLO.加载模型("yolov8n.param", "yolov8n.bin", 80)
|
|
62
|
+
*/
|
|
63
|
+
function 加载模型(
|
|
64
|
+
ncnn模型的param文件路径: 字符串,
|
|
65
|
+
ncnn模型的bin文件路径: 字符串,
|
|
66
|
+
标签数量: 数字,
|
|
67
|
+
模型版本?: 数字
|
|
68
|
+
): 字符串 | null;
|
|
69
|
+
|
|
53
70
|
/**
|
|
54
71
|
* 加载YOLOv11模型 (兼容 yolov8 模型)
|
|
55
72
|
* @param ncnn模型的param文件路径
|