From 9802ee0cd97f261f6717700f48d5a06312c264b5 Mon Sep 17 00:00:00 2001 From: chenshihai Date: Mon, 22 Aug 2022 14:45:43 +0800 Subject: [PATCH 1/3] Resources Management --- .../pages/resources/components/SceneDialog.vue | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/web_src/vuepages/pages/resources/components/SceneDialog.vue b/web_src/vuepages/pages/resources/components/SceneDialog.vue index 81507c368..3f20756fb 100644 --- a/web_src/vuepages/pages/resources/components/SceneDialog.vue +++ b/web_src/vuepages/pages/resources/components/SceneDialog.vue @@ -38,7 +38,8 @@ {{ $t('resourcesManagement.exclusiveOrg') }}
- +
@@ -146,14 +147,15 @@ export default { v: `${item.QueueCode}(${getListValueWithKey(this.clusterList, item.Cluster)} - ${item.AiCenterName})`, }); } - if (this.dataInfo.Cluster === 'C2Net') { - list.unshift({ - k: '-1', - v: this.$t('resourcesManagement.allResQueue'), - }); - } + list.unshift({ + k: '-1', + v: this.$t('resourcesManagement.allResQueue'), + }); this.queueList.splice(0, Infinity, ...list); if (next) { + if (this.type === 'add') { + this.dataInfo.QueueId = '-1'; + } this.getResSpecificationList(); } } @@ -195,7 +197,7 @@ export default { this.dataInfo.SpecIds = []; this.queueList.splice(0, Infinity); this.specsList.splice(0, Infinity); - this.getQueueList(); + this.getQueueList(true); }, changeQueue() { this.dataInfo.SpecIds = []; From 918c979c4f22987b274eb8656c94937e0595129f Mon Sep 17 00:00:00 2001 From: chenshihai Date: Thu, 25 Aug 2022 14:50:33 +0800 Subject: [PATCH 2/3] specs useage --- templates/custom/task_wait_count.tmpl | 25 ++++++++++++++++++++++ templates/repo/cloudbrain/benchmark/new.tmpl | 10 +++++++-- templates/repo/cloudbrain/inference/new.tmpl | 5 ++++- templates/repo/cloudbrain/new.tmpl | 9 +++++--- templates/repo/cloudbrain/trainjob/new.tmpl | 5 ++++- templates/repo/grampus/trainjob/gpu/new.tmpl | 29 ++++++++++++++++++++++---- templates/repo/grampus/trainjob/npu/new.tmpl | 29 ++++++++++++++++++++++---- templates/repo/grampus/trainjob/show.tmpl | 16 ++++++++++++-- templates/repo/modelarts/inferencejob/new.tmpl | 5 ++++- templates/repo/modelarts/notebook/new.tmpl | 5 ++++- templates/repo/modelarts/trainjob/new.tmpl | 5 ++++- web_src/js/standalone/specsuse.js | 4 ++-- 12 files changed, 125 insertions(+), 22 deletions(-) create mode 100644 templates/custom/task_wait_count.tmpl diff --git a/templates/custom/task_wait_count.tmpl b/templates/custom/task_wait_count.tmpl new file mode 100644 index 000000000..74d1060ce --- /dev/null +++ b/templates/custom/task_wait_count.tmpl @@ -0,0 +1,25 @@ +
+
+ + {{.i18n.Tr "repo.wait_count_start"}} {{.WaitCount}} {{.i18n.Tr "repo.wait_count_end"}} +
+
+ diff --git a/templates/repo/cloudbrain/benchmark/new.tmpl b/templates/repo/cloudbrain/benchmark/new.tmpl index 7c7bee0da..0d85c8615 100755 --- a/templates/repo/cloudbrain/benchmark/new.tmpl +++ b/templates/repo/cloudbrain/benchmark/new.tmpl @@ -51,9 +51,12 @@ {{.i18n.Tr "repo.cloudbrain.benchmark.model"}} - {{template "custom/wait_count_train" Dict "ctx" $ "type" .benchmark_gpu_types}}
+
+ + {{template "custom/task_wait_count" .}} +
{{.i18n.Tr "repo.cloudbrain.benchmark.model"}}
- {{template "custom/wait_count_train" Dict "ctx" $ "type" .benchmark_gpu_types}}
+
+ + {{template "custom/task_wait_count" .}} +
Ascend NPU
- {{template "custom/wait_count_train" Dict "ctx" $ "type" .inference_gpu_types}} +
+
+ + {{template "custom/task_wait_count" .}}
diff --git a/templates/repo/cloudbrain/new.tmpl b/templates/repo/cloudbrain/new.tmpl index f1c59550f..94e7ba5a7 100755 --- a/templates/repo/cloudbrain/new.tmpl +++ b/templates/repo/cloudbrain/new.tmpl @@ -25,7 +25,7 @@
{{template "base/alert" .}} -
+
@@ -55,8 +55,11 @@ d="M3 2.992C3 2.444 3.445 2 3.993 2h16.014a1 1 0 0 1 .993.992v18.016a.993.993 0 0 1-.993.992H3.993A1 1 0 0 1 3 21.008V2.992zM19 11V4H5v7h14zm0 2H5v7h14v-7zM9 6h6v2H9V6zm0 9h6v2H9v-2z" /> Ascend NPU -
- {{template "custom/wait_count" .}} +
+
+
+ + {{template "custom/task_wait_count" .}}
diff --git a/templates/repo/cloudbrain/trainjob/new.tmpl b/templates/repo/cloudbrain/trainjob/new.tmpl index 8fa599eba..d3167b88d 100755 --- a/templates/repo/cloudbrain/trainjob/new.tmpl +++ b/templates/repo/cloudbrain/trainjob/new.tmpl @@ -116,7 +116,10 @@ Ascend NPU
- {{template "custom/wait_count_train" Dict "ctx" $ "type" .train_gpu_types}} + +
+ + {{template "custom/task_wait_count" .}}
diff --git a/templates/repo/grampus/trainjob/gpu/new.tmpl b/templates/repo/grampus/trainjob/gpu/new.tmpl index 6dd928f65..6ed44196d 100755 --- a/templates/repo/grampus/trainjob/gpu/new.tmpl +++ b/templates/repo/grampus/trainjob/gpu/new.tmpl @@ -30,7 +30,9 @@ .width81{ width: 81% !important; } - +.width48{ + width: 48.5% !important; +} .add{font-size: 18px; padding: 0.5rem; border: 1px solid rgba(187, 187, 187, 100); @@ -105,7 +107,10 @@ Ascend NPU
- {{template "custom/wait_count_train" Dict "ctx" $}} + +
+ + {{template "custom/task_wait_count" .}}
@@ -174,8 +179,7 @@
- -
+ +
+ +
@@ -212,6 +220,7 @@
{{template "base/footer" .}} + \ No newline at end of file diff --git a/templates/repo/grampus/trainjob/npu/new.tmpl b/templates/repo/grampus/trainjob/npu/new.tmpl index 76bb572f0..6e11f3602 100755 --- a/templates/repo/grampus/trainjob/npu/new.tmpl +++ b/templates/repo/grampus/trainjob/npu/new.tmpl @@ -25,7 +25,9 @@ .width81{ width: 81% !important; } - +.width48 { + width: 48.5% !important; +} .add{font-size: 18px; padding: 0.5rem; border: 1px solid rgba(187, 187, 187, 100); @@ -99,9 +101,11 @@ Ascend NPU - {{template "custom/wait_count_train" Dict "ctx" $}} - +
+ + {{template "custom/task_wait_count" .}} +
@@ -187,7 +191,7 @@
-
+ +
+ +
@@ -238,6 +246,7 @@
{{template "base/footer" .}} + diff --git a/templates/repo/grampus/trainjob/show.tmpl b/templates/repo/grampus/trainjob/show.tmpl index 728b876b5..8960c13d4 100755 --- a/templates/repo/grampus/trainjob/show.tmpl +++ b/templates/repo/grampus/trainjob/show.tmpl @@ -357,7 +357,7 @@ {{$.i18n.Tr "repo.modelarts.train_job.standard"}} - +
{{.FlavorName}}
@@ -629,8 +629,20 @@ {{template "base/footer" .}} - +