| @@ -286,6 +286,11 @@ public class RayInsServiceImpl implements RayInsService { | |||||
| Path experimentState = Paths.get(collect.get(0).get("name").toString()); | Path experimentState = Paths.get(collect.get(0).get("name").toString()); | ||||
| String content = minioUtil.readObjectAsString(bucketName, prefix + "/" + experimentState); | String content = minioUtil.readObjectAsString(bucketName, prefix + "/" + experimentState); | ||||
| String resultTxt = minioUtil.readObjectAsString(bucketName, prefix + "result.txt"); | |||||
| String bestMetrics = getStringBetween(resultTxt, "Best metrics:", "Best result_df"); | |||||
| Map<String, Object> bestMetricsMap = JsonUtils.jsonToMap(bestMetrics); | |||||
| String bestTrialId = (String)bestMetricsMap.get("trial_id"); | |||||
| Map<String, Object> result = JsonUtils.jsonToMap(content); | Map<String, Object> result = JsonUtils.jsonToMap(content); | ||||
| ArrayList<ArrayList> trial_data_list = (ArrayList<ArrayList>) result.get("trial_data"); | ArrayList<ArrayList> trial_data_list = (ArrayList<ArrayList>) result.get("trial_data"); | ||||
| ArrayList<Map<String, Object>> trialList = new ArrayList<>(); | ArrayList<Map<String, Object>> trialList = new ArrayList<>(); | ||||
| @@ -318,8 +323,6 @@ public class RayInsServiceImpl implements RayInsService { | |||||
| } | } | ||||
| try { | try { | ||||
| String resultTxt = minioUtil.readObjectAsString(bucketName, prefix + "result.txt"); | |||||
| String bestTrialId = getStringBetween(resultTxt, "'trial_id': '", "'"); | |||||
| if (bestTrialId.equals(trialId)) { | if (bestTrialId.equals(trialId)) { | ||||
| trial.put("is_best", true); | trial.put("is_best", true); | ||||
| } | } | ||||