From 9205593f6646b5eb81d85fd1d02fe5ac2a9205d6 Mon Sep 17 00:00:00 2001 From: zhoupzh Date: Mon, 15 Aug 2022 11:09:43 +0800 Subject: [PATCH 1/4] fix issue --- web_src/js/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/web_src/js/index.js b/web_src/js/index.js index b6872eaa7..6b0ce2ab7 100755 --- a/web_src/js/index.js +++ b/web_src/js/index.js @@ -5142,7 +5142,9 @@ function initChartsNpu() { }; return seriesOption; }); + let xAxisValue = res.interval === 1 ? "时间(min)" : "时间(hour)"; let xLength = res.MetricsInfo[0].value.length; + options.xAxis.name = xAxisValue; options.xAxis.data = Array.from( { length: xLength }, (_, index) => index From 1ad7bf901799b53dee6d65511187630b370cbf1e Mon Sep 17 00:00:00 2001 From: zhoupzh Date: Mon, 15 Aug 2022 11:25:31 +0800 Subject: [PATCH 2/4] fix issue --- web_src/js/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web_src/js/index.js b/web_src/js/index.js index 6b0ce2ab7..1ec155461 100755 --- a/web_src/js/index.js +++ b/web_src/js/index.js @@ -5086,7 +5086,7 @@ function initChartsNpu() { axisLabel: { interval: "auto", }, - name: "时间(min)", + name: "", }, yAxis: { show: true, @@ -5142,7 +5142,7 @@ function initChartsNpu() { }; return seriesOption; }); - let xAxisValue = res.interval === 1 ? "时间(min)" : "时间(hour)"; + let xAxisValue = res.Interval === 1 ? "时间(min)" : "时间(hour)"; let xLength = res.MetricsInfo[0].value.length; options.xAxis.name = xAxisValue; options.xAxis.data = Array.from( From ef1f5bc983ed107c1ebd952054f4d5bea83f9374 Mon Sep 17 00:00:00 2001 From: zhoupzh Date: Tue, 16 Aug 2022 10:13:49 +0800 Subject: [PATCH 3/4] fix issue --- options/locale/locale_en-US.ini | 3 ++- options/locale/locale_zh-CN.ini | 3 ++- templates/repo/cloudbrain/trainjob/new.tmpl | 7 ++++-- templates/repo/grampus/trainjob/gpu/new.tmpl | 6 ++++- templates/repo/grampus/trainjob/npu/new.tmpl | 6 ++++- .../repo/modelarts/inferencejob/new.tmpl | 6 ++++- templates/repo/modelarts/trainjob/new.tmpl | 7 ++++-- .../js/components/dataset/selectDataset.vue | 23 ++++++++++++++----- 8 files changed, 46 insertions(+), 15 deletions(-) diff --git a/options/locale/locale_en-US.ini b/options/locale/locale_en-US.ini index 0fecf7de2..974b03b66 100755 --- a/options/locale/locale_en-US.ini +++ b/options/locale/locale_en-US.ini @@ -3116,7 +3116,7 @@ wrong_specification=You cannot use this specification, please choose another ite job_name_rule = Please enter letters, numbers, _ and - up to 64 characters and cannot end with a dash (-). -dataset_path_rule = The dataset location is stored in the environment variable data_url, and the training output path is stored in the environment variable train_url. +dataset_path_rule = The dataset location is stored in the environment variable data_url, and the output path is stored in the environment variable train_url. view_sample = View sample inference_output_path_rule = The inference output path is stored in the environment variable result_url. model_file_path_rule=The model file location is stored in the environment variable ckpt_url @@ -3149,3 +3149,4 @@ Stopped_success_update_status_fail=Succeed in stopping th job, but failed to upd load_code_failed=Fail to load code, please check if the right branch is selected. error.dataset_select = dataset select error:the count exceed the limit or has same name +new_train_gpu_tooltips = The code is storaged in %s, the dataset is storaged in %s, and please put your model into %s then you can download it online diff --git a/options/locale/locale_zh-CN.ini b/options/locale/locale_zh-CN.ini index 2878627e2..39edb2da5 100755 --- a/options/locale/locale_zh-CN.ini +++ b/options/locale/locale_zh-CN.ini @@ -3131,7 +3131,7 @@ card_type = 卡类型 wrong_specification=您目前不能使用这个资源规格,请选择其他资源规格。 job_name_rule = 请输入字母、数字、_和-,最长64个字符,且不能以中划线(-)结尾。 -dataset_path_rule = 数据集位置存储在环境变量data_url中,训练输出路径存储在环境变量train_url中。 +dataset_path_rule = 数据集位置存储在环境变量data_url中,输出路径存储在环境变量train_url中。 view_sample = 查看样例 inference_output_path_rule = 推理输出路径存储在环境变量result_url中。 model_file_path_rule = 模型文件位置存储在环境变量ckpt_url中。 @@ -3165,3 +3165,4 @@ load_code_failed=代码加载失败,请确认选择了正确的分支。 error.dataset_select = 数据集选择错误:数量超过限制或者有同名数据集 +new_train_gpu_tooltips =训练脚本存储在%s中,数据集存储在%s中,训练输出请存储在%s中以供后续下载。 diff --git a/templates/repo/cloudbrain/trainjob/new.tmpl b/templates/repo/cloudbrain/trainjob/new.tmpl index 72e22f730..3f8253819 100755 --- a/templates/repo/cloudbrain/trainjob/new.tmpl +++ b/templates/repo/cloudbrain/trainjob/new.tmpl @@ -115,6 +115,10 @@ Ascend NPU {{template "custom/wait_count_train" Dict "ctx" $ "type" .train_gpu_types}} +
+ + {{.i18n.Tr "cloudbrain.new_train_gpu_tooltips" "/code" "/dataset" "/model" | Safe}} +
@@ -212,8 +216,7 @@
- 训练脚本存储在/code中,数据集存储在/dataset中,训练输出请存储在/model中以供后续下载。 +
{{template "custom/wait_count_train" Dict "ctx" $}} +
+ + {{.i18n.Tr "cloudbrain.new_train_gpu_tooltips" "/tmp/code" "/tmp/dataset" "/tmp/output" | Safe}} +
@@ -165,7 +169,7 @@ {{template "custom/select_dataset_train" .}} - {{.i18n.Tr "repo.grampus.gpu_dataset_path_rule"}} +
{{.i18n.Tr "repo.modelarts.train_job.add_run_parameter"}} diff --git a/templates/repo/grampus/trainjob/npu/new.tmpl b/templates/repo/grampus/trainjob/npu/new.tmpl index 76bb572f0..98bc19451 100755 --- a/templates/repo/grampus/trainjob/npu/new.tmpl +++ b/templates/repo/grampus/trainjob/npu/new.tmpl @@ -100,6 +100,10 @@ Ascend NPU
{{template "custom/wait_count_train" Dict "ctx" $}} +
+ + {{.i18n.Tr "cloudbrain.new_train_gpu_tooltips" "/cache/code" "/cache/dataset" "/cache/output" | Safe}} +
@@ -177,7 +181,7 @@
{{template "custom/select_dataset_train" .}} - {{.i18n.Tr "repo.grampus.dataset_path_rule"}} +
{{.i18n.Tr "repo.modelarts.train_job.add_run_parameter"}} diff --git a/templates/repo/modelarts/inferencejob/new.tmpl b/templates/repo/modelarts/inferencejob/new.tmpl index 3b2150e41..0e0c80a45 100644 --- a/templates/repo/modelarts/inferencejob/new.tmpl +++ b/templates/repo/modelarts/inferencejob/new.tmpl @@ -83,6 +83,10 @@ Ascend NPU
{{template "custom/wait_count_train" Dict "ctx" $}} +
+ + {{.i18n.Tr "cloudbrain.dataset_path_rule" | Safe}} +
@@ -193,7 +197,7 @@
{{template "custom/select_dataset_train" .}} - {{.i18n.Tr "cloudbrain.dataset_path_rule"}} +
{{if .bootFile}} diff --git a/templates/repo/modelarts/trainjob/new.tmpl b/templates/repo/modelarts/trainjob/new.tmpl index 51f447f46..cf3ea76c4 100755 --- a/templates/repo/modelarts/trainjob/new.tmpl +++ b/templates/repo/modelarts/trainjob/new.tmpl @@ -111,11 +111,14 @@ Ascend NPU
{{template "custom/wait_count_train" Dict "ctx" $}} +
+ + {{.i18n.Tr "cloudbrain.dataset_path_rule" | Safe}} +
- {{.i18n.Tr "repo.cloudbrain_jobname_err"}}
@@ -204,7 +207,7 @@
- {{.i18n.Tr "cloudbrain.dataset_path_rule"}} +
{{.i18n.Tr "repo.modelarts.train_job.add_run_parameter"}} diff --git a/web_src/js/components/dataset/selectDataset.vue b/web_src/js/components/dataset/selectDataset.vue index 43b3701f4..b36b90cab 100755 --- a/web_src/js/components/dataset/selectDataset.vue +++ b/web_src/js/components/dataset/selectDataset.vue @@ -75,7 +75,7 @@
@@ -727,7 +727,9 @@ export default { "currentTree", this.paramsCurrent.page ); - this.initCurrentTreeNode = this.currentDatasetList[0]?.id ? [this.currentDatasetList[0].id] : []; + this.initCurrentTreeNode = this.currentDatasetList[0]?.id + ? [this.currentDatasetList[0].id] + : []; this.totalNumCurrent = parseInt(res.data.count); let setCheckedKeysList = this.currentDatasetList.reduce( (pre, cur) => { @@ -763,7 +765,9 @@ export default { "myTree", this.paramsMy.page ); - this.initMyTreeNode = this.myDatasetList[0]?.id ? [this.myDatasetList[0].id] : []; + this.initMyTreeNode = this.myDatasetList[0]?.id + ? [this.myDatasetList[0].id] + : []; this.totalNumMy = parseInt(res.data.count); let setCheckedKeysList = this.myDatasetList.reduce((pre, cur) => { cur.Attachments.forEach((item) => { @@ -796,7 +800,9 @@ export default { "publicTree", this.paramsPublics.page ); - this.initPublicTreeNode = this.publicDatasetList[0]?.id ? [this.publicDatasetList[0].id] : []; + this.initPublicTreeNode = this.publicDatasetList[0]?.id + ? [this.publicDatasetList[0].id] + : []; this.totalNumPublic = parseInt(res.data.count); let setCheckedKeysList = this.publicDatasetList.reduce((pre, cur) => { cur.Attachments.forEach((item) => { @@ -830,7 +836,9 @@ export default { "favoriteTree", this.paramsFavorite.page ); - this.initFavoriteTreeNode = this.MyFavoriteDatasetList[0]?.id ? [this.MyFavoriteDatasetList[0].id] : []; + this.initFavoriteTreeNode = this.MyFavoriteDatasetList[0]?.id + ? [this.MyFavoriteDatasetList[0].id] + : []; this.totalNumFavorite = parseInt(res.data.count); let setCheckedKeysList = this.MyFavoriteDatasetList.reduce( (pre, cur) => { @@ -955,7 +963,10 @@ export default { ) { this.benchmarkNew = true; } - if (location.href.indexOf("modelarts/notebook/create") !== -1 || location.href.indexOf("/cloudbrain/create") !== -1) { + if ( + location.href.indexOf("modelarts/notebook/create") !== -1 || + location.href.indexOf("/cloudbrain/create") !== -1 + ) { this.required = false; } window.onresize = () => { From 5af395629dc7787895a3fd432294a93fa160121d Mon Sep 17 00:00:00 2001 From: zhoupzh Date: Tue, 16 Aug 2022 11:12:08 +0800 Subject: [PATCH 4/4] fix issue --- templates/repo/cloudbrain/benchmark/new.tmpl | 8 ++++++- templates/repo/cloudbrain/inference/new.tmpl | 8 ++++++- templates/repo/cloudbrain/new.tmpl | 6 ++++- templates/repo/cloudbrain/trainjob/new.tmpl | 8 ++++++- templates/repo/grampus/trainjob/gpu/new.tmpl | 10 ++++++--- templates/repo/grampus/trainjob/npu/new.tmpl | 9 ++++++-- .../repo/modelarts/inferencejob/new.tmpl | 8 ++++++- templates/repo/modelarts/notebook/new.tmpl | 8 +++---- templates/repo/modelarts/trainjob/new.tmpl | 22 ++++++------------- 9 files changed, 57 insertions(+), 30 deletions(-) diff --git a/templates/repo/cloudbrain/benchmark/new.tmpl b/templates/repo/cloudbrain/benchmark/new.tmpl index f8e83e1ae..a60f32853 100755 --- a/templates/repo/cloudbrain/benchmark/new.tmpl +++ b/templates/repo/cloudbrain/benchmark/new.tmpl @@ -40,7 +40,7 @@ {{if eq .benchmarkMode "model"}} -
+ {{.CsrfTokenHtml}}
@@ -251,6 +251,12 @@ {{template "base/footer" .}} \ No newline at end of file diff --git a/templates/repo/cloudbrain/trainjob/new.tmpl b/templates/repo/cloudbrain/trainjob/new.tmpl index 72e22f730..2cab32cba 100755 --- a/templates/repo/cloudbrain/trainjob/new.tmpl +++ b/templates/repo/cloudbrain/trainjob/new.tmpl @@ -75,7 +75,7 @@
- + {{.CsrfTokenHtml}} @@ -266,6 +266,12 @@ {{template "base/footer" .}}