|
|
|
@@ -106,7 +106,6 @@ func GrampusNotebookCreate(ctx *context.Context, form auth.CreateGrampusNotebook |
|
|
|
image := strings.TrimSpace(form.Image) |
|
|
|
|
|
|
|
codeStoragePath := setting.CBCodePathPrefix + jobName + cloudbrain.CodeMountPath + "/" |
|
|
|
modelStoragePath := setting.CBCodePathPrefix + jobName + cloudbrain.ModelMountPath + "/" |
|
|
|
|
|
|
|
tpl := tplGrampusNotebookGPUNew |
|
|
|
processType := grampus.ProcessorTypeGPU |
|
|
|
@@ -223,12 +222,6 @@ func GrampusNotebookCreate(ctx *context.Context, form auth.CreateGrampusNotebook |
|
|
|
ctx.RenderWithErr(ctx.Tr("cloudbrain.load_code_failed"), tpl, &form) |
|
|
|
return |
|
|
|
} |
|
|
|
errStr := initModelPath(jobName, cloudbrain.ModelMountPath) |
|
|
|
if errStr != "" { |
|
|
|
grampusNotebookNewDataPrepare(ctx, processType) |
|
|
|
ctx.RenderWithErr(ctx.Tr(errStr), tpl, &form) |
|
|
|
return |
|
|
|
} |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
@@ -258,7 +251,6 @@ func GrampusNotebookCreate(ctx *context.Context, form auth.CreateGrampusNotebook |
|
|
|
Spec: spec, |
|
|
|
CodeStoragePath: codeStoragePath, |
|
|
|
CodeName: strings.ToLower(repo.Name), |
|
|
|
ModelPath: modelStoragePath + README, |
|
|
|
} |
|
|
|
|
|
|
|
if form.ModelName != "" { //使用预训练模型训练 |
|
|
|
|