feat: 添加小模型训练菜单

This commit is contained in:
赵伟 2026-02-05 15:31:36 +08:00
parent 969d9b70a3
commit e6d97a14f6
5 changed files with 237 additions and 229 deletions

View File

@ -102,34 +102,34 @@ export default [
}, },
], ],
}, },
{
name: '开发环境',
path: 'developmentEnvironment',
routes: [
{
name: '开发环境',
path: '',
component: './DevelopmentEnvironment/List',
},
{
name: '创建开发环境',
path: 'create',
component: './DevelopmentEnvironment/Create',
},
{
name: '开发环境详情',
path: 'editor',
component: './DevelopmentEnvironment/Editor',
},
],
},
{ {
name: '流水线', name: '流水线',
path: '/pipeline', path: '/pipeline',
routes: [ routes: [
{ {
path: '', path: '',
redirect: 'developmentEnvironment', redirect: 'template',
},
{
name: '开发环境',
path: 'developmentEnvironment',
routes: [
{
name: '开发环境',
path: '',
component: './DevelopmentEnvironment/List',
},
{
name: '创建开发环境',
path: 'create',
component: './DevelopmentEnvironment/Create',
},
{
name: '开发环境详情',
path: 'editor',
component: './DevelopmentEnvironment/Editor',
},
],
}, },
{ {
name: '流水线模板', name: '流水线模板',
@ -825,205 +825,205 @@ export default [
// microApp: 'flint-service', // microApp: 'flint-service',
// layout: true, // layout: true,
// }, // },
// { {
// path: '/training', path: '/training',
// name: '模型训练', name: '模型训练',
// routes: [ routes: [
// { {
// name: '小模型训练', name: '小模型训练',
// path: 'pipeline', path: 'pipeline',
// routes: [ routes: [
// { {
// path: '', path: '',
// redirect: 'template', redirect: 'template',
// }, },
// { {
// name: '流水线模板', name: '流水线模板',
// path: 'template', path: 'template',
// routes: [ routes: [
// { {
// name: '流水线模板', name: '流水线模板',
// path: '', path: '',
// component: './Pipeline/index', component: './Pipeline/index',
// }, },
// { {
// name: '流水线详情', name: '流水线详情',
// path: 'info/:id', path: 'info/:id',
// component: './Pipeline/Info/index', component: './Pipeline/Info/index',
// }, },
// ], ],
// }, },
// { {
// name: '实验', name: '实验',
// path: 'experiment', path: 'experiment',
// routes: [ routes: [
// { {
// name: '实验', name: '实验',
// path: '', path: '',
// component: './Experiment/index', component: './Experiment/index',
// }, },
// { {
// name: '实验实例', name: '实验实例',
// path: 'instance/:workflowId/:id', path: 'instance/:workflowId/:id',
// component: './Experiment/Info/index', component: './Experiment/Info/index',
// }, },
// { {
// name: '实验对比', name: '实验对比',
// path: 'compare', path: 'compare',
// routes: [ routes: [
// { {
// name: '实验对比', name: '实验对比',
// path: '', path: '',
// component: './Experiment/Comparison/index', component: './Experiment/Comparison/index',
// }, },
// { {
// name: '可视化对比', name: '可视化对比',
// path: 'compare-visual', path: 'compare-visual',
// component: './Experiment/Aim/index', component: './Experiment/Aim/index',
// }, },
// ], ],
// }, },
// { {
// name: '可视化', name: '可视化',
// path: 'visual', path: 'visual',
// component: './Experiment/Tensorboard/index', component: './Experiment/Tensorboard/index',
// }, },
// ], ],
// }, },
// { {
// name: '自动机器学习', name: '自动机器学习',
// path: 'automl', path: 'automl',
// routes: [ routes: [
// { {
// name: '自动机器学习', name: '自动机器学习',
// path: '', path: '',
// component: './AutoML/List/index', component: './AutoML/List/index',
// }, },
// { {
// name: '实验详情', name: '实验详情',
// path: 'info/:id', path: 'info/:id',
// component: './AutoML/Info/index', component: './AutoML/Info/index',
// }, },
// { {
// name: '创建实验', name: '创建实验',
// path: 'create', path: 'create',
// component: './AutoML/Create/index', component: './AutoML/Create/index',
// }, },
// { {
// name: '编辑实验', name: '编辑实验',
// path: 'edit/:id', path: 'edit/:id',
// component: './AutoML/Create/index', component: './AutoML/Create/index',
// }, },
// { {
// name: '复制实验', name: '复制实验',
// path: 'copy/:id', path: 'copy/:id',
// component: './AutoML/Create/index', component: './AutoML/Create/index',
// }, },
// { {
// name: '实验实例详情', name: '实验实例详情',
// path: 'instance/:experimentId/:id', path: 'instance/:experimentId/:id',
// component: './AutoML/Instance/index', component: './AutoML/Instance/index',
// }, },
// ], ],
// }, },
// { {
// name: '超参数自动寻优', name: '超参数自动寻优',
// path: 'hyperparameter', path: 'hyperparameter',
// routes: [ routes: [
// { {
// name: '超参数寻优', name: '超参数寻优',
// path: '', path: '',
// component: './HyperParameter/List/index', component: './HyperParameter/List/index',
// }, },
// { {
// name: '实验详情', name: '实验详情',
// path: 'info/:id', path: 'info/:id',
// component: './HyperParameter/Info/index', component: './HyperParameter/Info/index',
// }, },
// { {
// name: '创建实验', name: '创建实验',
// path: 'create', path: 'create',
// component: './HyperParameter/Create/index', component: './HyperParameter/Create/index',
// }, },
// { {
// name: '编辑实验', name: '编辑实验',
// path: 'edit/:id', path: 'edit/:id',
// component: './HyperParameter/Create/index', component: './HyperParameter/Create/index',
// }, },
// { {
// name: '复制实验', name: '复制实验',
// path: 'copy/:id', path: 'copy/:id',
// component: './HyperParameter/Create/index', component: './HyperParameter/Create/index',
// }, },
// { {
// name: '实验实例详情', name: '实验实例详情',
// path: 'instance/:experimentId/:id', path: 'instance/:experimentId/:id',
// routes: [ routes: [
// { {
// name: '实验实例详情', name: '实验实例详情',
// path: '', path: '',
// component: './HyperParameter/Instance/index', component: './HyperParameter/Instance/index',
// }, },
// { {
// name: '可视化对比', name: '可视化对比',
// path: 'compare-visual', path: 'compare-visual',
// component: './Experiment/Aim/index', component: './Experiment/Aim/index',
// }, },
// ], ],
// }, },
// ], ],
// }, },
// { {
// name: '主动学习', name: '主动学习',
// path: 'active-learn', path: 'active-learn',
// routes: [ routes: [
// { {
// name: '主动学习', name: '主动学习',
// path: '', path: '',
// component: './ActiveLearn/List/index', component: './ActiveLearn/List/index',
// }, },
// { {
// name: '实验详情', name: '实验详情',
// path: 'info/:id', path: 'info/:id',
// component: './ActiveLearn/Info/index', component: './ActiveLearn/Info/index',
// }, },
// { {
// name: '创建实验', name: '创建实验',
// path: 'create', path: 'create',
// component: './ActiveLearn/Create/index', component: './ActiveLearn/Create/index',
// }, },
// { {
// name: '编辑实验', name: '编辑实验',
// path: 'edit/:id', path: 'edit/:id',
// component: './ActiveLearn/Create/index', component: './ActiveLearn/Create/index',
// }, },
// { {
// name: '复制实验', name: '复制实验',
// path: 'copy/:id', path: 'copy/:id',
// component: './ActiveLearn/Create/index', component: './ActiveLearn/Create/index',
// }, },
// { {
// name: '实验实例详情', name: '实验实例详情',
// path: 'instance/:experimentId/:id', path: 'instance/:experimentId/:id',
// routes: [ routes: [
// { {
// name: '实验实例详情', name: '实验实例详情',
// path: '', path: '',
// component: './ActiveLearn/Instance/index', component: './ActiveLearn/Instance/index',
// }, },
// { {
// name: '数据标注', name: '数据标注',
// path: 'label', path: 'label',
// component: './ActiveLearn/Label/index', component: './ActiveLearn/Label/index',
// }, },
// ], ],
// }, },
// ], ],
// }, },
// ], ],
// }, },
// ], ],
// }, },
] ]
: []), : []),
{ {

View File

@ -43,7 +43,7 @@
margin: 0; margin: 0;
padding: 0; padding: 0;
color: rgba(0, 0, 0, 0.65); color: rgba(0, 0, 0, 0.65);
color: #1890ff; color: #514cf9;
font-size: 14px; font-size: 14px;
font-variant: tabular-nums; font-variant: tabular-nums;
line-height: 1.5; line-height: 1.5;
@ -80,7 +80,7 @@
display: block; display: block;
width: 9px; width: 9px;
height: 9px; height: 9px;
background-color: #1890ff; background-color: #514cf9;
border-radius: 100%; border-radius: 100%;
-webkit-transform: scale(0.75); -webkit-transform: scale(0.75);
-ms-transform: scale(0.75); -ms-transform: scale(0.75);

View File

@ -3,7 +3,7 @@
display: flex; display: flex;
flex-direction: column; flex-direction: column;
height: 100%; height: 100%;
padding: @page-padding-top 0 @page-padding-bottom; padding: @page-padding-bottom 0 @page-padding-bottom;
&__header { &__header {
flex: none; flex: none;
@ -33,9 +33,11 @@
font-size: 15px; font-size: 15px;
border-radius: 17px; border-radius: 17px;
cursor: pointer; cursor: pointer;
&:hover { &:hover {
color: @text-color; color: @text-color;
} }
&:active, &:active,
&--selected { &--selected {
color: white !important; color: white !important;
@ -54,9 +56,11 @@
border: 1px solid rgba(65, 84, 241, 0.06); border: 1px solid rgba(65, 84, 241, 0.06);
border-radius: 16px; border-radius: 16px;
cursor: pointer; cursor: pointer;
&:hover { &:hover {
color: @primary-color; color: @primary-color;
} }
&:active, &:active,
&--selected { &--selected {
color: @primary-color; color: @primary-color;

View File

@ -2,7 +2,7 @@
display: flex; display: flex;
flex-direction: column; flex-direction: column;
height: 100%; height: 100%;
padding: @page-padding-top @content-padding @page-padding-bottom; padding: @page-padding-bottom @content-padding @page-padding-bottom;
.backgroundPageImage(url(@/assets/img/app/app-bg-2.png)); .backgroundPageImage(url(@/assets/img/app/app-bg-2.png));
:global { :global {

View File

@ -5,6 +5,7 @@
*/ */
import KFSpin from '@/components/KFSpin'; import KFSpin from '@/components/KFSpin';
import themes from '@/styles/theme.less';
import { ConfigProvider, SpinProps } from 'antd'; import { ConfigProvider, SpinProps } from 'antd';
import { globalConfig } from 'antd/es/config-provider'; import { globalConfig } from 'antd/es/config-provider';
import zhCN from 'antd/locale/zh_CN'; import zhCN from 'antd/locale/zh_CN';
@ -40,13 +41,16 @@ export class Loading {
renderTimeoutId = setTimeout(() => { renderTimeoutId = setTimeout(() => {
const rootPrefixCls = global.getPrefixCls(); const rootPrefixCls = global.getPrefixCls();
const iconPrefixCls = global.getIconPrefixCls(); const iconPrefixCls = global.getIconPrefixCls();
const theme = global.getTheme();
const dom = <KFSpin {...spinProps} />; const dom = <KFSpin {...spinProps} />;
root.render( root.render(
<ConfigProvider <ConfigProvider
prefixCls={rootPrefixCls} prefixCls={rootPrefixCls}
iconPrefixCls={iconPrefixCls} iconPrefixCls={iconPrefixCls}
theme={theme} theme={{
token: {
colorPrimary: themes['primaryColor'],
},
}}
locale={zhCN} locale={zhCN}
> >
{global.holderRender ? global.holderRender(dom) : dom} {global.holderRender ? global.holderRender(dom) : dom}