|
@@ -113,6 +113,8 @@ const intervalChangeFps: any = ref()
|
|
|
const taskType = ref([])
|
|
|
const taskTypeEnums: EnumProps[] = []
|
|
|
|
|
|
+const hyperparameterConfiguration = []
|
|
|
+const hyperparameter = ref('')
|
|
|
const getTaskType = async () => {
|
|
|
const res: any = await listDataApi({
|
|
|
dictName: '',
|
|
@@ -134,6 +136,24 @@ const getTaskType = async () => {
|
|
|
tagType: 'default'
|
|
|
})
|
|
|
})
|
|
|
+ for (let i = 0; i < taskType.value.length; i++) {
|
|
|
+ let dictValue = taskType.value[i].value
|
|
|
+ const res: any = await listDataApi({
|
|
|
+ dictName: '',
|
|
|
+ dictType: 'biz_data_augmentation',
|
|
|
+ dictLabel: dictValue + '超参配置',
|
|
|
+ pageNum: 0,
|
|
|
+ pageSize: 1000
|
|
|
+ })
|
|
|
+ if (res.data.list.length != 0) {
|
|
|
+ //console.log(res.data.list[0].dictValue)
|
|
|
+ let obj = {}
|
|
|
+ obj[dictValue] = res.data.list[0].dictValue
|
|
|
+ hyperparameterConfiguration.push(obj)
|
|
|
+ } else {
|
|
|
+ ElMessage.error('${dictValue}未在数据字典中设置超参!')
|
|
|
+ }
|
|
|
+ }
|
|
|
} else {
|
|
|
ElMessage.error('task_type为空,请在数据字典中设置具体的任务类型!')
|
|
|
}
|
|
@@ -434,7 +454,14 @@ const setItemsOptions = () => {
|
|
|
compOptions: {
|
|
|
elTagName: 'select', // 指定使用 el-select 组件
|
|
|
placeholder: '请选择任务类型',
|
|
|
- enum: taskType
|
|
|
+ enum: taskType,
|
|
|
+ onChange: (value: string) => {
|
|
|
+ hyperparameterConfiguration.forEach(obj => {
|
|
|
+ if (value in obj) {
|
|
|
+ hyperparameter.value = obj[value]
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
}
|
|
|
},
|
|
|
{
|
|
@@ -465,7 +492,9 @@ const setItemsOptions = () => {
|
|
|
compOptions: {
|
|
|
type: 'input',
|
|
|
clearable: true,
|
|
|
- placeholder: ''
|
|
|
+ // placeholder: hyperparameter,
|
|
|
+ value: hyperparameter
|
|
|
+ //value: hyperparameterConfiguration[itemsOptions.taskType]
|
|
|
}
|
|
|
},
|
|
|
{
|