|
|
@@ -99,6 +99,7 @@ func createTrainJob(modelConvert *models.AiModelConvert, ctx *context.Context, m |
|
|
|
mkModelPath(modelPath) |
|
|
|
uploadCodeToMinio(modelPath, modelConvert.ID, ModelMountPath+"/") |
|
|
|
command := getModelConvertCommand(modelConvert.ID, modelConvert.ModelPath) |
|
|
|
log.Info("command=" + command) |
|
|
|
dataActualPath := setting.Attachment.Minio.RealPath + modelRelativePath |
|
|
|
|
|
|
|
if TrainResourceSpecs == nil { |
|
|
@@ -170,7 +171,7 @@ func createTrainJob(modelConvert *models.AiModelConvert, ctx *context.Context, m |
|
|
|
func getModelConvertCommand(name string, modelFile string) string { |
|
|
|
var command string |
|
|
|
bootFile := "convert_pytorch.py" |
|
|
|
command += "python /code/" + bootFile + " --model " + modelFile + " > " + ModelMountPath + "/" + name + "-" + LogFile |
|
|
|
command += "python3 /code/" + bootFile + " --model " + modelFile + " > " + ModelMountPath + "/" + name + "-" + LogFile |
|
|
|
return command |
|
|
|
} |
|
|
|
|
|
|
|