|
@@ -37,9 +37,7 @@
|
|
<el-button type="primary" link icon="View" v-auth="['demo:DataAugmentation:query']" @click="openDialog(3, '任务查看', scope.row)">
|
|
<el-button type="primary" link icon="View" v-auth="['demo:DataAugmentation:query']" @click="openDialog(3, '任务查看', scope.row)">
|
|
查看
|
|
查看
|
|
</el-button>
|
|
</el-button>
|
|
- <!-- <el-button type="primary" link icon="EditPen" v-auth="['demo:DataAugmentation:edit']" @click="openDialog(2, '视频去抖动编辑', scope.row)">
|
|
|
|
- 编辑
|
|
|
|
- </el-button> -->
|
|
|
|
|
|
+ <el-button type="primary" link icon="View" v-auth="['demo:DataAugmentation:query']" @click="openLogDialog(scope.row.id)"> 日志 </el-button>
|
|
<el-button type="primary" link icon="Delete" v-auth="['demo:DataAugmentation:remove']" @click="deleteDataAugmentation(scope.row)">
|
|
<el-button type="primary" link icon="Delete" v-auth="['demo:DataAugmentation:remove']" @click="deleteDataAugmentation(scope.row)">
|
|
删除
|
|
删除
|
|
</el-button>
|
|
</el-button>
|
|
@@ -48,26 +46,23 @@
|
|
<FormDialog ref="formDialogRef" />
|
|
<FormDialog ref="formDialogRef" />
|
|
<ImportExcel ref="dialogRef" />
|
|
<ImportExcel ref="dialogRef" />
|
|
<el-dialog v-model="dialogVisible" :title="dialogTitle" width="80%">
|
|
<el-dialog v-model="dialogVisible" :title="dialogTitle" width="80%">
|
|
- <div class="image-dialog" v-if="imageIdx >= 0">
|
|
|
|
- <el-image
|
|
|
|
- v-for="(image, index) in cacheImages[imageIdx].origin"
|
|
|
|
- :key="index"
|
|
|
|
- :src="'data:image/png;base64,' + image"
|
|
|
|
- style="width: 45%"
|
|
|
|
- ></el-image>
|
|
|
|
- <el-tag>结果:</el-tag>
|
|
|
|
- <el-image
|
|
|
|
- v-for="(image, index) in cacheImages[imageIdx].stable"
|
|
|
|
- :key="index"
|
|
|
|
- :src="'data:image/png;base64,' + image"
|
|
|
|
- style="width: 45%"
|
|
|
|
- ></el-image>
|
|
|
|
|
|
+ <div class="image-dialog" v-if="imageIdx >= 0 && cacheImages[imageIdx]">
|
|
|
|
+ <div style="width: 50%">
|
|
|
|
+ <el-image v-for="(image, index) in cacheImages[imageIdx].origin" :key="index" :src="'data:image/png;base64,' + image"></el-image>
|
|
|
|
+ <!-- <el-tag>结果:</el-tag> -->
|
|
|
|
+ </div>
|
|
|
|
+ <div style="width: 50%">
|
|
|
|
+ <el-image v-for="(image, index) in cacheImages[imageIdx].stable" :key="index" :src="'data:image/png;base64,' + image"></el-image>
|
|
|
|
+ </div>
|
|
</div>
|
|
</div>
|
|
<div class="image-dialog-btn" v-if="imageFps == 0">
|
|
<div class="image-dialog-btn" v-if="imageFps == 0">
|
|
<el-button type="primary" @click="pre_picture" :disabled="imageIdx <= 0">上一个</el-button>
|
|
<el-button type="primary" @click="pre_picture" :disabled="imageIdx <= 0">上一个</el-button>
|
|
<el-button type="primary" @click="next_picture" :disabled="imageIdx >= fileCount - 1">下一个</el-button>
|
|
<el-button type="primary" @click="next_picture" :disabled="imageIdx >= fileCount - 1">下一个</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
+ <el-dialog v-model="logDialogVisible" title="日志" width="80%">
|
|
|
|
+ <el-text class="mx-1">{{ logDialog }}</el-text>
|
|
|
|
+ </el-dialog>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
@@ -92,9 +87,11 @@ import {
|
|
startDataAugmentationApi,
|
|
startDataAugmentationApi,
|
|
stopDataAugmentationApi,
|
|
stopDataAugmentationApi,
|
|
getCompareImageApi,
|
|
getCompareImageApi,
|
|
- getCompareImageCountApi
|
|
|
|
|
|
+ getCompareImageCountApi,
|
|
|
|
+ getDialogApi
|
|
} from '@/api/modules/demo/dataAugmentation'
|
|
} from '@/api/modules/demo/dataAugmentation'
|
|
import { listDataApi } from '@/api/modules/system/dictData'
|
|
import { listDataApi } from '@/api/modules/system/dictData'
|
|
|
|
+import { S } from 'vite/dist/node/types.d-aGj9QkWt'
|
|
const dialogVisible = ref(false)
|
|
const dialogVisible = ref(false)
|
|
const taskId = ref('')
|
|
const taskId = ref('')
|
|
const imageIdx = ref(0)
|
|
const imageIdx = ref(0)
|
|
@@ -115,6 +112,13 @@ const taskTypeEnums: EnumProps[] = []
|
|
|
|
|
|
const hyperparameterConfiguration = []
|
|
const hyperparameterConfiguration = []
|
|
const hyperparameter = ref('')
|
|
const hyperparameter = ref('')
|
|
|
|
+const logDialogVisible = ref(false)
|
|
|
|
+const logDialog = ref('')
|
|
|
|
+const openLogDialog = async (id: string | number) => {
|
|
|
|
+ const res: any = await getDialogApi(id)
|
|
|
|
+ logDialog.value = res.data
|
|
|
|
+ logDialogVisible.value = true
|
|
|
|
+}
|
|
const getTaskType = async () => {
|
|
const getTaskType = async () => {
|
|
const res: any = await listDataApi({
|
|
const res: any = await listDataApi({
|
|
dictName: '',
|
|
dictName: '',
|
|
@@ -214,6 +218,8 @@ const compareDataAugmentation = async (params: any) => {
|
|
continue
|
|
continue
|
|
}
|
|
}
|
|
const res: any = await getCompareImageApi(taskId.value, idx - 1)
|
|
const res: any = await getCompareImageApi(taskId.value, idx - 1)
|
|
|
|
+ // console.log(res)
|
|
|
|
+
|
|
cacheImages.value[idx - 1] = {
|
|
cacheImages.value[idx - 1] = {
|
|
origin: res.origin,
|
|
origin: res.origin,
|
|
stable: res.stable
|
|
stable: res.stable
|
|
@@ -284,7 +290,9 @@ const openDialog = async (type: number, title: string, row?: any) => {
|
|
let res = { data: {} }
|
|
let res = { data: {} }
|
|
if (row?.id) {
|
|
if (row?.id) {
|
|
res = await getDataAugmentationApi(row?.id || null)
|
|
res = await getDataAugmentationApi(row?.id || null)
|
|
|
|
+ hyperparameter.value = res.data?.hyperparameterConfiguration
|
|
}
|
|
}
|
|
|
|
+
|
|
// 重置表单
|
|
// 重置表单
|
|
setItemsOptions()
|
|
setItemsOptions()
|
|
const params = {
|
|
const params = {
|
|
@@ -508,6 +516,7 @@ const setItemsOptions = () => {
|
|
<style lang="scss" scoped>
|
|
<style lang="scss" scoped>
|
|
.image-dialog {
|
|
.image-dialog {
|
|
display: flex;
|
|
display: flex;
|
|
|
|
+ align-items: center;
|
|
justify-content: center;
|
|
justify-content: center;
|
|
.el-image {
|
|
.el-image {
|
|
margin-right: 20px;
|
|
margin-right: 20px;
|