|
|
|
@@ -1,5 +1,4 @@ |
|
|
|
import InfoGroup from '@/components/InfoGroup'; |
|
|
|
import KFIcon from '@/components/KFIcon'; |
|
|
|
import { getFileReq } from '@/services/file'; |
|
|
|
import { to } from '@/utils/promise'; |
|
|
|
import { Button, Image } from 'antd'; |
|
|
|
@@ -38,28 +37,10 @@ function ExperimentResult({ fileUrl, imageUrl, modelPath }: ExperimentResultProp |
|
|
|
|
|
|
|
return ( |
|
|
|
<div className={styles['experiment-result']}> |
|
|
|
{modelPath && ( |
|
|
|
<div className={styles['experiment-result__download']}> |
|
|
|
<span style={{ marginRight: '12px', color: '#606b7a' }}>文件名</span> |
|
|
|
<span>save_model.joblib</span> |
|
|
|
<Button |
|
|
|
type="link" |
|
|
|
className={styles['experiment-result__download__btn']} |
|
|
|
icon={<KFIcon type="icon-a-xiazai1" />} |
|
|
|
size="small" |
|
|
|
iconPosition="end" |
|
|
|
onClick={() => { |
|
|
|
window.location.href = modelPath; |
|
|
|
}} |
|
|
|
> |
|
|
|
模型下载 |
|
|
|
</Button> |
|
|
|
</div> |
|
|
|
)} |
|
|
|
<InfoGroup title="实验结果" contentScroll> |
|
|
|
<div className={styles['experiment-result__text']}>{result}</div> |
|
|
|
</InfoGroup> |
|
|
|
<InfoGroup title="可视化结果" style={{ marginTop: '16px' }}> |
|
|
|
<InfoGroup title="可视化结果" style={{ margin: '16px 0' }}> |
|
|
|
<div className={styles['experiment-result__images']}> |
|
|
|
<Image.PreviewGroup |
|
|
|
preview={{ |
|
|
|
@@ -80,6 +61,21 @@ function ExperimentResult({ fileUrl, imageUrl, modelPath }: ExperimentResultProp |
|
|
|
</Image.PreviewGroup> |
|
|
|
</div> |
|
|
|
</InfoGroup> |
|
|
|
{modelPath && ( |
|
|
|
<div className={styles['experiment-result__download']}> |
|
|
|
<span style={{ marginRight: '12px', color: '#606b7a' }}>文件名</span> |
|
|
|
<span>save_model.joblib</span> |
|
|
|
<Button |
|
|
|
type="primary" |
|
|
|
className={styles['experiment-result__download__btn']} |
|
|
|
onClick={() => { |
|
|
|
window.location.href = modelPath; |
|
|
|
}} |
|
|
|
> |
|
|
|
模型下载 |
|
|
|
</Button> |
|
|
|
</div> |
|
|
|
)} |
|
|
|
</div> |
|
|
|
); |
|
|
|
} |
|
|
|
|