Browse Source

Merge pull request 'gpu-inference' (#2523) from gpu-inference into V20220718

Reviewed-on: https://git.openi.org.cn/OpenI/aiforge/pulls/2523
Reviewed-by: lewis <747342561@qq.com>
pull/2526/head
lewis 2 years ago
parent
commit
9f201ff6c2
1 changed files with 9 additions and 0 deletions
  1. +9
    -0
      routers/repo/cloudbrain.go

+ 9
- 0
routers/repo/cloudbrain.go View File

@@ -731,6 +731,15 @@ func cloudBrainShow(ctx *context.Context, tpName base.TplName, jobType models.Jo
ctx.Data["resource_type"] = resourceType.Value ctx.Data["resource_type"] = resourceType.Value
} }
} }
for _, specialPool := range cloudbrain.SpecialPools.Pools {

for _, resourceType := range specialPool.Pool {
if resourceType.Queue == jobRes.Config.GpuType {
ctx.Data["resource_type"] = resourceType.Value
}
}
}

} else if task.JobType == string(models.JobTypeInference) { } else if task.JobType == string(models.JobTypeInference) {
if inferenceGpuInfos == nil { if inferenceGpuInfos == nil {
json.Unmarshal([]byte(setting.InferenceGpuTypes), &inferenceGpuInfos) json.Unmarshal([]byte(setting.InferenceGpuTypes), &inferenceGpuInfos)


Loading…
Cancel
Save