From 468b812f24598f168dbba51b722cf1895a48aae0 Mon Sep 17 00:00:00 2001
From: chenzhihang <709011834@qq.com>
Date: Fri, 22 Nov 2024 11:22:53 +0800
Subject: [PATCH] =?UTF-8?q?=E8=87=AA=E5=8A=A8=E6=9C=BA=E5=99=A8=E5=AD=A6?=
=?UTF-8?q?=E4=B9=A0=E5=BC=80=E5=8F=91?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../src/main/java/com/ruoyi/platform/domain/AutoMl.java | 7 +++++--
.../mapper/managementPlatform/AutoMLDaoMapper.xml | 7 +++++--
2 files changed, 10 insertions(+), 4 deletions(-)
diff --git a/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/domain/AutoMl.java b/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/domain/AutoMl.java
index e1aa5506..ec9b5931 100644
--- a/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/domain/AutoMl.java
+++ b/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/domain/AutoMl.java
@@ -110,16 +110,19 @@ public class AutoMl {
private String excludeFeaturePreprocessor;
+ @ApiModelProperty(value = "训练集的比率,0到1之间")
+ private Float testSize;
+
@ApiModelProperty(value = "如何处理过拟合,如果使用基于“cv”的方法或Splitter对象,可能需要使用resampling_strategy_arguments。holdout或crossValid")
private String resamplingStrategy;
- @ApiModelProperty(value = "训练集的比率,0到1之间")
+ @ApiModelProperty(value = "重采样划分训练集和验证集,训练集的比率,0到1之间")
private Float trainSize;
@ApiModelProperty(value = "拆分数据前是否进行shuffle")
private Boolean shuffle;
- @ApiModelProperty(value = "当resamplingStrategy为crossValid时,此项必填。为整数")
+ @ApiModelProperty(value = "交叉验证的折数,当resamplingStrategy为crossValid时,此项必填,为整数")
private Integer folds;
@ApiModelProperty(value = "文件夹存放配置输出和日志文件,默认/tmp/automl")
diff --git a/ruoyi-modules/management-platform/src/main/resources/mapper/managementPlatform/AutoMLDaoMapper.xml b/ruoyi-modules/management-platform/src/main/resources/mapper/managementPlatform/AutoMLDaoMapper.xml
index 55f8e8f5..e5fecd5a 100644
--- a/ruoyi-modules/management-platform/src/main/resources/mapper/managementPlatform/AutoMLDaoMapper.xml
+++ b/ruoyi-modules/management-platform/src/main/resources/mapper/managementPlatform/AutoMLDaoMapper.xml
@@ -6,7 +6,7 @@
per_run_time_limit, ensemble_size, ensemble_class, ensemble_nbest, max_models_on_disc, seed,
memory_limit,
include_classifier, include_feature_preprocessor, include_regressor, exclude_classifier,
- exclude_regressor, exclude_feature_preprocessor, resampling_strategy, train_size,
+ exclude_regressor, exclude_feature_preprocessor, test_size, resampling_strategy, train_size,
shuffle, folds, data_csv, target_columns, metric_name, metrics,greater_is_better,scoring_functions,tmp_folder,
create_by,update_by)
values (#{autoMl.mlName}, #{autoMl.mlDescription}, #{autoMl.taskType}, #{autoMl.datasetName},
@@ -15,7 +15,7 @@
#{autoMl.maxModelsOnDisc}, #{autoMl.seed},
#{autoMl.memoryLimit}, #{autoMl.includeClassifier}, #{autoMl.includeFeaturePreprocessor},
#{autoMl.includeRegressor}, #{autoMl.excludeClassifier},
- #{autoMl.excludeRegressor}, #{autoMl.excludeFeaturePreprocessor}, #{autoMl.resamplingStrategy},
+ #{autoMl.excludeRegressor}, #{autoMl.excludeFeaturePreprocessor}, #{autoMl.testSize}, #{autoMl.resamplingStrategy},
#{autoMl.trainSize}, #{autoMl.shuffle},
#{autoMl.folds}, #{autoMl.dataCsv},
#{autoMl.targetColumns}, #{autoMl.metricName}, #{autoMl.metrics},#{autoMl.greaterIsBetter},#{autoMl.scoringFunctions},#{autoMl.tmpFolder},
@@ -85,6 +85,9 @@
exclude_feature_preprocessor = #{autoMl.excludeFeaturePreprocessor},
+
+ test_size = #{autoMl.testSize},
+
resampling_strategy = #{autoMl.resamplingStrategy},