Commit c847d403 authored by linpeiqin's avatar linpeiqin

增加模型评估的参数

parent dc26bbfc
...@@ -50,17 +50,16 @@ public class ModelEstimateController { ...@@ -50,17 +50,16 @@ public class ModelEstimateController {
* 新增模型评估数据,及其关联的从表数据。 * 新增模型评估数据,及其关联的从表数据。
* *
* @param modelEstimateDto 新增主表对象。 * @param modelEstimateDto 新增主表对象。
* @param modelTaskDto 一对一模型任务从表Dto。
* @return 应答结果对象,包含新增对象主键Id。 * @return 应答结果对象,包含新增对象主键Id。
*/ */
@ApiOperationSupport(ignoreParameters = {"modelEstimateDto.taskId", "modelEstimateDto.searchString"}) @ApiOperationSupport(ignoreParameters = {"modelEstimateDto.taskId", "modelEstimateDto.searchString"})
@OperationLog(type = SysOperationLogType.ADD) @OperationLog(type = SysOperationLogType.ADD)
@PostMapping("/add") @PostMapping("/add")
public ResponseResult<Long> add( public ResponseResult<Long> add(
@MyRequestBody ModelEstimateDto modelEstimateDto, @MyRequestBody ModelEstimateDto modelEstimateDto) {
@MyRequestBody ModelTaskDto modelTaskDto) {
Long modelVersionId = modelEstimateDto.getModelVersionId(); Long modelVersionId = modelEstimateDto.getModelVersionId();
ModelVersion modelVersion = this.modelVersionService.getById(modelVersionId); ModelVersion modelVersion = this.modelVersionService.getById(modelVersionId);
ModelTaskDto modelTaskDto = new ModelTaskDto();
modelTaskDto.setVersionId(modelVersion.getVersionId()); modelTaskDto.setVersionId(modelVersion.getVersionId());
modelTaskDto.setTaskType(1); modelTaskDto.setTaskType(1);
modelTaskDto.setModelId(modelVersion.getModelId()); modelTaskDto.setModelId(modelVersion.getModelId());
......
...@@ -12,6 +12,7 @@ ...@@ -12,6 +12,7 @@
<result column="model_version_id" jdbcType="BIGINT" property="modelVersionId"/> <result column="model_version_id" jdbcType="BIGINT" property="modelVersionId"/>
<result column="dataset_version_id" jdbcType="BIGINT" property="datasetVersionId"/> <result column="dataset_version_id" jdbcType="BIGINT" property="datasetVersionId"/>
<result column="scoring_mode" jdbcType="TINYINT" property="scoringMode"/> <result column="scoring_mode" jdbcType="TINYINT" property="scoringMode"/>
<result column="configuration" jdbcType="LONGVARCHAR" property="configuration"/>
</resultMap> </resultMap>
<insert id="insertList"> <insert id="insertList">
...@@ -25,7 +26,8 @@ ...@@ -25,7 +26,8 @@
task_describe, task_describe,
model_version_id, model_version_id,
dataset_version_id, dataset_version_id,
scoring_mode) scoring_mode,
configuration)
VALUES VALUES
<foreach collection="list" index="index" item="item" separator=","> <foreach collection="list" index="index" item="item" separator=",">
(#{item.taskId}, (#{item.taskId},
...@@ -37,7 +39,8 @@ ...@@ -37,7 +39,8 @@
#{item.taskDescribe}, #{item.taskDescribe},
#{item.modelVersionId}, #{item.modelVersionId},
#{item.datasetVersionId}, #{item.datasetVersionId},
#{item.scoringMode}) #{item.scoringMode},
#{item.configuration})
</foreach> </foreach>
</insert> </insert>
......
...@@ -54,6 +54,12 @@ public class ModelEstimateDto { ...@@ -54,6 +54,12 @@ public class ModelEstimateDto {
@ApiModelProperty(value = "打分模式") @ApiModelProperty(value = "打分模式")
private Integer scoringMode; private Integer scoringMode;
/**
* 参数配置。
*/
@ApiModelProperty(value = "参数配置")
private String configuration;
/** /**
* task_name LIKE搜索字符串。 * task_name LIKE搜索字符串。
*/ */
......
...@@ -55,6 +55,10 @@ public class ModelEstimate extends BaseModel { ...@@ -55,6 +55,10 @@ public class ModelEstimate extends BaseModel {
* 打分模式。 * 打分模式。
*/ */
private Integer scoringMode; private Integer scoringMode;
/**
* 参数配置。
*/
private String configuration;
/** /**
* task_name LIKE搜索字符串。 * task_name LIKE搜索字符串。
......
...@@ -54,6 +54,12 @@ public class ModelEstimateVo extends BaseVo { ...@@ -54,6 +54,12 @@ public class ModelEstimateVo extends BaseVo {
@ApiModelProperty(value = "打分模式") @ApiModelProperty(value = "打分模式")
private Integer scoringMode; private Integer scoringMode;
/**
* 参数配置。
*/
@ApiModelProperty(value = "参数配置")
private String configuration;
/** /**
* taskId 的一对一关联数据对象,数据对应类型为ModelTaskVo。 * taskId 的一对一关联数据对象,数据对应类型为ModelTaskVo。
*/ */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment