Files
observer/server/biz/model/entity/model_version.go
T

23 lines
1.6 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package entity
import "github.com/gogf/gf/v2/os/gtime"
// ModelVersion 模型版本:每数据集全局共用版本序列(s/n 交替发布同一序列,UNIQUE(dataset_id, version)),
// is_latest 按 (数据集, 档位) 各记一条。
// 模型文件不落表:训练成功即直写 trainings/<文件名前缀>.tflites 档)/<文件名前缀>_n.tfliten 档,
// 前缀空回退数据集名,无存档回退机制);labels 为类别名数组 JSON(App 多模型合并推理依赖)。
type ModelVersion struct {
Id int64 `json:"id" orm:"id" description:"自增主键"`
DatasetId int64 `json:"datasetId" orm:"dataset_id" description:"所属数据集"`
Variant string `json:"variant" orm:"variant" description:"档位 s|n"`
Version string `json:"version" orm:"version" description:"m1.0.0 递增"`
TrainingId int64 `json:"trainingId" orm:"training_id" description:"来源训练任务"`
Metrics string `json:"metrics" orm:"metrics" description:"JSON 指标"`
Labels string `json:"labels" orm:"labels" description:"JSON 类别名数组"`
Sha256 string `json:"sha256" orm:"sha256" description:"tflite 文件校验"`
SizeBytes int64 `json:"sizeBytes" orm:"size_bytes" description:"文件大小"`
IsLatest int `json:"isLatest" orm:"is_latest" description:"1=该(数据集,档位)当前生效"`
Notes string `json:"notes" orm:"notes" description:"备注"`
CreatedAt *gtime.Time `json:"createdAt" orm:"created_at" description:"发布时间"`
}