BongGyun Shin commited on
Commit
71282fe
Β·
2 Parent(s): 3597ca0 e34354f

Merge pull request #1 from singbong/bong/modeling

Browse files
This view is limited to 50 files because it contains too many changes. Β  See raw diff
Files changed (50) hide show
  1. Analysis_code/4.oversampling_data_test/analysis_for_oversampling_data.ipynb +0 -0
  2. Analysis_code/{4.sampling_data_test β†’ 4.oversampling_data_test}/lgb_sampled_test.ipynb +0 -0
  3. Analysis_code/{4.sampling_data_test β†’ 4.oversampling_data_test}/xgb_sampled_test.ipynb +0 -0
  4. Analysis_code/4.sampling_data_test/analysis.ipynb +0 -244
  5. Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_daegu.py +97 -0
  6. Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_daejeon.py +97 -0
  7. Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_gwangju.py +97 -0
  8. Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_incheon.py +97 -0
  9. Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_seoul.py +97 -0
  10. Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_daegu.py +96 -0
  11. Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_daejeon.py +96 -0
  12. Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_gwangju.py +96 -0
  13. Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_incheon.py +96 -0
  14. Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_seoul.py +96 -0
  15. Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_busan.py +1 -0
  16. Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_daegu.py +317 -0
  17. Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_daejeon.py +317 -0
  18. Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_gwangju.py +317 -0
  19. Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_incheon.py +317 -0
  20. Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_seoul.py +317 -0
  21. Analysis_code/5.optima/lgb_pure/LGB_pure_daegu.py +1 -0
  22. Analysis_code/5.optima/lgb_pure/LGB_pure_daejeon.py +1 -0
  23. Analysis_code/5.optima/lgb_pure/LGB_pure_gwangju.py +1 -0
  24. Analysis_code/5.optima/lgb_pure/LGB_pure_incheon.py +1 -0
  25. Analysis_code/5.optima/lgb_pure/LGB_pure_seoul.py +1 -0
  26. Analysis_code/5.optima/lgb_smote/LGB_smote_busan.py +26 -0
  27. Analysis_code/5.optima/lgb_smote/LGB_smote_daegu.py +26 -0
  28. Analysis_code/5.optima/lgb_smote/LGB_smote_daejeon.py +26 -0
  29. Analysis_code/5.optima/lgb_smote/LGB_smote_gwangju.py +26 -0
  30. Analysis_code/5.optima/lgb_smote/LGB_smote_incheon.py +26 -0
  31. Analysis_code/5.optima/lgb_smote/LGB_smote_seoul.py +26 -0
  32. Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_busan.py +25 -0
  33. Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_daegu.py +25 -0
  34. Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_daejeon.py +25 -0
  35. Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_gwangju.py +25 -0
  36. Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_incheon.py +25 -0
  37. Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_seoul.py +25 -0
  38. Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_daegu.py +97 -0
  39. Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_daejeon.py +97 -0
  40. Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_gwangju.py +97 -0
  41. Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_incheon.py +97 -0
  42. Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_seoul.py +97 -0
  43. Analysis_code/5.optima/run_bash/deepgbm/deepgbm_ctgan10000.log +0 -0
  44. Analysis_code/5.optima/run_bash/deepgbm/deepgbm_smotenc_ctgan20000.log +0 -0
  45. Analysis_code/5.optima/run_bash/deepgbm/run_deepgbm_ctgan10000.sh +80 -0
  46. Analysis_code/5.optima/run_bash/ft_transformer/ft_transformer_ctgan10000.log +0 -0
  47. Analysis_code/5.optima/run_bash/ft_transformer/ft_transformer_smote.log +0 -0
  48. Analysis_code/5.optima/run_bash/ft_transformer/ft_transformer_smotenc_ctgan20000.log +0 -0
  49. Analysis_code/5.optima/run_bash/ft_transformer/run_ft_transformer_ctgan10000.sh +80 -0
  50. Analysis_code/5.optima/run_bash/lgb/lgb_ctgan10000.log +219 -0
Analysis_code/4.oversampling_data_test/analysis_for_oversampling_data.ipynb ADDED
The diff for this file is too large to render. See raw diff
 
Analysis_code/{4.sampling_data_test β†’ 4.oversampling_data_test}/lgb_sampled_test.ipynb RENAMED
File without changes
Analysis_code/{4.sampling_data_test β†’ 4.oversampling_data_test}/xgb_sampled_test.ipynb RENAMED
File without changes
Analysis_code/4.sampling_data_test/analysis.ipynb DELETED
@@ -1,244 +0,0 @@
1
- {
2
- "cells": [
3
- {
4
- "cell_type": "code",
5
- "execution_count": 1,
6
- "id": "70effd7a",
7
- "metadata": {},
8
- "outputs": [],
9
- "source": [
10
- "import pandas as pd\n",
11
- "import numpy as np"
12
- ]
13
- },
14
- {
15
- "cell_type": "code",
16
- "execution_count": 3,
17
- "id": "f38ce7d1",
18
- "metadata": {},
19
- "outputs": [],
20
- "source": [
21
- "df= pd.read_csv(\"../../data/oversampled_data_test_for_model/combined_sampled_data_test.csv\")"
22
- ]
23
- },
24
- {
25
- "cell_type": "code",
26
- "execution_count": 4,
27
- "id": "2bae91e4",
28
- "metadata": {},
29
- "outputs": [
30
- {
31
- "data": {
32
- "text/html": [
33
- "<div>\n",
34
- "<style scoped>\n",
35
- " .dataframe tbody tr th:only-of-type {\n",
36
- " vertical-align: middle;\n",
37
- " }\n",
38
- "\n",
39
- " .dataframe tbody tr th {\n",
40
- " vertical-align: top;\n",
41
- " }\n",
42
- "\n",
43
- " .dataframe thead th {\n",
44
- " text-align: right;\n",
45
- " }\n",
46
- "</style>\n",
47
- "<table border=\"1\" class=\"dataframe\">\n",
48
- " <thead>\n",
49
- " <tr style=\"text-align: right;\">\n",
50
- " <th></th>\n",
51
- " <th>region</th>\n",
52
- " <th>model</th>\n",
53
- " <th>data_sample</th>\n",
54
- " <th>CSI</th>\n",
55
- " <th>MCC</th>\n",
56
- " <th>Accuracy</th>\n",
57
- " <th>fold_csi</th>\n",
58
- " </tr>\n",
59
- " </thead>\n",
60
- " <tbody>\n",
61
- " <tr>\n",
62
- " <th>0</th>\n",
63
- " <td>seoul</td>\n",
64
- " <td>LightGBM</td>\n",
65
- " <td>pure</td>\n",
66
- " <td>0.505041</td>\n",
67
- " <td>0.646992</td>\n",
68
- " <td>0.936174</td>\n",
69
- " <td>[[0.46595932802825235, 0.5771195097037204, 0.4...</td>\n",
70
- " </tr>\n",
71
- " <tr>\n",
72
- " <th>1</th>\n",
73
- " <td>busan</td>\n",
74
- " <td>LightGBM</td>\n",
75
- " <td>pure</td>\n",
76
- " <td>0.430188</td>\n",
77
- " <td>0.600801</td>\n",
78
- " <td>0.956971</td>\n",
79
- " <td>[[0.32824427480911017, 0.4782608695651431, 0.4...</td>\n",
80
- " </tr>\n",
81
- " </tbody>\n",
82
- "</table>\n",
83
- "</div>"
84
- ],
85
- "text/plain": [
86
- " region model data_sample CSI MCC Accuracy \\\n",
87
- "0 seoul LightGBM pure 0.505041 0.646992 0.936174 \n",
88
- "1 busan LightGBM pure 0.430188 0.600801 0.956971 \n",
89
- "\n",
90
- " fold_csi \n",
91
- "0 [[0.46595932802825235, 0.5771195097037204, 0.4... \n",
92
- "1 [[0.32824427480911017, 0.4782608695651431, 0.4... "
93
- ]
94
- },
95
- "execution_count": 4,
96
- "metadata": {},
97
- "output_type": "execute_result"
98
- }
99
- ],
100
- "source": [
101
- "df.head(2)"
102
- ]
103
- },
104
- {
105
- "cell_type": "code",
106
- "execution_count": 5,
107
- "id": "6893a958",
108
- "metadata": {},
109
- "outputs": [
110
- {
111
- "data": {
112
- "text/html": [
113
- "<div>\n",
114
- "<style scoped>\n",
115
- " .dataframe tbody tr th:only-of-type {\n",
116
- " vertical-align: middle;\n",
117
- " }\n",
118
- "\n",
119
- " .dataframe tbody tr th {\n",
120
- " vertical-align: top;\n",
121
- " }\n",
122
- "\n",
123
- " .dataframe thead th {\n",
124
- " text-align: right;\n",
125
- " }\n",
126
- "</style>\n",
127
- "<table border=\"1\" class=\"dataframe\">\n",
128
- " <thead>\n",
129
- " <tr style=\"text-align: right;\">\n",
130
- " <th></th>\n",
131
- " <th>region</th>\n",
132
- " <th>model</th>\n",
133
- " <th>data_sample</th>\n",
134
- " <th>CSI</th>\n",
135
- " </tr>\n",
136
- " </thead>\n",
137
- " <tbody>\n",
138
- " <tr>\n",
139
- " <th>0</th>\n",
140
- " <td>busan</td>\n",
141
- " <td>LightGBM</td>\n",
142
- " <td>ctgan10000</td>\n",
143
- " <td>0.467663</td>\n",
144
- " </tr>\n",
145
- " <tr>\n",
146
- " <th>1</th>\n",
147
- " <td>daegu</td>\n",
148
- " <td>XGBoost</td>\n",
149
- " <td>smote</td>\n",
150
- " <td>0.454066</td>\n",
151
- " </tr>\n",
152
- " <tr>\n",
153
- " <th>2</th>\n",
154
- " <td>daejeon</td>\n",
155
- " <td>LightGBM</td>\n",
156
- " <td>smote</td>\n",
157
- " <td>0.521335</td>\n",
158
- " </tr>\n",
159
- " <tr>\n",
160
- " <th>3</th>\n",
161
- " <td>gwangju</td>\n",
162
- " <td>LightGBM</td>\n",
163
- " <td>smote</td>\n",
164
- " <td>0.522731</td>\n",
165
- " </tr>\n",
166
- " <tr>\n",
167
- " <th>4</th>\n",
168
- " <td>incheon</td>\n",
169
- " <td>XGBoost</td>\n",
170
- " <td>smote</td>\n",
171
- " <td>0.589146</td>\n",
172
- " </tr>\n",
173
- " <tr>\n",
174
- " <th>5</th>\n",
175
- " <td>seoul</td>\n",
176
- " <td>XGBoost</td>\n",
177
- " <td>smote</td>\n",
178
- " <td>0.582266</td>\n",
179
- " </tr>\n",
180
- " </tbody>\n",
181
- "</table>\n",
182
- "</div>"
183
- ],
184
- "text/plain": [
185
- " region model data_sample CSI\n",
186
- "0 busan LightGBM ctgan10000 0.467663\n",
187
- "1 daegu XGBoost smote 0.454066\n",
188
- "2 daejeon LightGBM smote 0.521335\n",
189
- "3 gwangju LightGBM smote 0.522731\n",
190
- "4 incheon XGBoost smote 0.589146\n",
191
- "5 seoul XGBoost smote 0.582266"
192
- ]
193
- },
194
- "execution_count": 5,
195
- "metadata": {},
196
- "output_type": "execute_result"
197
- }
198
- ],
199
- "source": [
200
- "# μ§€μ—­λ³„λ‘œ CSIκ°€ κ°€μž₯ 높은 modelκ³Ό data_sample μ‘°ν•© 보기\n",
201
- "top_csi_per_region = df.loc[df.groupby('region')['CSI'].idxmax()][['region', 'model', 'data_sample', 'CSI']]\n",
202
- "top_csi_per_region = top_csi_per_region.sort_values('region').reset_index(drop=True)\n",
203
- "top_csi_per_region"
204
- ]
205
- },
206
- {
207
- "cell_type": "code",
208
- "execution_count": null,
209
- "id": "2942ba86",
210
- "metadata": {},
211
- "outputs": [],
212
- "source": []
213
- },
214
- {
215
- "cell_type": "code",
216
- "execution_count": null,
217
- "id": "d55af59c",
218
- "metadata": {},
219
- "outputs": [],
220
- "source": []
221
- }
222
- ],
223
- "metadata": {
224
- "kernelspec": {
225
- "display_name": "py39",
226
- "language": "python",
227
- "name": "python3"
228
- },
229
- "language_info": {
230
- "codemirror_mode": {
231
- "name": "ipython",
232
- "version": 3
233
- },
234
- "file_extension": ".py",
235
- "mimetype": "text/x-python",
236
- "name": "python",
237
- "nbconvert_exporter": "python",
238
- "pygments_lexer": "ipython3",
239
- "version": "3.9.18"
240
- }
241
- },
242
- "nbformat": 4,
243
- "nbformat_minor": 5
244
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_daegu.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="deepgbm", region="daegu", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/deepgbm_ctgan10000_daegu_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="deepgbm",
79
+ region="daegu",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_daejeon.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="deepgbm", region="daejeon", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/deepgbm_ctgan10000_daejeon_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="deepgbm",
79
+ region="daejeon",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_gwangju.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="deepgbm", region="gwangju", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/deepgbm_ctgan10000_gwangju_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="deepgbm",
79
+ region="gwangju",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_incheon.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="deepgbm", region="incheon", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/deepgbm_ctgan10000_incheon_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="deepgbm",
79
+ region="incheon",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/deepgbm_ctgan10000/deepgbm_ctgan10000_seoul.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="deepgbm", region="seoul", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/deepgbm_ctgan10000_seoul_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="deepgbm",
79
+ region="seoul",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_daegu.py ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
16
+ def print_trial_callback(study, trial):
17
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
18
+ print(f"\n{'='*80}")
19
+ print(f"Trial {trial.number} μ™„λ£Œ")
20
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
21
+ print(f" Parameters: {trial.params}")
22
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
23
+ print(f" Best Trial: {study.best_trial.number}")
24
+ print(f" Best Parameters: {study.best_params}")
25
+ print(f"{'='*80}\n")
26
+
27
+
28
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
29
+ study = optuna.create_study(
30
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
31
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
32
+ )
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="ft_transformer", region="daegu", data_sample='ctgan10000'),
37
+ n_trials=100,
38
+ callbacks=[print_trial_callback]
39
+ )
40
+
41
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
42
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
43
+ print(f"Best CSI Score: {study.best_value:.4f}")
44
+ print(f"Best Hyperparameters: {study.best_params}")
45
+
46
+ try:
47
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
48
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
49
+
50
+ if len(csi_scores) > 0:
51
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
52
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
53
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
54
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
55
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
56
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
57
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
58
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
59
+
60
+ # Study 객체 μ €μž₯
61
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
62
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
63
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
64
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
65
+ study_path = os.path.join(base_dir, "optimization_history/ft_transformer_ctgan10000_daegu_trials.pkl")
66
+ joblib.dump(study, study_path)
67
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
68
+
69
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
70
+ print("\n" + "="*50)
71
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
72
+ print("="*50)
73
+
74
+ best_params = study.best_params
75
+ model_path = train_final_model(
76
+ best_params=best_params,
77
+ model_choose="ft_transformer",
78
+ region="daegu",
79
+ data_sample='ctgan10000',
80
+ target='multi',
81
+ n_folds=3,
82
+ random_state=seed
83
+ )
84
+
85
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
86
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
87
+
88
+ except Exception as e:
89
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
90
+ import traceback
91
+ traceback.print_exc()
92
+
93
+ # 정상 μ’…λ£Œ
94
+ import sys
95
+ sys.exit(0)
96
+
Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_daejeon.py ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
16
+ def print_trial_callback(study, trial):
17
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
18
+ print(f"\n{'='*80}")
19
+ print(f"Trial {trial.number} μ™„λ£Œ")
20
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
21
+ print(f" Parameters: {trial.params}")
22
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
23
+ print(f" Best Trial: {study.best_trial.number}")
24
+ print(f" Best Parameters: {study.best_params}")
25
+ print(f"{'='*80}\n")
26
+
27
+
28
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
29
+ study = optuna.create_study(
30
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
31
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
32
+ )
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="ft_transformer", region="daejeon", data_sample='ctgan10000'),
37
+ n_trials=100,
38
+ callbacks=[print_trial_callback]
39
+ )
40
+
41
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
42
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
43
+ print(f"Best CSI Score: {study.best_value:.4f}")
44
+ print(f"Best Hyperparameters: {study.best_params}")
45
+
46
+ try:
47
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
48
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
49
+
50
+ if len(csi_scores) > 0:
51
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
52
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
53
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
54
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
55
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
56
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
57
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
58
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
59
+
60
+ # Study 객체 μ €μž₯
61
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
62
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
63
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
64
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
65
+ study_path = os.path.join(base_dir, "optimization_history/ft_transformer_ctgan10000_daejeon_trials.pkl")
66
+ joblib.dump(study, study_path)
67
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
68
+
69
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
70
+ print("\n" + "="*50)
71
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
72
+ print("="*50)
73
+
74
+ best_params = study.best_params
75
+ model_path = train_final_model(
76
+ best_params=best_params,
77
+ model_choose="ft_transformer",
78
+ region="daejeon",
79
+ data_sample='ctgan10000',
80
+ target='multi',
81
+ n_folds=3,
82
+ random_state=seed
83
+ )
84
+
85
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
86
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
87
+
88
+ except Exception as e:
89
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
90
+ import traceback
91
+ traceback.print_exc()
92
+
93
+ # 정상 μ’…λ£Œ
94
+ import sys
95
+ sys.exit(0)
96
+
Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_gwangju.py ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
16
+ def print_trial_callback(study, trial):
17
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
18
+ print(f"\n{'='*80}")
19
+ print(f"Trial {trial.number} μ™„λ£Œ")
20
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
21
+ print(f" Parameters: {trial.params}")
22
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
23
+ print(f" Best Trial: {study.best_trial.number}")
24
+ print(f" Best Parameters: {study.best_params}")
25
+ print(f"{'='*80}\n")
26
+
27
+
28
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
29
+ study = optuna.create_study(
30
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
31
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
32
+ )
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="ft_transformer", region="gwangju", data_sample='ctgan10000'),
37
+ n_trials=100,
38
+ callbacks=[print_trial_callback]
39
+ )
40
+
41
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
42
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
43
+ print(f"Best CSI Score: {study.best_value:.4f}")
44
+ print(f"Best Hyperparameters: {study.best_params}")
45
+
46
+ try:
47
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
48
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
49
+
50
+ if len(csi_scores) > 0:
51
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
52
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
53
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
54
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
55
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
56
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
57
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
58
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
59
+
60
+ # Study 객체 μ €μž₯
61
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
62
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
63
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
64
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
65
+ study_path = os.path.join(base_dir, "optimization_history/ft_transformer_ctgan10000_gwangju_trials.pkl")
66
+ joblib.dump(study, study_path)
67
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
68
+
69
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
70
+ print("\n" + "="*50)
71
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
72
+ print("="*50)
73
+
74
+ best_params = study.best_params
75
+ model_path = train_final_model(
76
+ best_params=best_params,
77
+ model_choose="ft_transformer",
78
+ region="gwangju",
79
+ data_sample='ctgan10000',
80
+ target='multi',
81
+ n_folds=3,
82
+ random_state=seed
83
+ )
84
+
85
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
86
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
87
+
88
+ except Exception as e:
89
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
90
+ import traceback
91
+ traceback.print_exc()
92
+
93
+ # 정상 μ’…λ£Œ
94
+ import sys
95
+ sys.exit(0)
96
+
Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_incheon.py ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
16
+ def print_trial_callback(study, trial):
17
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
18
+ print(f"\n{'='*80}")
19
+ print(f"Trial {trial.number} μ™„λ£Œ")
20
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
21
+ print(f" Parameters: {trial.params}")
22
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
23
+ print(f" Best Trial: {study.best_trial.number}")
24
+ print(f" Best Parameters: {study.best_params}")
25
+ print(f"{'='*80}\n")
26
+
27
+
28
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
29
+ study = optuna.create_study(
30
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
31
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
32
+ )
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="ft_transformer", region="incheon", data_sample='ctgan10000'),
37
+ n_trials=100,
38
+ callbacks=[print_trial_callback]
39
+ )
40
+
41
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
42
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
43
+ print(f"Best CSI Score: {study.best_value:.4f}")
44
+ print(f"Best Hyperparameters: {study.best_params}")
45
+
46
+ try:
47
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
48
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
49
+
50
+ if len(csi_scores) > 0:
51
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
52
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
53
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
54
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
55
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
56
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
57
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
58
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
59
+
60
+ # Study 객체 μ €μž₯
61
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
62
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
63
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
64
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
65
+ study_path = os.path.join(base_dir, "optimization_history/ft_transformer_ctgan10000_incheon_trials.pkl")
66
+ joblib.dump(study, study_path)
67
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
68
+
69
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
70
+ print("\n" + "="*50)
71
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
72
+ print("="*50)
73
+
74
+ best_params = study.best_params
75
+ model_path = train_final_model(
76
+ best_params=best_params,
77
+ model_choose="ft_transformer",
78
+ region="incheon",
79
+ data_sample='ctgan10000',
80
+ target='multi',
81
+ n_folds=3,
82
+ random_state=seed
83
+ )
84
+
85
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
86
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
87
+
88
+ except Exception as e:
89
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
90
+ import traceback
91
+ traceback.print_exc()
92
+
93
+ # 정상 μ’…λ£Œ
94
+ import sys
95
+ sys.exit(0)
96
+
Analysis_code/5.optima/ft_transformer_ctgan10000/ft_transformer_ctgan10000_seoul.py ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
16
+ def print_trial_callback(study, trial):
17
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
18
+ print(f"\n{'='*80}")
19
+ print(f"Trial {trial.number} μ™„λ£Œ")
20
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
21
+ print(f" Parameters: {trial.params}")
22
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
23
+ print(f" Best Trial: {study.best_trial.number}")
24
+ print(f" Best Parameters: {study.best_params}")
25
+ print(f"{'='*80}\n")
26
+
27
+
28
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
29
+ study = optuna.create_study(
30
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
31
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
32
+ )
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="ft_transformer", region="seoul", data_sample='ctgan10000'),
37
+ n_trials=100,
38
+ callbacks=[print_trial_callback]
39
+ )
40
+
41
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
42
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
43
+ print(f"Best CSI Score: {study.best_value:.4f}")
44
+ print(f"Best Hyperparameters: {study.best_params}")
45
+
46
+ try:
47
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
48
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
49
+
50
+ if len(csi_scores) > 0:
51
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
52
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
53
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
54
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
55
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
56
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
57
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
58
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
59
+
60
+ # Study 객체 μ €μž₯
61
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
62
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
63
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
64
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
65
+ study_path = os.path.join(base_dir, "optimization_history/ft_transformer_ctgan10000_seoul_trials.pkl")
66
+ joblib.dump(study, study_path)
67
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
68
+
69
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
70
+ print("\n" + "="*50)
71
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
72
+ print("="*50)
73
+
74
+ best_params = study.best_params
75
+ model_path = train_final_model(
76
+ best_params=best_params,
77
+ model_choose="ft_transformer",
78
+ region="seoul",
79
+ data_sample='ctgan10000',
80
+ target='multi',
81
+ n_folds=3,
82
+ random_state=seed
83
+ )
84
+
85
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
86
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
87
+
88
+ except Exception as e:
89
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
90
+ import traceback
91
+ traceback.print_exc()
92
+
93
+ # 정상 μ’…λ£Œ
94
+ import sys
95
+ sys.exit(0)
96
+
Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_busan.py CHANGED
@@ -281,6 +281,7 @@ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
281
 
282
  # Trials 객체 μ €μž₯
283
  import os
 
284
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
285
  trials_path = os.path.join(base_dir, "optimization_history/lgb_ctgan10000_busan_trials.pkl")
286
  joblib.dump(trials, trials_path)
 
281
 
282
  # Trials 객체 μ €μž₯
283
  import os
284
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
285
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
286
  trials_path = os.path.join(base_dir, "optimization_history/lgb_ctgan10000_busan_trials.pkl")
287
  joblib.dump(trials, trials_path)
Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_daegu.py ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import pandas as pd
2
+ import numpy as np
3
+ import joblib
4
+ import os
5
+ from warnings import filterwarnings
6
+ from sklearn.metrics import confusion_matrix
7
+ from lightgbm import LGBMClassifier
8
+ from hyperopt import fmin, tpe, Trials, hp
9
+
10
+ filterwarnings('ignore')
11
+
12
+ # μƒμˆ˜ μ •μ˜
13
+ RANDOM_STATE = 42
14
+ N_ESTIMATORS = 4000
15
+ EARLY_STOPPING_ROUNDS = 400
16
+ MAX_EVALS = 100
17
+ DEVICE = 'gpu'
18
+ OBJECTIVE = 'multiclassova'
19
+
20
+ # Fold μ„€μ •: (train_years, val_year)
21
+ FOLD_CONFIGS = [
22
+ ([2018, 2019], 2020), # Fold 1
23
+ ([2018, 2020], 2019), # Fold 2
24
+ ([2019, 2020], 2018), # Fold 3
25
+ ]
26
+
27
+ def calculate_csi(y_true, y_pred):
28
+ """CSI(Critical Success Index) 점수λ₯Ό κ³„μ‚°ν•©λ‹ˆλ‹€.
29
+
30
+ Args:
31
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
32
+ y_pred: 예츑 λ ˆμ΄λΈ”
33
+
34
+ Returns:
35
+ CSI 점수 (0~1 μ‚¬μ΄μ˜ κ°’)
36
+ """
37
+ cm = confusion_matrix(y_true, y_pred)
38
+
39
+ # ν˜Όλ™ ν–‰λ ¬μ—μ„œ H(Hit), F(False alarm), M(Miss) μΆ”μΆœ
40
+ H = cm[0, 0] + cm[1, 1]
41
+ F = cm[1, 0] + cm[2, 0] + cm[0, 1] + cm[2, 1]
42
+ M = cm[0, 2] + cm[1, 2]
43
+
44
+ # CSI 계산
45
+ csi = H / (H + F + M + 1e-10)
46
+ return csi
47
+
48
+
49
+ def csi_metric(y_true, pred_prob):
50
+ """LightGBM용 CSI λ©”νŠΈλ¦­ ν•¨μˆ˜.
51
+
52
+ Args:
53
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
54
+ pred_prob: 예츑 ν™•λ₯  (shape: [n_samples, n_classes])
55
+
56
+ Returns:
57
+ ('CSI', score, higher_better) νŠœν”Œ
58
+ """
59
+ y_pred_binary = np.argmax(pred_prob, axis=1)
60
+ score = calculate_csi(y_true, y_pred_binary)
61
+ return 'CSI', score, True
62
+
63
+ def add_derived_features(df: pd.DataFrame) -> pd.DataFrame:
64
+ """
65
+ μ œκ±°ν–ˆλ˜ νŒŒμƒ λ³€μˆ˜λ“€μ„ 볡ꡬ
66
+
67
+ Args:
68
+ df: λ°μ΄ν„°ν”„λ ˆμž„
69
+
70
+ Returns:
71
+ νŒŒμƒ λ³€μˆ˜κ°€ μΆ”κ°€λœ λ°μ΄ν„°ν”„λ ˆμž„
72
+ """
73
+ df = df.copy()
74
+ df['hour_sin'] = np.sin(2 * np.pi * df['hour'] / 24)
75
+ df['hour_cos'] = np.cos(2 * np.pi * df['hour'] / 24)
76
+ df['month_sin'] = np.sin(2 * np.pi * df['month'] / 12)
77
+ df['month_cos'] = np.cos(2 * np.pi * df['month'] / 12)
78
+ df['ground_temp - temp_C'] = df['groundtemp'] - df['temp_C']
79
+ return df
80
+
81
+ def preprocessing(df):
82
+ """데이터 μ „μ²˜λ¦¬ ν•¨μˆ˜.
83
+
84
+ Args:
85
+ df: 원본 λ°μ΄ν„°ν”„λ ˆμž„
86
+
87
+ Returns:
88
+ μ „μ²˜λ¦¬λœ λ°μ΄ν„°ν”„λ ˆμž„
89
+ """
90
+ df = df[df.columns].copy()
91
+ df['year'] = df['year'].astype('int')
92
+ df['month'] = df['month'].astype('int')
93
+ df['hour'] = df['hour'].astype('int')
94
+ df = add_derived_features(df).copy()
95
+ df['multi_class'] = df['multi_class'].astype('int')
96
+ df.loc[df['wind_dir']=='μ •μ˜¨', 'wind_dir'] = "0"
97
+ df['wind_dir'] = df['wind_dir'].astype('int')
98
+ df = df[['temp_C', 'precip_mm', 'wind_speed', 'wind_dir', 'hm',
99
+ 'vap_pressure', 'dewpoint_C', 'loc_pressure', 'sea_pressure',
100
+ 'solarRad', 'snow_cm', 'cloudcover', 'lm_cloudcover', 'low_cloudbase',
101
+ 'groundtemp', 'O3', 'NO2', 'PM10', 'PM25', 'year',
102
+ 'month', 'hour', 'ground_temp - temp_C', 'hour_sin', 'hour_cos',
103
+ 'month_sin', 'month_cos','multi_class']].copy()
104
+ return df
105
+
106
+
107
+ def split_data(df_sampled, df_original, train_years, val_year):
108
+ """데이터λ₯Ό ν•™μŠ΅μš©κ³Ό κ²€μ¦μš©μœΌλ‘œ λΆ„ν• ν•©λ‹ˆλ‹€.
109
+
110
+ Args:
111
+ df_sampled: μƒ˜ν”Œλ§λœ λ°μ΄ν„°ν”„λ ˆμž„
112
+ df_original: 원본 λ°μ΄ν„°ν”„λ ˆμž„
113
+ train_years: ν•™μŠ΅μ— μ‚¬μš©ν•  연도 리슀트
114
+ val_year: 검증에 μ‚¬μš©ν•  연도
115
+
116
+ Returns:
117
+ (X_train, X_val, y_train, y_val) νŠœν”Œ
118
+ """
119
+ # ν•™μŠ΅ 데이터: μƒ˜ν”Œλ§λœ λ°μ΄ν„°μ—μ„œ train_years에 ν•΄λ‹Ήν•˜λŠ” 데이터
120
+ train_mask = df_sampled['year'].isin(train_years)
121
+ X_train = df_sampled.loc[train_mask, df_sampled.columns != 'multi_class'].copy()
122
+ y_train = df_sampled.loc[train_mask, 'multi_class']
123
+
124
+ # 검증 데이터: 원본 λ°μ΄ν„°μ—μ„œ val_year에 ν•΄λ‹Ήν•˜λŠ” 데이터
125
+ val_mask = df_original['year'] == val_year
126
+ X_val = df_original.loc[val_mask, df_original.columns != 'multi_class'].copy()
127
+ y_val = df_original.loc[val_mask, 'multi_class']
128
+
129
+ # 'year' 컬럼 제거
130
+ X_train = X_train.drop(columns=['year'])
131
+ X_val = X_val.drop(columns=['year'])
132
+
133
+ return X_train, X_val, y_train, y_val
134
+
135
+
136
+ def create_lgb_model(search_space=None, best_params=None):
137
+ """LightGBM λͺ¨λΈμ„ μƒμ„±ν•©λ‹ˆλ‹€.
138
+
139
+ Args:
140
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 (objective_funcμ—μ„œ μ‚¬μš©)
141
+ best_params: μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„° (μ΅œμ’… λͺ¨λΈ ν•™μŠ΅μ—μ„œ μ‚¬μš©)
142
+
143
+ Returns:
144
+ LGBMClassifier μΈμŠ€ν„΄μŠ€
145
+ """
146
+ base_params = {
147
+ 'n_estimators': N_ESTIMATORS,
148
+ 'device': DEVICE,
149
+ 'objective': OBJECTIVE,
150
+ 'random_state': RANDOM_STATE,
151
+ 'early_stopping_rounds': EARLY_STOPPING_ROUNDS,
152
+ 'verbose': -1,
153
+ }
154
+
155
+ if search_space is not None:
156
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” 쀑
157
+ params = {
158
+ **base_params,
159
+ 'learning_rate': search_space['learning_rate'],
160
+ 'max_depth': int(search_space['max_depth']),
161
+ 'num_leaves': int(search_space['num_leaves']),
162
+ 'min_child_weight': int(search_space['min_child_weight']),
163
+ 'subsample': search_space['subsample'],
164
+ 'colsample_bytree': search_space['colsample_bytree'],
165
+ 'reg_alpha': search_space['reg_alpha'],
166
+ 'reg_lambda': search_space['reg_lambda'],
167
+ }
168
+ elif best_params is not None:
169
+ # μ΅œμ ν™”λœ νŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ 생성
170
+ params = {
171
+ **base_params,
172
+ 'learning_rate': best_params['learning_rate'],
173
+ 'max_depth': int(best_params['max_depth']),
174
+ 'num_leaves': int(best_params['num_leaves']),
175
+ 'min_child_weight': int(best_params['min_child_weight']),
176
+ 'subsample': best_params['subsample'],
177
+ 'colsample_bytree': best_params['colsample_bytree'],
178
+ 'reg_alpha': best_params['reg_alpha'],
179
+ 'reg_lambda': best_params['reg_lambda'],
180
+ }
181
+ else:
182
+ params = base_params
183
+
184
+ return LGBMClassifier(**params)
185
+
186
+ # 데이터 λ‘œλ”©
187
+ print("데이터 λ‘œλ”© 쀑...")
188
+ # 파일 μœ„μΉ˜ 기반으둜 데이터 디렉토리 경둜 μ„€μ •
189
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
190
+ data_base_dir = os.path.abspath(os.path.join(current_file_dir, '../../../data'))
191
+ df_daegu = pd.read_csv(os.path.join(data_base_dir, "data_for_modeling/daegu_train.csv"))
192
+ df_ctgan_daegu_1 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_1_daegu.csv"))
193
+ df_ctgan_daegu_2 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_2_daegu.csv"))
194
+ df_ctgan_daegu_3 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_3_daegu.csv"))
195
+
196
+ # 데이터 μ „μ²˜λ¦¬
197
+ print("데이터 μ „μ²˜λ¦¬ 쀑...")
198
+ df_ctgan_daegu_1 = preprocessing(df_ctgan_daegu_1)
199
+ df_ctgan_daegu_2 = preprocessing(df_ctgan_daegu_2)
200
+ df_ctgan_daegu_3 = preprocessing(df_ctgan_daegu_3)
201
+ df_daegu = preprocessing(df_daegu)
202
+
203
+ # CTGAN 데이터 리슀트 (fold μˆœμ„œμ™€ 일치)
204
+ df_ctgan_list = [df_ctgan_daegu_1, df_ctgan_daegu_2, df_ctgan_daegu_3]
205
+
206
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 μ •μ˜
207
+ lgb_search_space = {
208
+ 'learning_rate': hp.loguniform('learning_rate', np.log(0.01), np.log(0.2)),
209
+ 'max_depth': hp.quniform('max_depth', 3, 15, 1),
210
+ 'num_leaves': hp.quniform('num_leaves', 20, 150, 1), # 2^max_depth λ³΄λ‹€λŠ” μž‘κ²Œ
211
+ 'min_child_weight': hp.quniform('min_child_weight', 1, 20, 1),
212
+ 'subsample': hp.uniform('subsample', 0.6, 1.0),
213
+ 'colsample_bytree': hp.uniform('colsample_bytree', 0.6, 1.0),
214
+ 'reg_alpha': hp.uniform('reg_alpha', 0.0, 1.0),
215
+ 'reg_lambda': hp.uniform('reg_lambda', 0.0, 1.0)
216
+ }
217
+
218
+
219
+ def objective_func(search_space):
220
+ """ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”λ₯Ό μœ„ν•œ λͺ©μ  ν•¨μˆ˜.
221
+
222
+ Args:
223
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간
224
+
225
+ Returns:
226
+ 평균 CSI 점수의 μŒμˆ˜κ°’ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰ν•˜λ―€λ‘œ)
227
+ """
228
+ lgb_model = create_lgb_model(search_space=search_space)
229
+ csi_scores = []
230
+
231
+ # 각 fold에 λŒ€ν•΄ ꡐ차 검증 μˆ˜ν–‰
232
+ for df_ctgan, (train_years, val_year) in zip(df_ctgan_list, FOLD_CONFIGS):
233
+ X_train, X_val, y_train, y_val = split_data(
234
+ df_ctgan, df_daegu, train_years, val_year
235
+ )
236
+
237
+ lgb_model.fit(
238
+ X_train, y_train,
239
+ eval_set=[(X_val, y_val)],
240
+ eval_metric=csi_metric
241
+ )
242
+
243
+ csi = calculate_csi(y_val, lgb_model.predict(X_val))
244
+ csi_scores.append(csi)
245
+
246
+ # 평균 CSI의 μŒμˆ˜κ°’ λ°˜ν™˜ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰)
247
+ return -1 * round(np.mean(csi_scores), 4)
248
+
249
+
250
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”
251
+ print("ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...")
252
+ trials = Trials()
253
+ lgb_best = fmin(
254
+ fn=objective_func,
255
+ space=lgb_search_space,
256
+ algo=tpe.suggest,
257
+ max_evals=MAX_EVALS,
258
+ trials=trials
259
+ )
260
+
261
+ # μ΅œμ ν™” κ²°κ³Ό 뢄석 및 좜λ ₯
262
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
263
+
264
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
265
+ best_loss = trials.best_trial['result']['loss']
266
+ best_csi = -best_loss
267
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
268
+
269
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
270
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
271
+ csi_scores = [-loss for loss in losses]
272
+
273
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
274
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
275
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
276
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
277
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
278
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
279
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
280
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
281
+
282
+ # Trials 객체 μ €μž₯
283
+ import os
284
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
285
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
286
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_ctgan10000_daegu_trials.pkl")
287
+ joblib.dump(trials, trials_path)
288
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
289
+
290
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
291
+ print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
292
+ models = []
293
+
294
+ for fold_idx, (df_ctgan, (train_years, val_year)) in enumerate(
295
+ zip(df_ctgan_list, FOLD_CONFIGS), start=1
296
+ ):
297
+ print(f"Fold {fold_idx} ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: {train_years}, 검증 연도: {val_year})")
298
+
299
+ X_train, X_val, y_train, y_val = split_data(
300
+ df_ctgan, df_daegu, train_years, val_year
301
+ )
302
+
303
+ lgb_model = create_lgb_model(best_params=lgb_best)
304
+ lgb_model.fit(X_train, y_train, eval_set=[(X_val, y_val)])
305
+
306
+ # 검증 μ„±λŠ₯ 좜λ ₯
307
+ val_csi = calculate_csi(y_val, lgb_model.predict(X_val))
308
+ print(f"Fold {fold_idx} 검증 CSI: {val_csi:.4f}")
309
+
310
+ models.append(lgb_model)
311
+
312
+ # λͺ¨λΈ μ €μž₯
313
+ print("λͺ¨λΈ μ €μž₯ 쀑...")
314
+ model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_ctgan10000_daegu.pkl")
315
+ joblib.dump(models, model_save_path)
316
+ print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
317
+
Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_daejeon.py ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import pandas as pd
2
+ import numpy as np
3
+ import joblib
4
+ import os
5
+ from warnings import filterwarnings
6
+ from sklearn.metrics import confusion_matrix
7
+ from lightgbm import LGBMClassifier
8
+ from hyperopt import fmin, tpe, Trials, hp
9
+
10
+ filterwarnings('ignore')
11
+
12
+ # μƒμˆ˜ μ •μ˜
13
+ RANDOM_STATE = 42
14
+ N_ESTIMATORS = 4000
15
+ EARLY_STOPPING_ROUNDS = 400
16
+ MAX_EVALS = 100
17
+ DEVICE = 'gpu'
18
+ OBJECTIVE = 'multiclassova'
19
+
20
+ # Fold μ„€μ •: (train_years, val_year)
21
+ FOLD_CONFIGS = [
22
+ ([2018, 2019], 2020), # Fold 1
23
+ ([2018, 2020], 2019), # Fold 2
24
+ ([2019, 2020], 2018), # Fold 3
25
+ ]
26
+
27
+ def calculate_csi(y_true, y_pred):
28
+ """CSI(Critical Success Index) 점수λ₯Ό κ³„μ‚°ν•©λ‹ˆλ‹€.
29
+
30
+ Args:
31
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
32
+ y_pred: 예츑 λ ˆμ΄λΈ”
33
+
34
+ Returns:
35
+ CSI 점수 (0~1 μ‚¬μ΄μ˜ κ°’)
36
+ """
37
+ cm = confusion_matrix(y_true, y_pred)
38
+
39
+ # ν˜Όλ™ ν–‰λ ¬μ—μ„œ H(Hit), F(False alarm), M(Miss) μΆ”μΆœ
40
+ H = cm[0, 0] + cm[1, 1]
41
+ F = cm[1, 0] + cm[2, 0] + cm[0, 1] + cm[2, 1]
42
+ M = cm[0, 2] + cm[1, 2]
43
+
44
+ # CSI 계산
45
+ csi = H / (H + F + M + 1e-10)
46
+ return csi
47
+
48
+
49
+ def csi_metric(y_true, pred_prob):
50
+ """LightGBM용 CSI λ©”νŠΈλ¦­ ν•¨μˆ˜.
51
+
52
+ Args:
53
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
54
+ pred_prob: 예츑 ν™•λ₯  (shape: [n_samples, n_classes])
55
+
56
+ Returns:
57
+ ('CSI', score, higher_better) νŠœν”Œ
58
+ """
59
+ y_pred_binary = np.argmax(pred_prob, axis=1)
60
+ score = calculate_csi(y_true, y_pred_binary)
61
+ return 'CSI', score, True
62
+
63
+ def add_derived_features(df: pd.DataFrame) -> pd.DataFrame:
64
+ """
65
+ μ œκ±°ν–ˆλ˜ νŒŒμƒ λ³€μˆ˜λ“€μ„ 볡ꡬ
66
+
67
+ Args:
68
+ df: λ°μ΄ν„°ν”„λ ˆμž„
69
+
70
+ Returns:
71
+ νŒŒμƒ λ³€μˆ˜κ°€ μΆ”κ°€λœ λ°μ΄ν„°ν”„λ ˆμž„
72
+ """
73
+ df = df.copy()
74
+ df['hour_sin'] = np.sin(2 * np.pi * df['hour'] / 24)
75
+ df['hour_cos'] = np.cos(2 * np.pi * df['hour'] / 24)
76
+ df['month_sin'] = np.sin(2 * np.pi * df['month'] / 12)
77
+ df['month_cos'] = np.cos(2 * np.pi * df['month'] / 12)
78
+ df['ground_temp - temp_C'] = df['groundtemp'] - df['temp_C']
79
+ return df
80
+
81
+ def preprocessing(df):
82
+ """데이터 μ „μ²˜λ¦¬ ν•¨μˆ˜.
83
+
84
+ Args:
85
+ df: 원본 λ°μ΄ν„°ν”„λ ˆμž„
86
+
87
+ Returns:
88
+ μ „μ²˜λ¦¬λœ λ°μ΄ν„°ν”„λ ˆμž„
89
+ """
90
+ df = df[df.columns].copy()
91
+ df['year'] = df['year'].astype('int')
92
+ df['month'] = df['month'].astype('int')
93
+ df['hour'] = df['hour'].astype('int')
94
+ df = add_derived_features(df).copy()
95
+ df['multi_class'] = df['multi_class'].astype('int')
96
+ df.loc[df['wind_dir']=='μ •μ˜¨', 'wind_dir'] = "0"
97
+ df['wind_dir'] = df['wind_dir'].astype('int')
98
+ df = df[['temp_C', 'precip_mm', 'wind_speed', 'wind_dir', 'hm',
99
+ 'vap_pressure', 'dewpoint_C', 'loc_pressure', 'sea_pressure',
100
+ 'solarRad', 'snow_cm', 'cloudcover', 'lm_cloudcover', 'low_cloudbase',
101
+ 'groundtemp', 'O3', 'NO2', 'PM10', 'PM25', 'year',
102
+ 'month', 'hour', 'ground_temp - temp_C', 'hour_sin', 'hour_cos',
103
+ 'month_sin', 'month_cos','multi_class']].copy()
104
+ return df
105
+
106
+
107
+ def split_data(df_sampled, df_original, train_years, val_year):
108
+ """데이터λ₯Ό ν•™μŠ΅μš©κ³Ό κ²€μ¦μš©μœΌλ‘œ λΆ„ν• ν•©λ‹ˆλ‹€.
109
+
110
+ Args:
111
+ df_sampled: μƒ˜ν”Œλ§λœ λ°μ΄ν„°ν”„λ ˆμž„
112
+ df_original: 원본 λ°μ΄ν„°ν”„λ ˆμž„
113
+ train_years: ν•™μŠ΅μ— μ‚¬μš©ν•  연도 리슀트
114
+ val_year: 검증에 μ‚¬μš©ν•  연도
115
+
116
+ Returns:
117
+ (X_train, X_val, y_train, y_val) νŠœν”Œ
118
+ """
119
+ # ν•™μŠ΅ 데이터: μƒ˜ν”Œλ§λœ λ°μ΄ν„°μ—μ„œ train_years에 ν•΄λ‹Ήν•˜λŠ” 데이터
120
+ train_mask = df_sampled['year'].isin(train_years)
121
+ X_train = df_sampled.loc[train_mask, df_sampled.columns != 'multi_class'].copy()
122
+ y_train = df_sampled.loc[train_mask, 'multi_class']
123
+
124
+ # 검증 데이터: 원본 λ°μ΄ν„°μ—μ„œ val_year에 ν•΄λ‹Ήν•˜λŠ” 데이터
125
+ val_mask = df_original['year'] == val_year
126
+ X_val = df_original.loc[val_mask, df_original.columns != 'multi_class'].copy()
127
+ y_val = df_original.loc[val_mask, 'multi_class']
128
+
129
+ # 'year' 컬럼 제거
130
+ X_train = X_train.drop(columns=['year'])
131
+ X_val = X_val.drop(columns=['year'])
132
+
133
+ return X_train, X_val, y_train, y_val
134
+
135
+
136
+ def create_lgb_model(search_space=None, best_params=None):
137
+ """LightGBM λͺ¨λΈμ„ μƒμ„±ν•©λ‹ˆλ‹€.
138
+
139
+ Args:
140
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 (objective_funcμ—μ„œ μ‚¬μš©)
141
+ best_params: μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„° (μ΅œμ’… λͺ¨λΈ ν•™μŠ΅μ—μ„œ μ‚¬μš©)
142
+
143
+ Returns:
144
+ LGBMClassifier μΈμŠ€ν„΄μŠ€
145
+ """
146
+ base_params = {
147
+ 'n_estimators': N_ESTIMATORS,
148
+ 'device': DEVICE,
149
+ 'objective': OBJECTIVE,
150
+ 'random_state': RANDOM_STATE,
151
+ 'early_stopping_rounds': EARLY_STOPPING_ROUNDS,
152
+ 'verbose': -1,
153
+ }
154
+
155
+ if search_space is not None:
156
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” 쀑
157
+ params = {
158
+ **base_params,
159
+ 'learning_rate': search_space['learning_rate'],
160
+ 'max_depth': int(search_space['max_depth']),
161
+ 'num_leaves': int(search_space['num_leaves']),
162
+ 'min_child_weight': int(search_space['min_child_weight']),
163
+ 'subsample': search_space['subsample'],
164
+ 'colsample_bytree': search_space['colsample_bytree'],
165
+ 'reg_alpha': search_space['reg_alpha'],
166
+ 'reg_lambda': search_space['reg_lambda'],
167
+ }
168
+ elif best_params is not None:
169
+ # μ΅œμ ν™”λœ νŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ 생성
170
+ params = {
171
+ **base_params,
172
+ 'learning_rate': best_params['learning_rate'],
173
+ 'max_depth': int(best_params['max_depth']),
174
+ 'num_leaves': int(best_params['num_leaves']),
175
+ 'min_child_weight': int(best_params['min_child_weight']),
176
+ 'subsample': best_params['subsample'],
177
+ 'colsample_bytree': best_params['colsample_bytree'],
178
+ 'reg_alpha': best_params['reg_alpha'],
179
+ 'reg_lambda': best_params['reg_lambda'],
180
+ }
181
+ else:
182
+ params = base_params
183
+
184
+ return LGBMClassifier(**params)
185
+
186
+ # 데이터 λ‘œλ”©
187
+ print("데이터 λ‘œλ”© 쀑...")
188
+ # 파일 μœ„μΉ˜ 기반으둜 데이터 디렉토리 경둜 μ„€μ •
189
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
190
+ data_base_dir = os.path.abspath(os.path.join(current_file_dir, '../../../data'))
191
+ df_daejeon = pd.read_csv(os.path.join(data_base_dir, "data_for_modeling/daejeon_train.csv"))
192
+ df_ctgan_daejeon_1 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_1_daejeon.csv"))
193
+ df_ctgan_daejeon_2 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_2_daejeon.csv"))
194
+ df_ctgan_daejeon_3 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_3_daejeon.csv"))
195
+
196
+ # 데이터 μ „μ²˜λ¦¬
197
+ print("데이터 μ „μ²˜λ¦¬ 쀑...")
198
+ df_ctgan_daejeon_1 = preprocessing(df_ctgan_daejeon_1)
199
+ df_ctgan_daejeon_2 = preprocessing(df_ctgan_daejeon_2)
200
+ df_ctgan_daejeon_3 = preprocessing(df_ctgan_daejeon_3)
201
+ df_daejeon = preprocessing(df_daejeon)
202
+
203
+ # CTGAN 데이터 리슀트 (fold μˆœμ„œμ™€ 일치)
204
+ df_ctgan_list = [df_ctgan_daejeon_1, df_ctgan_daejeon_2, df_ctgan_daejeon_3]
205
+
206
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 μ •μ˜
207
+ lgb_search_space = {
208
+ 'learning_rate': hp.loguniform('learning_rate', np.log(0.01), np.log(0.2)),
209
+ 'max_depth': hp.quniform('max_depth', 3, 15, 1),
210
+ 'num_leaves': hp.quniform('num_leaves', 20, 150, 1), # 2^max_depth λ³΄λ‹€λŠ” μž‘κ²Œ
211
+ 'min_child_weight': hp.quniform('min_child_weight', 1, 20, 1),
212
+ 'subsample': hp.uniform('subsample', 0.6, 1.0),
213
+ 'colsample_bytree': hp.uniform('colsample_bytree', 0.6, 1.0),
214
+ 'reg_alpha': hp.uniform('reg_alpha', 0.0, 1.0),
215
+ 'reg_lambda': hp.uniform('reg_lambda', 0.0, 1.0)
216
+ }
217
+
218
+
219
+ def objective_func(search_space):
220
+ """ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”λ₯Ό μœ„ν•œ λͺ©μ  ν•¨μˆ˜.
221
+
222
+ Args:
223
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간
224
+
225
+ Returns:
226
+ 평균 CSI 점수의 μŒμˆ˜κ°’ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰ν•˜λ―€λ‘œ)
227
+ """
228
+ lgb_model = create_lgb_model(search_space=search_space)
229
+ csi_scores = []
230
+
231
+ # 각 fold에 λŒ€ν•΄ ꡐ차 검증 μˆ˜ν–‰
232
+ for df_ctgan, (train_years, val_year) in zip(df_ctgan_list, FOLD_CONFIGS):
233
+ X_train, X_val, y_train, y_val = split_data(
234
+ df_ctgan, df_daejeon, train_years, val_year
235
+ )
236
+
237
+ lgb_model.fit(
238
+ X_train, y_train,
239
+ eval_set=[(X_val, y_val)],
240
+ eval_metric=csi_metric
241
+ )
242
+
243
+ csi = calculate_csi(y_val, lgb_model.predict(X_val))
244
+ csi_scores.append(csi)
245
+
246
+ # 평균 CSI의 μŒμˆ˜κ°’ λ°˜ν™˜ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰)
247
+ return -1 * round(np.mean(csi_scores), 4)
248
+
249
+
250
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”
251
+ print("ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...")
252
+ trials = Trials()
253
+ lgb_best = fmin(
254
+ fn=objective_func,
255
+ space=lgb_search_space,
256
+ algo=tpe.suggest,
257
+ max_evals=MAX_EVALS,
258
+ trials=trials
259
+ )
260
+
261
+ # μ΅œμ ν™” κ²°κ³Ό 뢄석 및 좜λ ₯
262
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
263
+
264
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
265
+ best_loss = trials.best_trial['result']['loss']
266
+ best_csi = -best_loss
267
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
268
+
269
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
270
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
271
+ csi_scores = [-loss for loss in losses]
272
+
273
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
274
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
275
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
276
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
277
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
278
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
279
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
280
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
281
+
282
+ # Trials 객체 μ €μž₯
283
+ import os
284
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima ���렉토리
285
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
286
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_ctgan10000_daejeon_trials.pkl")
287
+ joblib.dump(trials, trials_path)
288
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
289
+
290
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
291
+ print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
292
+ models = []
293
+
294
+ for fold_idx, (df_ctgan, (train_years, val_year)) in enumerate(
295
+ zip(df_ctgan_list, FOLD_CONFIGS), start=1
296
+ ):
297
+ print(f"Fold {fold_idx} ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: {train_years}, 검증 연도: {val_year})")
298
+
299
+ X_train, X_val, y_train, y_val = split_data(
300
+ df_ctgan, df_daejeon, train_years, val_year
301
+ )
302
+
303
+ lgb_model = create_lgb_model(best_params=lgb_best)
304
+ lgb_model.fit(X_train, y_train, eval_set=[(X_val, y_val)])
305
+
306
+ # 검증 μ„±λŠ₯ 좜λ ₯
307
+ val_csi = calculate_csi(y_val, lgb_model.predict(X_val))
308
+ print(f"Fold {fold_idx} 검증 CSI: {val_csi:.4f}")
309
+
310
+ models.append(lgb_model)
311
+
312
+ # λͺ¨λΈ μ €μž₯
313
+ print("λͺ¨λΈ μ €μž₯ 쀑...")
314
+ model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_ctgan10000_daejeon.pkl")
315
+ joblib.dump(models, model_save_path)
316
+ print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
317
+
Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_gwangju.py ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import pandas as pd
2
+ import numpy as np
3
+ import joblib
4
+ import os
5
+ from warnings import filterwarnings
6
+ from sklearn.metrics import confusion_matrix
7
+ from lightgbm import LGBMClassifier
8
+ from hyperopt import fmin, tpe, Trials, hp
9
+
10
+ filterwarnings('ignore')
11
+
12
+ # μƒμˆ˜ μ •μ˜
13
+ RANDOM_STATE = 42
14
+ N_ESTIMATORS = 4000
15
+ EARLY_STOPPING_ROUNDS = 400
16
+ MAX_EVALS = 100
17
+ DEVICE = 'gpu'
18
+ OBJECTIVE = 'multiclassova'
19
+
20
+ # Fold μ„€μ •: (train_years, val_year)
21
+ FOLD_CONFIGS = [
22
+ ([2018, 2019], 2020), # Fold 1
23
+ ([2018, 2020], 2019), # Fold 2
24
+ ([2019, 2020], 2018), # Fold 3
25
+ ]
26
+
27
+ def calculate_csi(y_true, y_pred):
28
+ """CSI(Critical Success Index) 점수λ₯Ό κ³„μ‚°ν•©λ‹ˆλ‹€.
29
+
30
+ Args:
31
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
32
+ y_pred: 예츑 λ ˆμ΄λΈ”
33
+
34
+ Returns:
35
+ CSI 점수 (0~1 μ‚¬μ΄μ˜ κ°’)
36
+ """
37
+ cm = confusion_matrix(y_true, y_pred)
38
+
39
+ # ν˜Όλ™ ν–‰λ ¬μ—μ„œ H(Hit), F(False alarm), M(Miss) μΆ”μΆœ
40
+ H = cm[0, 0] + cm[1, 1]
41
+ F = cm[1, 0] + cm[2, 0] + cm[0, 1] + cm[2, 1]
42
+ M = cm[0, 2] + cm[1, 2]
43
+
44
+ # CSI 계산
45
+ csi = H / (H + F + M + 1e-10)
46
+ return csi
47
+
48
+
49
+ def csi_metric(y_true, pred_prob):
50
+ """LightGBM용 CSI λ©”νŠΈλ¦­ ν•¨μˆ˜.
51
+
52
+ Args:
53
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
54
+ pred_prob: 예츑 ν™•λ₯  (shape: [n_samples, n_classes])
55
+
56
+ Returns:
57
+ ('CSI', score, higher_better) νŠœν”Œ
58
+ """
59
+ y_pred_binary = np.argmax(pred_prob, axis=1)
60
+ score = calculate_csi(y_true, y_pred_binary)
61
+ return 'CSI', score, True
62
+
63
+ def add_derived_features(df: pd.DataFrame) -> pd.DataFrame:
64
+ """
65
+ μ œκ±°ν–ˆλ˜ νŒŒμƒ λ³€μˆ˜λ“€μ„ 볡ꡬ
66
+
67
+ Args:
68
+ df: λ°μ΄ν„°ν”„λ ˆμž„
69
+
70
+ Returns:
71
+ νŒŒμƒ λ³€μˆ˜κ°€ μΆ”κ°€λœ λ°μ΄ν„°ν”„λ ˆμž„
72
+ """
73
+ df = df.copy()
74
+ df['hour_sin'] = np.sin(2 * np.pi * df['hour'] / 24)
75
+ df['hour_cos'] = np.cos(2 * np.pi * df['hour'] / 24)
76
+ df['month_sin'] = np.sin(2 * np.pi * df['month'] / 12)
77
+ df['month_cos'] = np.cos(2 * np.pi * df['month'] / 12)
78
+ df['ground_temp - temp_C'] = df['groundtemp'] - df['temp_C']
79
+ return df
80
+
81
+ def preprocessing(df):
82
+ """데이터 μ „μ²˜λ¦¬ ν•¨μˆ˜.
83
+
84
+ Args:
85
+ df: 원본 λ°μ΄ν„°ν”„λ ˆμž„
86
+
87
+ Returns:
88
+ μ „μ²˜λ¦¬λœ λ°μ΄ν„°ν”„λ ˆμž„
89
+ """
90
+ df = df[df.columns].copy()
91
+ df['year'] = df['year'].astype('int')
92
+ df['month'] = df['month'].astype('int')
93
+ df['hour'] = df['hour'].astype('int')
94
+ df = add_derived_features(df).copy()
95
+ df['multi_class'] = df['multi_class'].astype('int')
96
+ df.loc[df['wind_dir']=='μ •μ˜¨', 'wind_dir'] = "0"
97
+ df['wind_dir'] = df['wind_dir'].astype('int')
98
+ df = df[['temp_C', 'precip_mm', 'wind_speed', 'wind_dir', 'hm',
99
+ 'vap_pressure', 'dewpoint_C', 'loc_pressure', 'sea_pressure',
100
+ 'solarRad', 'snow_cm', 'cloudcover', 'lm_cloudcover', 'low_cloudbase',
101
+ 'groundtemp', 'O3', 'NO2', 'PM10', 'PM25', 'year',
102
+ 'month', 'hour', 'ground_temp - temp_C', 'hour_sin', 'hour_cos',
103
+ 'month_sin', 'month_cos','multi_class']].copy()
104
+ return df
105
+
106
+
107
+ def split_data(df_sampled, df_original, train_years, val_year):
108
+ """데이터λ₯Ό ν•™μŠ΅μš©κ³Ό κ²€μ¦μš©μœΌλ‘œ λΆ„ν• ν•©λ‹ˆλ‹€.
109
+
110
+ Args:
111
+ df_sampled: μƒ˜ν”Œλ§λœ λ°μ΄ν„°ν”„λ ˆμž„
112
+ df_original: 원본 λ°μ΄ν„°ν”„λ ˆμž„
113
+ train_years: ν•™μŠ΅μ— μ‚¬μš©ν•  연도 리슀트
114
+ val_year: 검증에 μ‚¬μš©ν•  연도
115
+
116
+ Returns:
117
+ (X_train, X_val, y_train, y_val) νŠœν”Œ
118
+ """
119
+ # ν•™μŠ΅ 데이터: μƒ˜ν”Œλ§λœ λ°μ΄ν„°μ—μ„œ train_years에 ν•΄λ‹Ήν•˜λŠ” 데이터
120
+ train_mask = df_sampled['year'].isin(train_years)
121
+ X_train = df_sampled.loc[train_mask, df_sampled.columns != 'multi_class'].copy()
122
+ y_train = df_sampled.loc[train_mask, 'multi_class']
123
+
124
+ # 검증 데이터: 원본 λ°μ΄ν„°μ—μ„œ val_year에 ν•΄λ‹Ήν•˜λŠ” 데이터
125
+ val_mask = df_original['year'] == val_year
126
+ X_val = df_original.loc[val_mask, df_original.columns != 'multi_class'].copy()
127
+ y_val = df_original.loc[val_mask, 'multi_class']
128
+
129
+ # 'year' 컬럼 제거
130
+ X_train = X_train.drop(columns=['year'])
131
+ X_val = X_val.drop(columns=['year'])
132
+
133
+ return X_train, X_val, y_train, y_val
134
+
135
+
136
+ def create_lgb_model(search_space=None, best_params=None):
137
+ """LightGBM λͺ¨λΈμ„ μƒμ„±ν•©λ‹ˆλ‹€.
138
+
139
+ Args:
140
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 (objective_funcμ—μ„œ μ‚¬μš©)
141
+ best_params: μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„° (μ΅œμ’… λͺ¨λΈ ν•™μŠ΅μ—μ„œ μ‚¬μš©)
142
+
143
+ Returns:
144
+ LGBMClassifier μΈμŠ€ν„΄μŠ€
145
+ """
146
+ base_params = {
147
+ 'n_estimators': N_ESTIMATORS,
148
+ 'device': DEVICE,
149
+ 'objective': OBJECTIVE,
150
+ 'random_state': RANDOM_STATE,
151
+ 'early_stopping_rounds': EARLY_STOPPING_ROUNDS,
152
+ 'verbose': -1,
153
+ }
154
+
155
+ if search_space is not None:
156
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” 쀑
157
+ params = {
158
+ **base_params,
159
+ 'learning_rate': search_space['learning_rate'],
160
+ 'max_depth': int(search_space['max_depth']),
161
+ 'num_leaves': int(search_space['num_leaves']),
162
+ 'min_child_weight': int(search_space['min_child_weight']),
163
+ 'subsample': search_space['subsample'],
164
+ 'colsample_bytree': search_space['colsample_bytree'],
165
+ 'reg_alpha': search_space['reg_alpha'],
166
+ 'reg_lambda': search_space['reg_lambda'],
167
+ }
168
+ elif best_params is not None:
169
+ # μ΅œμ ν™”λœ νŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ 생성
170
+ params = {
171
+ **base_params,
172
+ 'learning_rate': best_params['learning_rate'],
173
+ 'max_depth': int(best_params['max_depth']),
174
+ 'num_leaves': int(best_params['num_leaves']),
175
+ 'min_child_weight': int(best_params['min_child_weight']),
176
+ 'subsample': best_params['subsample'],
177
+ 'colsample_bytree': best_params['colsample_bytree'],
178
+ 'reg_alpha': best_params['reg_alpha'],
179
+ 'reg_lambda': best_params['reg_lambda'],
180
+ }
181
+ else:
182
+ params = base_params
183
+
184
+ return LGBMClassifier(**params)
185
+
186
+ # 데이터 λ‘œλ”©
187
+ print("데이터 λ‘œλ”© 쀑...")
188
+ # 파일 μœ„μΉ˜ 기반으둜 데이터 디렉토리 경둜 μ„€μ •
189
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
190
+ data_base_dir = os.path.abspath(os.path.join(current_file_dir, '../../../data'))
191
+ df_gwangju = pd.read_csv(os.path.join(data_base_dir, "data_for_modeling/gwangju_train.csv"))
192
+ df_ctgan_gwangju_1 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_1_gwangju.csv"))
193
+ df_ctgan_gwangju_2 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_2_gwangju.csv"))
194
+ df_ctgan_gwangju_3 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_3_gwangju.csv"))
195
+
196
+ # 데이터 μ „μ²˜λ¦¬
197
+ print("데이터 μ „μ²˜λ¦¬ 쀑...")
198
+ df_ctgan_gwangju_1 = preprocessing(df_ctgan_gwangju_1)
199
+ df_ctgan_gwangju_2 = preprocessing(df_ctgan_gwangju_2)
200
+ df_ctgan_gwangju_3 = preprocessing(df_ctgan_gwangju_3)
201
+ df_gwangju = preprocessing(df_gwangju)
202
+
203
+ # CTGAN 데이터 리슀트 (fold μˆœμ„œμ™€ 일치)
204
+ df_ctgan_list = [df_ctgan_gwangju_1, df_ctgan_gwangju_2, df_ctgan_gwangju_3]
205
+
206
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 μ •μ˜
207
+ lgb_search_space = {
208
+ 'learning_rate': hp.loguniform('learning_rate', np.log(0.01), np.log(0.2)),
209
+ 'max_depth': hp.quniform('max_depth', 3, 15, 1),
210
+ 'num_leaves': hp.quniform('num_leaves', 20, 150, 1), # 2^max_depth λ³΄λ‹€λŠ” μž‘κ²Œ
211
+ 'min_child_weight': hp.quniform('min_child_weight', 1, 20, 1),
212
+ 'subsample': hp.uniform('subsample', 0.6, 1.0),
213
+ 'colsample_bytree': hp.uniform('colsample_bytree', 0.6, 1.0),
214
+ 'reg_alpha': hp.uniform('reg_alpha', 0.0, 1.0),
215
+ 'reg_lambda': hp.uniform('reg_lambda', 0.0, 1.0)
216
+ }
217
+
218
+
219
+ def objective_func(search_space):
220
+ """ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”λ₯Ό μœ„ν•œ λͺ©μ  ν•¨μˆ˜.
221
+
222
+ Args:
223
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간
224
+
225
+ Returns:
226
+ 평균 CSI 점수의 μŒμˆ˜κ°’ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰ν•˜λ―€λ‘œ)
227
+ """
228
+ lgb_model = create_lgb_model(search_space=search_space)
229
+ csi_scores = []
230
+
231
+ # 각 fold에 λŒ€ν•΄ ꡐ차 검증 μˆ˜ν–‰
232
+ for df_ctgan, (train_years, val_year) in zip(df_ctgan_list, FOLD_CONFIGS):
233
+ X_train, X_val, y_train, y_val = split_data(
234
+ df_ctgan, df_gwangju, train_years, val_year
235
+ )
236
+
237
+ lgb_model.fit(
238
+ X_train, y_train,
239
+ eval_set=[(X_val, y_val)],
240
+ eval_metric=csi_metric
241
+ )
242
+
243
+ csi = calculate_csi(y_val, lgb_model.predict(X_val))
244
+ csi_scores.append(csi)
245
+
246
+ # 평균 CSI의 μŒμˆ˜κ°’ λ°˜ν™˜ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰)
247
+ return -1 * round(np.mean(csi_scores), 4)
248
+
249
+
250
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”
251
+ print("ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...")
252
+ trials = Trials()
253
+ lgb_best = fmin(
254
+ fn=objective_func,
255
+ space=lgb_search_space,
256
+ algo=tpe.suggest,
257
+ max_evals=MAX_EVALS,
258
+ trials=trials
259
+ )
260
+
261
+ # μ΅œμ ν™” κ²°κ³Ό 뢄석 및 좜λ ₯
262
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
263
+
264
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
265
+ best_loss = trials.best_trial['result']['loss']
266
+ best_csi = -best_loss
267
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
268
+
269
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
270
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
271
+ csi_scores = [-loss for loss in losses]
272
+
273
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
274
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
275
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
276
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
277
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
278
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
279
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
280
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
281
+
282
+ # Trials 객체 μ €μž₯
283
+ import os
284
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima ���렉토리
285
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
286
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_ctgan10000_gwangju_trials.pkl")
287
+ joblib.dump(trials, trials_path)
288
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
289
+
290
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
291
+ print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
292
+ models = []
293
+
294
+ for fold_idx, (df_ctgan, (train_years, val_year)) in enumerate(
295
+ zip(df_ctgan_list, FOLD_CONFIGS), start=1
296
+ ):
297
+ print(f"Fold {fold_idx} ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: {train_years}, 검증 연도: {val_year})")
298
+
299
+ X_train, X_val, y_train, y_val = split_data(
300
+ df_ctgan, df_gwangju, train_years, val_year
301
+ )
302
+
303
+ lgb_model = create_lgb_model(best_params=lgb_best)
304
+ lgb_model.fit(X_train, y_train, eval_set=[(X_val, y_val)])
305
+
306
+ # 검증 μ„±λŠ₯ 좜λ ₯
307
+ val_csi = calculate_csi(y_val, lgb_model.predict(X_val))
308
+ print(f"Fold {fold_idx} 검증 CSI: {val_csi:.4f}")
309
+
310
+ models.append(lgb_model)
311
+
312
+ # λͺ¨λΈ μ €μž₯
313
+ print("λͺ¨λΈ μ €μž₯ 쀑...")
314
+ model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_ctgan10000_gwangju.pkl")
315
+ joblib.dump(models, model_save_path)
316
+ print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
317
+
Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_incheon.py ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import pandas as pd
2
+ import numpy as np
3
+ import joblib
4
+ import os
5
+ from warnings import filterwarnings
6
+ from sklearn.metrics import confusion_matrix
7
+ from lightgbm import LGBMClassifier
8
+ from hyperopt import fmin, tpe, Trials, hp
9
+
10
+ filterwarnings('ignore')
11
+
12
+ # μƒμˆ˜ μ •μ˜
13
+ RANDOM_STATE = 42
14
+ N_ESTIMATORS = 4000
15
+ EARLY_STOPPING_ROUNDS = 400
16
+ MAX_EVALS = 100
17
+ DEVICE = 'gpu'
18
+ OBJECTIVE = 'multiclassova'
19
+
20
+ # Fold μ„€μ •: (train_years, val_year)
21
+ FOLD_CONFIGS = [
22
+ ([2018, 2019], 2020), # Fold 1
23
+ ([2018, 2020], 2019), # Fold 2
24
+ ([2019, 2020], 2018), # Fold 3
25
+ ]
26
+
27
+ def calculate_csi(y_true, y_pred):
28
+ """CSI(Critical Success Index) 점수λ₯Ό κ³„μ‚°ν•©λ‹ˆλ‹€.
29
+
30
+ Args:
31
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
32
+ y_pred: 예츑 λ ˆμ΄λΈ”
33
+
34
+ Returns:
35
+ CSI 점수 (0~1 μ‚¬μ΄μ˜ κ°’)
36
+ """
37
+ cm = confusion_matrix(y_true, y_pred)
38
+
39
+ # ν˜Όλ™ ν–‰λ ¬μ—μ„œ H(Hit), F(False alarm), M(Miss) μΆ”μΆœ
40
+ H = cm[0, 0] + cm[1, 1]
41
+ F = cm[1, 0] + cm[2, 0] + cm[0, 1] + cm[2, 1]
42
+ M = cm[0, 2] + cm[1, 2]
43
+
44
+ # CSI 계산
45
+ csi = H / (H + F + M + 1e-10)
46
+ return csi
47
+
48
+
49
+ def csi_metric(y_true, pred_prob):
50
+ """LightGBM용 CSI λ©”νŠΈλ¦­ ν•¨μˆ˜.
51
+
52
+ Args:
53
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
54
+ pred_prob: 예츑 ν™•λ₯  (shape: [n_samples, n_classes])
55
+
56
+ Returns:
57
+ ('CSI', score, higher_better) νŠœν”Œ
58
+ """
59
+ y_pred_binary = np.argmax(pred_prob, axis=1)
60
+ score = calculate_csi(y_true, y_pred_binary)
61
+ return 'CSI', score, True
62
+
63
+ def add_derived_features(df: pd.DataFrame) -> pd.DataFrame:
64
+ """
65
+ μ œκ±°ν–ˆλ˜ νŒŒμƒ λ³€μˆ˜λ“€μ„ 볡ꡬ
66
+
67
+ Args:
68
+ df: λ°μ΄ν„°ν”„λ ˆμž„
69
+
70
+ Returns:
71
+ νŒŒμƒ λ³€μˆ˜κ°€ μΆ”κ°€λœ λ°μ΄ν„°ν”„λ ˆμž„
72
+ """
73
+ df = df.copy()
74
+ df['hour_sin'] = np.sin(2 * np.pi * df['hour'] / 24)
75
+ df['hour_cos'] = np.cos(2 * np.pi * df['hour'] / 24)
76
+ df['month_sin'] = np.sin(2 * np.pi * df['month'] / 12)
77
+ df['month_cos'] = np.cos(2 * np.pi * df['month'] / 12)
78
+ df['ground_temp - temp_C'] = df['groundtemp'] - df['temp_C']
79
+ return df
80
+
81
+ def preprocessing(df):
82
+ """데이터 μ „μ²˜λ¦¬ ν•¨μˆ˜.
83
+
84
+ Args:
85
+ df: 원본 λ°μ΄ν„°ν”„λ ˆμž„
86
+
87
+ Returns:
88
+ μ „μ²˜λ¦¬λœ λ°μ΄ν„°ν”„λ ˆμž„
89
+ """
90
+ df = df[df.columns].copy()
91
+ df['year'] = df['year'].astype('int')
92
+ df['month'] = df['month'].astype('int')
93
+ df['hour'] = df['hour'].astype('int')
94
+ df = add_derived_features(df).copy()
95
+ df['multi_class'] = df['multi_class'].astype('int')
96
+ df.loc[df['wind_dir']=='μ •μ˜¨', 'wind_dir'] = "0"
97
+ df['wind_dir'] = df['wind_dir'].astype('int')
98
+ df = df[['temp_C', 'precip_mm', 'wind_speed', 'wind_dir', 'hm',
99
+ 'vap_pressure', 'dewpoint_C', 'loc_pressure', 'sea_pressure',
100
+ 'solarRad', 'snow_cm', 'cloudcover', 'lm_cloudcover', 'low_cloudbase',
101
+ 'groundtemp', 'O3', 'NO2', 'PM10', 'PM25', 'year',
102
+ 'month', 'hour', 'ground_temp - temp_C', 'hour_sin', 'hour_cos',
103
+ 'month_sin', 'month_cos','multi_class']].copy()
104
+ return df
105
+
106
+
107
+ def split_data(df_sampled, df_original, train_years, val_year):
108
+ """데이터λ₯Ό ν•™μŠ΅μš©κ³Ό κ²€μ¦μš©μœΌλ‘œ λΆ„ν• ν•©λ‹ˆλ‹€.
109
+
110
+ Args:
111
+ df_sampled: μƒ˜ν”Œλ§λœ λ°μ΄ν„°ν”„λ ˆμž„
112
+ df_original: 원본 λ°μ΄ν„°ν”„λ ˆμž„
113
+ train_years: ν•™μŠ΅μ— μ‚¬μš©ν•  연도 리슀트
114
+ val_year: 검증에 μ‚¬μš©ν•  연도
115
+
116
+ Returns:
117
+ (X_train, X_val, y_train, y_val) νŠœν”Œ
118
+ """
119
+ # ν•™μŠ΅ 데이터: μƒ˜ν”Œλ§λœ λ°μ΄ν„°μ—μ„œ train_years에 ν•΄λ‹Ήν•˜λŠ” 데이터
120
+ train_mask = df_sampled['year'].isin(train_years)
121
+ X_train = df_sampled.loc[train_mask, df_sampled.columns != 'multi_class'].copy()
122
+ y_train = df_sampled.loc[train_mask, 'multi_class']
123
+
124
+ # 검증 데이터: 원본 λ°μ΄ν„°μ—μ„œ val_year에 ν•΄λ‹Ήν•˜λŠ” 데이터
125
+ val_mask = df_original['year'] == val_year
126
+ X_val = df_original.loc[val_mask, df_original.columns != 'multi_class'].copy()
127
+ y_val = df_original.loc[val_mask, 'multi_class']
128
+
129
+ # 'year' 컬럼 제거
130
+ X_train = X_train.drop(columns=['year'])
131
+ X_val = X_val.drop(columns=['year'])
132
+
133
+ return X_train, X_val, y_train, y_val
134
+
135
+
136
+ def create_lgb_model(search_space=None, best_params=None):
137
+ """LightGBM λͺ¨λΈμ„ μƒμ„±ν•©λ‹ˆλ‹€.
138
+
139
+ Args:
140
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 (objective_funcμ—μ„œ μ‚¬μš©)
141
+ best_params: μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„° (μ΅œμ’… λͺ¨λΈ ν•™μŠ΅μ—μ„œ μ‚¬μš©)
142
+
143
+ Returns:
144
+ LGBMClassifier μΈμŠ€ν„΄μŠ€
145
+ """
146
+ base_params = {
147
+ 'n_estimators': N_ESTIMATORS,
148
+ 'device': DEVICE,
149
+ 'objective': OBJECTIVE,
150
+ 'random_state': RANDOM_STATE,
151
+ 'early_stopping_rounds': EARLY_STOPPING_ROUNDS,
152
+ 'verbose': -1,
153
+ }
154
+
155
+ if search_space is not None:
156
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” 쀑
157
+ params = {
158
+ **base_params,
159
+ 'learning_rate': search_space['learning_rate'],
160
+ 'max_depth': int(search_space['max_depth']),
161
+ 'num_leaves': int(search_space['num_leaves']),
162
+ 'min_child_weight': int(search_space['min_child_weight']),
163
+ 'subsample': search_space['subsample'],
164
+ 'colsample_bytree': search_space['colsample_bytree'],
165
+ 'reg_alpha': search_space['reg_alpha'],
166
+ 'reg_lambda': search_space['reg_lambda'],
167
+ }
168
+ elif best_params is not None:
169
+ # μ΅œμ ν™”λœ νŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ 생성
170
+ params = {
171
+ **base_params,
172
+ 'learning_rate': best_params['learning_rate'],
173
+ 'max_depth': int(best_params['max_depth']),
174
+ 'num_leaves': int(best_params['num_leaves']),
175
+ 'min_child_weight': int(best_params['min_child_weight']),
176
+ 'subsample': best_params['subsample'],
177
+ 'colsample_bytree': best_params['colsample_bytree'],
178
+ 'reg_alpha': best_params['reg_alpha'],
179
+ 'reg_lambda': best_params['reg_lambda'],
180
+ }
181
+ else:
182
+ params = base_params
183
+
184
+ return LGBMClassifier(**params)
185
+
186
+ # 데이터 λ‘œλ”©
187
+ print("데이터 λ‘œλ”© 쀑...")
188
+ # 파일 μœ„μΉ˜ 기반으둜 데이터 디렉토리 경둜 μ„€μ •
189
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
190
+ data_base_dir = os.path.abspath(os.path.join(current_file_dir, '../../../data'))
191
+ df_incheon = pd.read_csv(os.path.join(data_base_dir, "data_for_modeling/incheon_train.csv"))
192
+ df_ctgan_incheon_1 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_1_incheon.csv"))
193
+ df_ctgan_incheon_2 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_2_incheon.csv"))
194
+ df_ctgan_incheon_3 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_3_incheon.csv"))
195
+
196
+ # 데이터 μ „μ²˜λ¦¬
197
+ print("데이터 μ „μ²˜λ¦¬ 쀑...")
198
+ df_ctgan_incheon_1 = preprocessing(df_ctgan_incheon_1)
199
+ df_ctgan_incheon_2 = preprocessing(df_ctgan_incheon_2)
200
+ df_ctgan_incheon_3 = preprocessing(df_ctgan_incheon_3)
201
+ df_incheon = preprocessing(df_incheon)
202
+
203
+ # CTGAN 데이터 리슀트 (fold μˆœμ„œμ™€ 일치)
204
+ df_ctgan_list = [df_ctgan_incheon_1, df_ctgan_incheon_2, df_ctgan_incheon_3]
205
+
206
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 μ •μ˜
207
+ lgb_search_space = {
208
+ 'learning_rate': hp.loguniform('learning_rate', np.log(0.01), np.log(0.2)),
209
+ 'max_depth': hp.quniform('max_depth', 3, 15, 1),
210
+ 'num_leaves': hp.quniform('num_leaves', 20, 150, 1), # 2^max_depth λ³΄λ‹€λŠ” μž‘κ²Œ
211
+ 'min_child_weight': hp.quniform('min_child_weight', 1, 20, 1),
212
+ 'subsample': hp.uniform('subsample', 0.6, 1.0),
213
+ 'colsample_bytree': hp.uniform('colsample_bytree', 0.6, 1.0),
214
+ 'reg_alpha': hp.uniform('reg_alpha', 0.0, 1.0),
215
+ 'reg_lambda': hp.uniform('reg_lambda', 0.0, 1.0)
216
+ }
217
+
218
+
219
+ def objective_func(search_space):
220
+ """ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”λ₯Ό μœ„ν•œ λͺ©μ  ν•¨μˆ˜.
221
+
222
+ Args:
223
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간
224
+
225
+ Returns:
226
+ 평균 CSI 점수의 μŒμˆ˜κ°’ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰ν•˜λ―€λ‘œ)
227
+ """
228
+ lgb_model = create_lgb_model(search_space=search_space)
229
+ csi_scores = []
230
+
231
+ # 각 fold에 λŒ€ν•΄ ꡐ차 검증 μˆ˜ν–‰
232
+ for df_ctgan, (train_years, val_year) in zip(df_ctgan_list, FOLD_CONFIGS):
233
+ X_train, X_val, y_train, y_val = split_data(
234
+ df_ctgan, df_incheon, train_years, val_year
235
+ )
236
+
237
+ lgb_model.fit(
238
+ X_train, y_train,
239
+ eval_set=[(X_val, y_val)],
240
+ eval_metric=csi_metric
241
+ )
242
+
243
+ csi = calculate_csi(y_val, lgb_model.predict(X_val))
244
+ csi_scores.append(csi)
245
+
246
+ # 평균 CSI의 μŒμˆ˜κ°’ λ°˜ν™˜ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰)
247
+ return -1 * round(np.mean(csi_scores), 4)
248
+
249
+
250
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”
251
+ print("ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...")
252
+ trials = Trials()
253
+ lgb_best = fmin(
254
+ fn=objective_func,
255
+ space=lgb_search_space,
256
+ algo=tpe.suggest,
257
+ max_evals=MAX_EVALS,
258
+ trials=trials
259
+ )
260
+
261
+ # μ΅œμ ν™” κ²°κ³Ό 뢄석 및 좜λ ₯
262
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
263
+
264
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
265
+ best_loss = trials.best_trial['result']['loss']
266
+ best_csi = -best_loss
267
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
268
+
269
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
270
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
271
+ csi_scores = [-loss for loss in losses]
272
+
273
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
274
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
275
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
276
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
277
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
278
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
279
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
280
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
281
+
282
+ # Trials 객체 μ €μž₯
283
+ import os
284
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima ���렉토리
285
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
286
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_ctgan10000_incheon_trials.pkl")
287
+ joblib.dump(trials, trials_path)
288
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
289
+
290
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
291
+ print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
292
+ models = []
293
+
294
+ for fold_idx, (df_ctgan, (train_years, val_year)) in enumerate(
295
+ zip(df_ctgan_list, FOLD_CONFIGS), start=1
296
+ ):
297
+ print(f"Fold {fold_idx} ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: {train_years}, 검증 연도: {val_year})")
298
+
299
+ X_train, X_val, y_train, y_val = split_data(
300
+ df_ctgan, df_incheon, train_years, val_year
301
+ )
302
+
303
+ lgb_model = create_lgb_model(best_params=lgb_best)
304
+ lgb_model.fit(X_train, y_train, eval_set=[(X_val, y_val)])
305
+
306
+ # 검증 μ„±λŠ₯ 좜λ ₯
307
+ val_csi = calculate_csi(y_val, lgb_model.predict(X_val))
308
+ print(f"Fold {fold_idx} 검증 CSI: {val_csi:.4f}")
309
+
310
+ models.append(lgb_model)
311
+
312
+ # λͺ¨λΈ μ €μž₯
313
+ print("λͺ¨λΈ μ €μž₯ 쀑...")
314
+ model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_ctgan10000_incheon.pkl")
315
+ joblib.dump(models, model_save_path)
316
+ print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
317
+
Analysis_code/5.optima/lgb_ctgan10000/LGB_ctgan10000_seoul.py ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import pandas as pd
2
+ import numpy as np
3
+ import joblib
4
+ import os
5
+ from warnings import filterwarnings
6
+ from sklearn.metrics import confusion_matrix
7
+ from lightgbm import LGBMClassifier
8
+ from hyperopt import fmin, tpe, Trials, hp
9
+
10
+ filterwarnings('ignore')
11
+
12
+ # μƒμˆ˜ μ •μ˜
13
+ RANDOM_STATE = 42
14
+ N_ESTIMATORS = 4000
15
+ EARLY_STOPPING_ROUNDS = 400
16
+ MAX_EVALS = 100
17
+ DEVICE = 'gpu'
18
+ OBJECTIVE = 'multiclassova'
19
+
20
+ # Fold μ„€μ •: (train_years, val_year)
21
+ FOLD_CONFIGS = [
22
+ ([2018, 2019], 2020), # Fold 1
23
+ ([2018, 2020], 2019), # Fold 2
24
+ ([2019, 2020], 2018), # Fold 3
25
+ ]
26
+
27
+ def calculate_csi(y_true, y_pred):
28
+ """CSI(Critical Success Index) 점수λ₯Ό κ³„μ‚°ν•©λ‹ˆλ‹€.
29
+
30
+ Args:
31
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
32
+ y_pred: 예츑 λ ˆμ΄λΈ”
33
+
34
+ Returns:
35
+ CSI 점수 (0~1 μ‚¬μ΄μ˜ κ°’)
36
+ """
37
+ cm = confusion_matrix(y_true, y_pred)
38
+
39
+ # ν˜Όλ™ ν–‰λ ¬μ—μ„œ H(Hit), F(False alarm), M(Miss) μΆ”μΆœ
40
+ H = cm[0, 0] + cm[1, 1]
41
+ F = cm[1, 0] + cm[2, 0] + cm[0, 1] + cm[2, 1]
42
+ M = cm[0, 2] + cm[1, 2]
43
+
44
+ # CSI 계산
45
+ csi = H / (H + F + M + 1e-10)
46
+ return csi
47
+
48
+
49
+ def csi_metric(y_true, pred_prob):
50
+ """LightGBM용 CSI λ©”νŠΈλ¦­ ν•¨μˆ˜.
51
+
52
+ Args:
53
+ y_true: μ‹€μ œ λ ˆμ΄λΈ”
54
+ pred_prob: 예츑 ν™•λ₯  (shape: [n_samples, n_classes])
55
+
56
+ Returns:
57
+ ('CSI', score, higher_better) νŠœν”Œ
58
+ """
59
+ y_pred_binary = np.argmax(pred_prob, axis=1)
60
+ score = calculate_csi(y_true, y_pred_binary)
61
+ return 'CSI', score, True
62
+
63
+ def add_derived_features(df: pd.DataFrame) -> pd.DataFrame:
64
+ """
65
+ μ œκ±°ν–ˆλ˜ νŒŒμƒ λ³€μˆ˜λ“€μ„ 볡ꡬ
66
+
67
+ Args:
68
+ df: λ°μ΄ν„°ν”„λ ˆμž„
69
+
70
+ Returns:
71
+ νŒŒμƒ λ³€μˆ˜κ°€ μΆ”κ°€λœ λ°μ΄ν„°ν”„λ ˆμž„
72
+ """
73
+ df = df.copy()
74
+ df['hour_sin'] = np.sin(2 * np.pi * df['hour'] / 24)
75
+ df['hour_cos'] = np.cos(2 * np.pi * df['hour'] / 24)
76
+ df['month_sin'] = np.sin(2 * np.pi * df['month'] / 12)
77
+ df['month_cos'] = np.cos(2 * np.pi * df['month'] / 12)
78
+ df['ground_temp - temp_C'] = df['groundtemp'] - df['temp_C']
79
+ return df
80
+
81
+ def preprocessing(df):
82
+ """데이터 μ „μ²˜λ¦¬ ν•¨μˆ˜.
83
+
84
+ Args:
85
+ df: 원본 λ°μ΄ν„°ν”„λ ˆμž„
86
+
87
+ Returns:
88
+ μ „μ²˜λ¦¬λœ λ°μ΄ν„°ν”„λ ˆμž„
89
+ """
90
+ df = df[df.columns].copy()
91
+ df['year'] = df['year'].astype('int')
92
+ df['month'] = df['month'].astype('int')
93
+ df['hour'] = df['hour'].astype('int')
94
+ df = add_derived_features(df).copy()
95
+ df['multi_class'] = df['multi_class'].astype('int')
96
+ df.loc[df['wind_dir']=='μ •μ˜¨', 'wind_dir'] = "0"
97
+ df['wind_dir'] = df['wind_dir'].astype('int')
98
+ df = df[['temp_C', 'precip_mm', 'wind_speed', 'wind_dir', 'hm',
99
+ 'vap_pressure', 'dewpoint_C', 'loc_pressure', 'sea_pressure',
100
+ 'solarRad', 'snow_cm', 'cloudcover', 'lm_cloudcover', 'low_cloudbase',
101
+ 'groundtemp', 'O3', 'NO2', 'PM10', 'PM25', 'year',
102
+ 'month', 'hour', 'ground_temp - temp_C', 'hour_sin', 'hour_cos',
103
+ 'month_sin', 'month_cos','multi_class']].copy()
104
+ return df
105
+
106
+
107
+ def split_data(df_sampled, df_original, train_years, val_year):
108
+ """데이터λ₯Ό ν•™μŠ΅μš©κ³Ό κ²€μ¦μš©μœΌλ‘œ λΆ„ν• ν•©λ‹ˆλ‹€.
109
+
110
+ Args:
111
+ df_sampled: μƒ˜ν”Œλ§λœ λ°μ΄ν„°ν”„λ ˆμž„
112
+ df_original: 원본 λ°μ΄ν„°ν”„λ ˆμž„
113
+ train_years: ν•™μŠ΅μ— μ‚¬μš©ν•  연도 리슀트
114
+ val_year: 검증에 μ‚¬μš©ν•  연도
115
+
116
+ Returns:
117
+ (X_train, X_val, y_train, y_val) νŠœν”Œ
118
+ """
119
+ # ν•™μŠ΅ 데이터: μƒ˜ν”Œλ§λœ λ°μ΄ν„°μ—μ„œ train_years에 ν•΄λ‹Ήν•˜λŠ” 데이터
120
+ train_mask = df_sampled['year'].isin(train_years)
121
+ X_train = df_sampled.loc[train_mask, df_sampled.columns != 'multi_class'].copy()
122
+ y_train = df_sampled.loc[train_mask, 'multi_class']
123
+
124
+ # 검증 데이터: 원본 λ°μ΄ν„°μ—μ„œ val_year에 ν•΄λ‹Ήν•˜λŠ” 데이터
125
+ val_mask = df_original['year'] == val_year
126
+ X_val = df_original.loc[val_mask, df_original.columns != 'multi_class'].copy()
127
+ y_val = df_original.loc[val_mask, 'multi_class']
128
+
129
+ # 'year' 컬럼 제거
130
+ X_train = X_train.drop(columns=['year'])
131
+ X_val = X_val.drop(columns=['year'])
132
+
133
+ return X_train, X_val, y_train, y_val
134
+
135
+
136
+ def create_lgb_model(search_space=None, best_params=None):
137
+ """LightGBM λͺ¨λΈμ„ μƒμ„±ν•©λ‹ˆλ‹€.
138
+
139
+ Args:
140
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 (objective_funcμ—μ„œ μ‚¬μš©)
141
+ best_params: μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„° (μ΅œμ’… λͺ¨λΈ ν•™μŠ΅μ—μ„œ μ‚¬μš©)
142
+
143
+ Returns:
144
+ LGBMClassifier μΈμŠ€ν„΄μŠ€
145
+ """
146
+ base_params = {
147
+ 'n_estimators': N_ESTIMATORS,
148
+ 'device': DEVICE,
149
+ 'objective': OBJECTIVE,
150
+ 'random_state': RANDOM_STATE,
151
+ 'early_stopping_rounds': EARLY_STOPPING_ROUNDS,
152
+ 'verbose': -1,
153
+ }
154
+
155
+ if search_space is not None:
156
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” 쀑
157
+ params = {
158
+ **base_params,
159
+ 'learning_rate': search_space['learning_rate'],
160
+ 'max_depth': int(search_space['max_depth']),
161
+ 'num_leaves': int(search_space['num_leaves']),
162
+ 'min_child_weight': int(search_space['min_child_weight']),
163
+ 'subsample': search_space['subsample'],
164
+ 'colsample_bytree': search_space['colsample_bytree'],
165
+ 'reg_alpha': search_space['reg_alpha'],
166
+ 'reg_lambda': search_space['reg_lambda'],
167
+ }
168
+ elif best_params is not None:
169
+ # μ΅œμ ν™”λœ νŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ 생성
170
+ params = {
171
+ **base_params,
172
+ 'learning_rate': best_params['learning_rate'],
173
+ 'max_depth': int(best_params['max_depth']),
174
+ 'num_leaves': int(best_params['num_leaves']),
175
+ 'min_child_weight': int(best_params['min_child_weight']),
176
+ 'subsample': best_params['subsample'],
177
+ 'colsample_bytree': best_params['colsample_bytree'],
178
+ 'reg_alpha': best_params['reg_alpha'],
179
+ 'reg_lambda': best_params['reg_lambda'],
180
+ }
181
+ else:
182
+ params = base_params
183
+
184
+ return LGBMClassifier(**params)
185
+
186
+ # 데이터 λ‘œλ”©
187
+ print("데이터 λ‘œλ”© 쀑...")
188
+ # 파일 μœ„μΉ˜ 기반으둜 데이터 디렉토리 경둜 μ„€μ •
189
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
190
+ data_base_dir = os.path.abspath(os.path.join(current_file_dir, '../../../data'))
191
+ df_seoul = pd.read_csv(os.path.join(data_base_dir, "data_for_modeling/seoul_train.csv"))
192
+ df_ctgan_seoul_1 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_1_seoul.csv"))
193
+ df_ctgan_seoul_2 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_2_seoul.csv"))
194
+ df_ctgan_seoul_3 = pd.read_csv(os.path.join(data_base_dir, "data_oversampled/ctgan10000/ctgan10000_3_seoul.csv"))
195
+
196
+ # 데이터 μ „μ²˜λ¦¬
197
+ print("데이터 μ „μ²˜λ¦¬ 쀑...")
198
+ df_ctgan_seoul_1 = preprocessing(df_ctgan_seoul_1)
199
+ df_ctgan_seoul_2 = preprocessing(df_ctgan_seoul_2)
200
+ df_ctgan_seoul_3 = preprocessing(df_ctgan_seoul_3)
201
+ df_seoul = preprocessing(df_seoul)
202
+
203
+ # CTGAN 데이터 리슀트 (fold μˆœμ„œμ™€ 일치)
204
+ df_ctgan_list = [df_ctgan_seoul_1, df_ctgan_seoul_2, df_ctgan_seoul_3]
205
+
206
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간 μ •μ˜
207
+ lgb_search_space = {
208
+ 'learning_rate': hp.loguniform('learning_rate', np.log(0.01), np.log(0.2)),
209
+ 'max_depth': hp.quniform('max_depth', 3, 15, 1),
210
+ 'num_leaves': hp.quniform('num_leaves', 20, 150, 1), # 2^max_depth λ³΄λ‹€λŠ” μž‘κ²Œ
211
+ 'min_child_weight': hp.quniform('min_child_weight', 1, 20, 1),
212
+ 'subsample': hp.uniform('subsample', 0.6, 1.0),
213
+ 'colsample_bytree': hp.uniform('colsample_bytree', 0.6, 1.0),
214
+ 'reg_alpha': hp.uniform('reg_alpha', 0.0, 1.0),
215
+ 'reg_lambda': hp.uniform('reg_lambda', 0.0, 1.0)
216
+ }
217
+
218
+
219
+ def objective_func(search_space):
220
+ """ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”λ₯Ό μœ„ν•œ λͺ©μ  ν•¨μˆ˜.
221
+
222
+ Args:
223
+ search_space: ν•˜μ΄νΌνŒŒλΌλ―Έν„° 검색 곡간
224
+
225
+ Returns:
226
+ 평균 CSI 점수의 μŒμˆ˜κ°’ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰ν•˜λ―€λ‘œ)
227
+ """
228
+ lgb_model = create_lgb_model(search_space=search_space)
229
+ csi_scores = []
230
+
231
+ # 각 fold에 λŒ€ν•΄ ꡐ차 검증 μˆ˜ν–‰
232
+ for df_ctgan, (train_years, val_year) in zip(df_ctgan_list, FOLD_CONFIGS):
233
+ X_train, X_val, y_train, y_val = split_data(
234
+ df_ctgan, df_seoul, train_years, val_year
235
+ )
236
+
237
+ lgb_model.fit(
238
+ X_train, y_train,
239
+ eval_set=[(X_val, y_val)],
240
+ eval_metric=csi_metric
241
+ )
242
+
243
+ csi = calculate_csi(y_val, lgb_model.predict(X_val))
244
+ csi_scores.append(csi)
245
+
246
+ # 평균 CSI의 μŒμˆ˜κ°’ λ°˜ν™˜ (hyperoptλŠ” μ΅œμ†Œν™”λ₯Ό μˆ˜ν–‰)
247
+ return -1 * round(np.mean(csi_scores), 4)
248
+
249
+
250
+ # ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™”
251
+ print("ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...")
252
+ trials = Trials()
253
+ lgb_best = fmin(
254
+ fn=objective_func,
255
+ space=lgb_search_space,
256
+ algo=tpe.suggest,
257
+ max_evals=MAX_EVALS,
258
+ trials=trials
259
+ )
260
+
261
+ # μ΅œμ ν™” κ²°κ³Ό 뢄석 및 좜λ ₯
262
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
263
+
264
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
265
+ best_loss = trials.best_trial['result']['loss']
266
+ best_csi = -best_loss
267
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
268
+
269
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
270
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
271
+ csi_scores = [-loss for loss in losses]
272
+
273
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
274
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
275
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
276
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
277
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
278
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
279
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
280
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
281
+
282
+ # Trials 객체 μ €μž₯
283
+ import os
284
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
285
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
286
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_ctgan10000_seoul_trials.pkl")
287
+ joblib.dump(trials, trials_path)
288
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
289
+
290
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
291
+ print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
292
+ models = []
293
+
294
+ for fold_idx, (df_ctgan, (train_years, val_year)) in enumerate(
295
+ zip(df_ctgan_list, FOLD_CONFIGS), start=1
296
+ ):
297
+ print(f"Fold {fold_idx} ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: {train_years}, 검증 연도: {val_year})")
298
+
299
+ X_train, X_val, y_train, y_val = split_data(
300
+ df_ctgan, df_seoul, train_years, val_year
301
+ )
302
+
303
+ lgb_model = create_lgb_model(best_params=lgb_best)
304
+ lgb_model.fit(X_train, y_train, eval_set=[(X_val, y_val)])
305
+
306
+ # 검증 μ„±λŠ₯ 좜λ ₯
307
+ val_csi = calculate_csi(y_val, lgb_model.predict(X_val))
308
+ print(f"Fold {fold_idx} 검증 CSI: {val_csi:.4f}")
309
+
310
+ models.append(lgb_model)
311
+
312
+ # λͺ¨λΈ μ €μž₯
313
+ print("λͺ¨λΈ μ €μž₯ 쀑...")
314
+ model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_ctgan10000_seoul.pkl")
315
+ joblib.dump(models, model_save_path)
316
+ print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
317
+
Analysis_code/5.optima/lgb_pure/LGB_pure_daegu.py CHANGED
@@ -271,6 +271,7 @@ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
 
274
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
275
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_daegu_trials.pkl")
276
  joblib.dump(trials, trials_path)
 
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
274
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
275
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
276
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_daegu_trials.pkl")
277
  joblib.dump(trials, trials_path)
Analysis_code/5.optima/lgb_pure/LGB_pure_daejeon.py CHANGED
@@ -271,6 +271,7 @@ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
 
274
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
275
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_daejeon_trials.pkl")
276
  joblib.dump(trials, trials_path)
 
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
274
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
275
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
276
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_daejeon_trials.pkl")
277
  joblib.dump(trials, trials_path)
Analysis_code/5.optima/lgb_pure/LGB_pure_gwangju.py CHANGED
@@ -271,6 +271,7 @@ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
 
274
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
275
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_gwangju_trials.pkl")
276
  joblib.dump(trials, trials_path)
 
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
274
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
275
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
276
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_gwangju_trials.pkl")
277
  joblib.dump(trials, trials_path)
Analysis_code/5.optima/lgb_pure/LGB_pure_incheon.py CHANGED
@@ -271,6 +271,7 @@ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
 
274
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
275
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_incheon_trials.pkl")
276
  joblib.dump(trials, trials_path)
 
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
274
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
275
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
276
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_incheon_trials.pkl")
277
  joblib.dump(trials, trials_path)
Analysis_code/5.optima/lgb_pure/LGB_pure_seoul.py CHANGED
@@ -271,6 +271,7 @@ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
 
274
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
275
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_seoul_trials.pkl")
276
  joblib.dump(trials, trials_path)
 
271
  print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
272
 
273
  # Trials 객체 μ €μž₯
274
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
275
  os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
276
  trials_path = os.path.join(base_dir, "optimization_history/lgb_pure_seoul_trials.pkl")
277
  joblib.dump(trials, trials_path)
Analysis_code/5.optima/lgb_smote/LGB_smote_busan.py CHANGED
@@ -259,6 +259,31 @@ lgb_best = fmin(
259
  )
260
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
261
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
262
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
263
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
264
  models = []
@@ -283,6 +308,7 @@ for fold_idx, (df_smote, (train_years, val_year)) in enumerate(
283
 
284
  # λͺ¨λΈ μ €μž₯
285
  print("λͺ¨λΈ μ €μž₯ 쀑...")
 
286
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_busan.pkl")
287
  joblib.dump(models, model_save_path)
288
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
 
259
  )
260
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
261
 
262
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
263
+ best_loss = trials.best_trial['result']['loss']
264
+ best_csi = -best_loss
265
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
266
+
267
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
268
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
269
+ csi_scores = [-loss for loss in losses]
270
+
271
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
272
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
273
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
274
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
275
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
276
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
277
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
278
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
279
+
280
+ # Trials 객체 μ €μž₯
281
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
282
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
283
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smote_busan_trials.pkl")
284
+ joblib.dump(trials, trials_path)
285
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
286
+
287
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
288
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
289
  models = []
 
308
 
309
  # λͺ¨λΈ μ €μž₯
310
  print("λͺ¨λΈ μ €μž₯ 쀑...")
311
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
312
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_busan.pkl")
313
  joblib.dump(models, model_save_path)
314
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
Analysis_code/5.optima/lgb_smote/LGB_smote_daegu.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
@@ -284,6 +309,7 @@ for fold_idx, (df_smote, (train_years, val_year)) in enumerate(
284
 
285
  # λͺ¨λΈ μ €μž₯
286
  print("λͺ¨λΈ μ €μž₯ 쀑...")
 
287
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_daegu.pkl")
288
  joblib.dump(models, model_save_path)
289
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smote_daegu_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
 
309
 
310
  # λͺ¨λΈ μ €μž₯
311
  print("λͺ¨λΈ μ €μž₯ 쀑...")
312
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
313
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_daegu.pkl")
314
  joblib.dump(models, model_save_path)
315
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
Analysis_code/5.optima/lgb_smote/LGB_smote_daejeon.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
@@ -284,6 +309,7 @@ for fold_idx, (df_smote, (train_years, val_year)) in enumerate(
284
 
285
  # λͺ¨λΈ μ €μž₯
286
  print("λͺ¨λΈ μ €μž₯ 쀑...")
 
287
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_daejeon.pkl")
288
  joblib.dump(models, model_save_path)
289
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smote_daejeon_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
 
309
 
310
  # λͺ¨λΈ μ €μž₯
311
  print("λͺ¨λΈ μ €μž₯ 쀑...")
312
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
313
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_daejeon.pkl")
314
  joblib.dump(models, model_save_path)
315
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
Analysis_code/5.optima/lgb_smote/LGB_smote_gwangju.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
@@ -284,6 +309,7 @@ for fold_idx, (df_smote, (train_years, val_year)) in enumerate(
284
 
285
  # λͺ¨λΈ μ €μž₯
286
  print("λͺ¨λΈ μ €μž₯ 쀑...")
 
287
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_gwangju.pkl")
288
  joblib.dump(models, model_save_path)
289
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smote_gwangju_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
 
309
 
310
  # λͺ¨λΈ μ €μž₯
311
  print("λͺ¨λΈ μ €μž₯ 쀑...")
312
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
313
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_gwangju.pkl")
314
  joblib.dump(models, model_save_path)
315
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
Analysis_code/5.optima/lgb_smote/LGB_smote_incheon.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
@@ -284,6 +309,7 @@ for fold_idx, (df_smote, (train_years, val_year)) in enumerate(
284
 
285
  # λͺ¨λΈ μ €μž₯
286
  print("λͺ¨λΈ μ €μž₯ 쀑...")
 
287
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_incheon.pkl")
288
  joblib.dump(models, model_save_path)
289
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smote_incheon_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
 
309
 
310
  # λͺ¨λΈ μ €μž₯
311
  print("λͺ¨λΈ μ €μž₯ 쀑...")
312
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
313
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_incheon.pkl")
314
  joblib.dump(models, model_save_path)
315
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
Analysis_code/5.optima/lgb_smote/LGB_smote_seoul.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
@@ -284,6 +309,7 @@ for fold_idx, (df_smote, (train_years, val_year)) in enumerate(
284
 
285
  # λͺ¨λΈ μ €μž₯
286
  print("λͺ¨λΈ μ €μž₯ 쀑...")
 
287
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_seoul.pkl")
288
  joblib.dump(models, model_save_path)
289
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smote_seoul_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
 
309
 
310
  # λͺ¨λΈ μ €μž₯
311
  print("λͺ¨λΈ μ €μž₯ 쀑...")
312
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
313
  model_save_path = os.path.join(base_dir, "save_model/lgb_optima/lgb_smote_seoul.pkl")
314
  joblib.dump(models, model_save_path)
315
  print(f"λͺ¨λΈμ΄ {model_save_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_busan.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smotenc_ctgan20000_busan_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_daegu.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smotenc_ctgan20000_daegu_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_daejeon.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smotenc_ctgan20000_daejeon_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_gwangju.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smotenc_ctgan20000_gwangju_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_incheon.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smotenc_ctgan20000_incheon_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
Analysis_code/5.optima/lgb_smotenc_ctgan20000/LGB_smotenc_ctgan20000_seoul.py CHANGED
@@ -260,6 +260,31 @@ lgb_best = fmin(
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
264
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
265
  models = []
 
260
  )
261
  print(f"μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {lgb_best}")
262
 
263
+ # Best loss (CSI 점수의 μŒμˆ˜κ°’μ΄λ―€λ‘œ, μ‹€μ œ CSIλŠ” -loss)
264
+ best_loss = trials.best_trial['result']['loss']
265
+ best_csi = -best_loss
266
+ print(f"졜적 CSI 점수: {best_csi:.4f} (loss: {best_loss:.4f})")
267
+
268
+ # λͺ¨λ“  trial의 loss κ°’ μΆ”μΆœ
269
+ losses = [trial['result']['loss'] for trial in trials.trials if trial['result']['status'] == 'ok']
270
+ csi_scores = [-loss for loss in losses]
271
+
272
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
273
+ print(f" - 총 μ‹œλ„ 횟수: {len(trials.trials)}")
274
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(losses)}")
275
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
276
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
277
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
278
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
279
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
280
+
281
+ # Trials 객체 μ €μž₯
282
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
283
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
284
+ trials_path = os.path.join(base_dir, "optimization_history/lgb_smotenc_ctgan20000_seoul_trials.pkl")
285
+ joblib.dump(trials, trials_path)
286
+ print(f"\nμ΅œμ ν™” Trials 객체가 {trials_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
287
+
288
  # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅
289
  print("μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...")
290
  models = []
Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_daegu.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="resnet_like", region="daegu", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/resnet_like_ctgan10000_daegu_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="resnet_like",
79
+ region="daegu",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_daejeon.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="resnet_like", region="daejeon", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/resnet_like_ctgan10000_daejeon_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="resnet_like",
79
+ region="daejeon",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_gwangju.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="resnet_like", region="gwangju", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/resnet_like_ctgan10000_gwangju_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="resnet_like",
79
+ region="gwangju",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_incheon.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="resnet_like", region="incheon", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/resnet_like_ctgan10000_incheon_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="resnet_like",
79
+ region="incheon",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/resnet_like_ctgan10000/resnet_like_ctgan10000_seoul.py ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import optuna
2
+ import numpy as np
3
+ import random
4
+ import pandas as pd
5
+ import joblib
6
+ import os
7
+ import torch
8
+ from utils import *
9
+ # Python 및 Numpy μ‹œλ“œ κ³ μ •
10
+ seed = 42
11
+ random.seed(seed)
12
+ np.random.seed(seed)
13
+
14
+
15
+ # 1. Study 생성 μ‹œ 'maximize'둜 μ„€μ •
16
+ study = optuna.create_study(
17
+ direction="maximize", # CSI μ μˆ˜κ°€ λ†’μ„μˆ˜λ‘ μ’‹μœΌλ―€λ‘œ maximize
18
+ pruner=optuna.pruners.MedianPruner(n_warmup_steps=10) # 초반 10에폭은 μ§€μΌœλ³΄κ³  이후 κ°€μ§€μΉ˜κΈ°
19
+ )
20
+ # Trial μ™„λ£Œ μ‹œ 상세 정보 좜λ ₯ν•˜λŠ” callback ν•¨μˆ˜
21
+ def print_trial_callback(study, trial):
22
+ """각 trial μ™„λ£Œ μ‹œ best valueλ₯Ό ν¬ν•¨ν•œ 상세 정보 좜λ ₯"""
23
+ print(f"\n{'='*80}")
24
+ print(f"Trial {trial.number} μ™„λ£Œ")
25
+ print(f" Value (CSI): {trial.value:.6f}" if trial.value is not None else f" Value: {trial.value}")
26
+ print(f" Parameters: {trial.params}")
27
+ print(f" Best Value (CSI): {study.best_value:.6f}" if study.best_value is not None else f" Best Value: {study.best_value}")
28
+ print(f" Best Trial: {study.best_trial.number}")
29
+ print(f" Best Parameters: {study.best_params}")
30
+ print(f"{'='*80}\n")
31
+
32
+
33
+
34
+ # 2. μ΅œμ ν™” μ‹€ν–‰
35
+ study.optimize(
36
+ lambda trial: objective(trial, model_choose="resnet_like", region="seoul", data_sample='ctgan10000'),
37
+ n_trials=100
38
+ ,
39
+ callbacks=[print_trial_callback]
40
+ )
41
+
42
+ # 3. κ²°κ³Ό 확인 및 μš”μ•½
43
+ print(f"\nμ΅œμ ν™” μ™„λ£Œ.")
44
+ print(f"Best CSI Score: {study.best_value:.4f}")
45
+ print(f"Best Hyperparameters: {study.best_params}")
46
+
47
+ try:
48
+ # λͺ¨λ“  trial의 CSI 점수 μΆ”μΆœ
49
+ csi_scores = [trial.value for trial in study.trials if trial.value is not None]
50
+
51
+ if len(csi_scores) > 0:
52
+ print(f"\nμ΅œμ ν™” κ³Όμ • μš”μ•½:")
53
+ print(f" - 총 μ‹œλ„ 횟수: {len(study.trials)}")
54
+ print(f" - μ„±κ³΅ν•œ μ‹œλ„: {len(csi_scores)}")
55
+ print(f" - 졜초 CSI: {csi_scores[0]:.4f}")
56
+ print(f" - μ΅œμ’… CSI: {csi_scores[-1]:.4f}")
57
+ print(f" - 졜고 CSI: {max(csi_scores):.4f}")
58
+ print(f" - μ΅œμ € CSI: {min(csi_scores):.4f}")
59
+ print(f" - 평균 CSI: {np.mean(csi_scores):.4f}")
60
+
61
+ # Study 객체 μ €μž₯
62
+ # 파일 μœ„μΉ˜ 기반으둜 base 디렉토리 경둜 μ„€μ •
63
+ current_file_dir = os.path.dirname(os.path.abspath(__file__))
64
+ base_dir = os.path.dirname(os.path.dirname(current_file_dir)) # 5.optima 디렉토리
65
+ os.makedirs(os.path.join(base_dir, "optimization_history"), exist_ok=True)
66
+ study_path = os.path.join(base_dir, "optimization_history/resnet_like_ctgan10000_seoul_trials.pkl")
67
+ joblib.dump(study, study_path)
68
+ print(f"\nμ΅œμ ν™” Study 객체가 {study_path}에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.")
69
+
70
+ # μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯
71
+ print("\n" + "="*50)
72
+ print("μ΅œμ ν™”λœ ν•˜μ΄νΌνŒŒλΌλ―Έν„°λ‘œ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘")
73
+ print("="*50)
74
+
75
+ best_params = study.best_params
76
+ model_path = train_final_model(
77
+ best_params=best_params,
78
+ model_choose="resnet_like",
79
+ region="seoul",
80
+ data_sample='ctgan10000',
81
+ target='multi',
82
+ n_folds=3,
83
+ random_state=seed
84
+ )
85
+
86
+ print(f"\nμ΅œμ’… λͺ¨λΈ ν•™μŠ΅ 및 μ €μž₯ μ™„λ£Œ!")
87
+ print(f"μ €μž₯된 λͺ¨λΈ 경둜: {model_path}")
88
+
89
+ except Exception as e:
90
+ print(f"\n⚠️ μ΅œμ ν™” κ²°κ³Ό 뢄석 쀑 였λ₯˜ λ°œμƒ: {e}")
91
+ import traceback
92
+ traceback.print_exc()
93
+
94
+ # 정상 μ’…λ£Œ
95
+ import sys
96
+ sys.exit(0)
97
+
Analysis_code/5.optima/run_bash/deepgbm/deepgbm_ctgan10000.log ADDED
The diff for this file is too large to render. See raw diff
 
Analysis_code/5.optima/run_bash/deepgbm/deepgbm_smotenc_ctgan20000.log CHANGED
The diff for this file is too large to render. See raw diff
 
Analysis_code/5.optima/run_bash/deepgbm/run_deepgbm_ctgan10000.sh ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+
3
+ # 슀크립트 λ””λ ‰ν† λ¦¬λ‘œ 이동 (μƒμœ„ 디렉토리인 5.optima둜 이동)
4
+ cd "$(dirname "$0")/../.."
5
+
6
+ # μ‹œμž‘ μ‹œκ°„ 기둝
7
+ START_TIME=$(date +%s)
8
+ echo "=========================================="
9
+ echo "DeepGBM CTGAN10000 파일 μ‹€ν–‰ μ‹œμž‘"
10
+ echo "μ‹œμž‘ μ‹œκ°„: $(date '+%Y-%m-%d %H:%M:%S')"
11
+ echo "GPU: 0번 (CUDA_VISIBLE_DEVICES=0)"
12
+ echo "=========================================="
13
+ echo ""
14
+
15
+ # μ‹€ν–‰ν•  파일 λͺ©λ‘
16
+ FILES=(
17
+ "deepgbm_ctgan10000_busan.py"
18
+ "deepgbm_ctgan10000_daegu.py"
19
+ "deepgbm_ctgan10000_daejeon.py"
20
+ "deepgbm_ctgan10000_gwangju.py"
21
+ "deepgbm_ctgan10000_incheon.py"
22
+ "deepgbm_ctgan10000_seoul.py"
23
+ )
24
+
25
+ # μ—λŸ¬ λ°œμƒ μ‹œ 쀑단 μ—¬λΆ€ (set -eλ₯Ό μ‚¬μš©ν•˜λ©΄ μ—λŸ¬ λ°œμƒ μ‹œ μ¦‰μ‹œ 쀑단)
26
+ set -e
27
+
28
+ # 각 파일 μ‹€ν–‰
29
+ SUCCESS_COUNT=0
30
+ FAIL_COUNT=0
31
+
32
+ for file in "${FILES[@]}"; do
33
+ filepath="deepgbm_ctgan10000/$file"
34
+ if [ ! -f "$filepath" ]; then
35
+ echo "⚠️ κ²½κ³ : $filepath νŒŒμΌμ„ 찾을 수 μ—†μŠ΅λ‹ˆλ‹€. κ±΄λ„ˆλœλ‹ˆλ‹€."
36
+ FAIL_COUNT=$((FAIL_COUNT + 1))
37
+ continue
38
+ fi
39
+
40
+ echo "----------------------------------------"
41
+ echo "μ‹€ν–‰ 쀑: $filepath"
42
+ echo "μ‹œμž‘ μ‹œκ°„: $(date '+%Y-%m-%d %H:%M:%S')"
43
+ echo "----------------------------------------"
44
+
45
+ FILE_START=$(date +%s)
46
+
47
+ # Python 슀크립트 μ‹€ν–‰ (GPU 0번 μ„€μ •)
48
+ if CUDA_VISIBLE_DEVICES=0 python3 -u "$filepath"; then
49
+ FILE_END=$(date +%s)
50
+ FILE_DURATION=$((FILE_END - FILE_START))
51
+ echo ""
52
+ echo "βœ“ μ™„λ£Œ: $filepath (μ†Œμš” μ‹œκ°„: ${FILE_DURATION}초)"
53
+ SUCCESS_COUNT=$((SUCCESS_COUNT + 1))
54
+ else
55
+ FILE_END=$(date +%s)
56
+ FILE_DURATION=$((FILE_END - FILE_START))
57
+ echo ""
58
+ echo "βœ— μ‹€νŒ¨: $filepath (μ†Œμš” μ‹œκ°„: ${FILE_DURATION}초)"
59
+ FAIL_COUNT=$((FAIL_COUNT + 1))
60
+ echo "μ—λŸ¬ λ°œμƒμœΌλ‘œ 인해 슀크립트λ₯Ό μ€‘λ‹¨ν•©λ‹ˆλ‹€."
61
+ exit 1
62
+ fi
63
+ echo ""
64
+ done
65
+
66
+ # μ’…λ£Œ μ‹œκ°„ 기둝
67
+ END_TIME=$(date +%s)
68
+ TOTAL_DURATION=$((END_TIME - START_TIME))
69
+ HOURS=$((TOTAL_DURATION / 3600))
70
+ MINUTES=$(((TOTAL_DURATION % 3600) / 60))
71
+ SECONDS=$((TOTAL_DURATION % 60))
72
+
73
+ echo "=========================================="
74
+ echo "DeepGBM CTGAN10000 파일 μ‹€ν–‰ μ™„λ£Œ"
75
+ echo "μ’…λ£Œ μ‹œκ°„: $(date '+%Y-%m-%d %H:%M:%S')"
76
+ echo "총 μ†Œμš” μ‹œκ°„: ${HOURS}μ‹œκ°„ ${MINUTES}λΆ„ ${SECONDS}초"
77
+ echo "성곡: ${SUCCESS_COUNT}개"
78
+ echo "μ‹€νŒ¨: ${FAIL_COUNT}개"
79
+ echo "=========================================="
80
+
Analysis_code/5.optima/run_bash/ft_transformer/ft_transformer_ctgan10000.log ADDED
The diff for this file is too large to render. See raw diff
 
Analysis_code/5.optima/run_bash/ft_transformer/ft_transformer_smote.log CHANGED
The diff for this file is too large to render. See raw diff
 
Analysis_code/5.optima/run_bash/ft_transformer/ft_transformer_smotenc_ctgan20000.log CHANGED
The diff for this file is too large to render. See raw diff
 
Analysis_code/5.optima/run_bash/ft_transformer/run_ft_transformer_ctgan10000.sh ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+
3
+ # 슀크립트 λ””λ ‰ν† λ¦¬λ‘œ 이동 (μƒμœ„ 디렉토리인 5.optima둜 이동)
4
+ cd "$(dirname "$0")/../.."
5
+
6
+ # μ‹œμž‘ μ‹œκ°„ 기둝
7
+ START_TIME=$(date +%s)
8
+ echo "=========================================="
9
+ echo "FT-Transformer CTGAN10000 파일 μ‹€ν–‰ μ‹œμž‘"
10
+ echo "μ‹œμž‘ μ‹œκ°„: $(date '+%Y-%m-%d %H:%M:%S')"
11
+ echo "GPU: 1번 (CUDA_VISIBLE_DEVICES=1)"
12
+ echo "=========================================="
13
+ echo ""
14
+
15
+ # μ‹€ν–‰ν•  파일 λͺ©λ‘
16
+ FILES=(
17
+ "ft_transformer_ctgan10000_busan.py"
18
+ "ft_transformer_ctgan10000_daegu.py"
19
+ "ft_transformer_ctgan10000_daejeon.py"
20
+ "ft_transformer_ctgan10000_gwangju.py"
21
+ "ft_transformer_ctgan10000_incheon.py"
22
+ "ft_transformer_ctgan10000_seoul.py"
23
+ )
24
+
25
+ # μ—λŸ¬ λ°œμƒ μ‹œ 쀑단 μ—¬λΆ€ (set -eλ₯Ό μ‚¬μš©ν•˜λ©΄ μ—λŸ¬ λ°œμƒ μ‹œ μ¦‰μ‹œ 쀑단)
26
+ set -e
27
+
28
+ # 각 파일 μ‹€ν–‰
29
+ SUCCESS_COUNT=0
30
+ FAIL_COUNT=0
31
+
32
+ for file in "${FILES[@]}"; do
33
+ filepath="ft_transformer_ctgan10000/$file"
34
+ if [ ! -f "$filepath" ]; then
35
+ echo "⚠️ κ²½κ³ : $filepath νŒŒμΌμ„ 찾을 수 μ—†μŠ΅λ‹ˆλ‹€. κ±΄λ„ˆλœλ‹ˆλ‹€."
36
+ FAIL_COUNT=$((FAIL_COUNT + 1))
37
+ continue
38
+ fi
39
+
40
+ echo "----------------------------------------"
41
+ echo "μ‹€ν–‰ 쀑: $filepath"
42
+ echo "μ‹œμž‘ μ‹œκ°„: $(date '+%Y-%m-%d %H:%M:%S')"
43
+ echo "----------------------------------------"
44
+
45
+ FILE_START=$(date +%s)
46
+
47
+ # Python 슀크립트 μ‹€ν–‰ (GPU 1번 μ„€μ •, 색상 μ½”λ“œ λΉ„ν™œμ„±ν™”)
48
+ if NO_COLOR=1 TERM=dumb CUDA_VISIBLE_DEVICES=1 python3 -u "$filepath"; then
49
+ FILE_END=$(date +%s)
50
+ FILE_DURATION=$((FILE_END - FILE_START))
51
+ echo ""
52
+ echo "βœ“ μ™„λ£Œ: $filepath (μ†Œμš” μ‹œκ°„: ${FILE_DURATION}초)"
53
+ SUCCESS_COUNT=$((SUCCESS_COUNT + 1))
54
+ else
55
+ FILE_END=$(date +%s)
56
+ FILE_DURATION=$((FILE_END - FILE_START))
57
+ echo ""
58
+ echo "βœ— μ‹€νŒ¨: $filepath (μ†Œμš” μ‹œκ°„: ${FILE_DURATION}초)"
59
+ FAIL_COUNT=$((FAIL_COUNT + 1))
60
+ echo "μ—λŸ¬ λ°œμƒμœΌλ‘œ 인해 슀크립트λ₯Ό μ€‘λ‹¨ν•©λ‹ˆλ‹€."
61
+ exit 1
62
+ fi
63
+ echo ""
64
+ done
65
+
66
+ # μ’…λ£Œ μ‹œκ°„ 기둝
67
+ END_TIME=$(date +%s)
68
+ TOTAL_DURATION=$((END_TIME - START_TIME))
69
+ HOURS=$((TOTAL_DURATION / 3600))
70
+ MINUTES=$(((TOTAL_DURATION % 3600) / 60))
71
+ SECONDS=$((TOTAL_DURATION % 60))
72
+
73
+ echo "=========================================="
74
+ echo "FT-Transformer CTGAN10000 파일 μ‹€ν–‰ μ™„λ£Œ"
75
+ echo "μ’…λ£Œ μ‹œκ°„: $(date '+%Y-%m-%d %H:%M:%S')"
76
+ echo "총 μ†Œμš” μ‹œκ°„: ${HOURS}μ‹œκ°„ ${MINUTES}λΆ„ ${SECONDS}초"
77
+ echo "성곡: ${SUCCESS_COUNT}개"
78
+ echo "μ‹€νŒ¨: ${FAIL_COUNT}개"
79
+ echo "=========================================="
80
+
Analysis_code/5.optima/run_bash/lgb/lgb_ctgan10000.log ADDED
@@ -0,0 +1,219 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
1
  1%| | 1/100 [01:04<1:47:14, 65.00s/trial, best loss: -0.4238]
2
  2%|▏ | 2/100 [01:54<1:31:25, 55.98s/trial, best loss: -0.4576]
3
  3%|β–Ž | 3/100 [02:31<1:16:36, 47.39s/trial, best loss: -0.4733]
4
  4%|▍ | 4/100 [03:21<1:17:24, 48.38s/trial, best loss: -0.4758]
5
  5%|β–Œ | 5/100 [04:00<1:10:52, 44.77s/trial, best loss: -0.4758]
6
  6%|β–Œ | 6/100 [04:24<59:01, 37.68s/trial, best loss: -0.4758]
7
  7%|β–‹ | 7/100 [04:54<54:54, 35.42s/trial, best loss: -0.4758]
8
  8%|β–Š | 8/100 [05:41<59:49, 39.02s/trial, best loss: -0.4758]
9
  9%|β–‰ | 9/100 [06:04<51:22, 33.87s/trial, best loss: -0.4758]
10
  10%|β–ˆ | 10/100 [06:52<57:39, 38.44s/trial, best loss: -0.4758]
11
  11%|β–ˆ | 11/100 [07:30<56:39, 38.20s/trial, best loss: -0.4835]
12
  12%|β–ˆβ– | 12/100 [08:01<52:39, 35.90s/trial, best loss: -0.4835]
13
  13%|β–ˆβ–Ž | 13/100 [08:23<46:16, 31.91s/trial, best loss: -0.4835]
14
  14%|β–ˆβ– | 14/100 [08:46<41:36, 29.03s/trial, best loss: -0.4835]
15
  15%|β–ˆβ–Œ | 15/100 [09:24<44:58, 31.74s/trial, best loss: -0.4835]
16
  16%|β–ˆβ–Œ | 16/100 [10:12<51:30, 36.80s/trial, best loss: -0.4835]
17
  17%|β–ˆβ–‹ | 17/100 [10:47<50:13, 36.30s/trial, best loss: -0.4835]
18
  18%|β–ˆβ–Š | 18/100 [11:15<46:03, 33.70s/trial, best loss: -0.4835]
19
  19%|β–ˆβ–‰ | 19/100 [11:52<46:41, 34.58s/trial, best loss: -0.4835]
20
  20%|β–ˆβ–ˆ | 20/100 [12:13<40:56, 30.71s/trial, best loss: -0.4835]
21
  21%|β–ˆβ–ˆ | 21/100 [12:44<40:26, 30.71s/trial, best loss: -0.4835]
22
  22%|β–ˆβ–ˆβ– | 22/100 [13:14<39:43, 30.56s/trial, best loss: -0.4836]
23
  23%|β–ˆβ–ˆβ–Ž | 23/100 [13:40<37:14, 29.02s/trial, best loss: -0.4836]
24
  24%|β–ˆβ–ˆβ– | 24/100 [14:23<42:05, 33.24s/trial, best loss: -0.4836]
25
  25%|β–ˆβ–ˆβ–Œ | 25/100 [14:53<40:20, 32.27s/trial, best loss: -0.4836]
26
  26%|β–ˆβ–ˆβ–Œ | 26/100 [15:18<37:18, 30.25s/trial, best loss: -0.4836]
27
  27%|β–ˆβ–ˆβ–‹ | 27/100 [15:47<36:22, 29.90s/trial, best loss: -0.4836]
28
  28%|β–ˆβ–ˆβ–Š | 28/100 [16:40<44:02, 36.70s/trial, best loss: -0.4836]
29
  29%|β–ˆβ–ˆβ–‰ | 29/100 [17:20<44:27, 37.57s/trial, best loss: -0.4836]
30
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [18:02<45:34, 39.06s/trial, best loss: -0.4836]
31
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [18:26<39:34, 34.42s/trial, best loss: -0.4836]
32
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [19:00<39:06, 34.51s/trial, best loss: -0.4836]
33
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [19:37<39:24, 35.29s/trial, best loss: -0.4836]
34
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [20:20<41:17, 37.54s/trial, best loss: -0.4836]
35
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [20:46<36:49, 33.99s/trial, best loss: -0.4836]
36
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [21:42<43:21, 40.65s/trial, best loss: -0.4836]
37
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [22:19<41:21, 39.38s/trial, best loss: -0.4836]
38
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [23:07<43:38, 42.23s/trial, best loss: -0.4836]
39
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [23:30<36:47, 36.19s/trial, best loss: -0.4836]
40
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [24:00<34:29, 34.49s/trial, best loss: -0.4836]
41
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [24:30<32:32, 33.10s/trial, best loss: -0.4836]
42
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [24:56<29:53, 30.93s/trial, best loss: -0.4836]
43
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [25:27<29:21, 30.90s/trial, best loss: -0.4836]
44
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [25:50<26:44, 28.65s/trial, best loss: -0.4836]
45
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [26:40<32:11, 35.13s/trial, best loss: -0.4836]
46
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [27:16<31:53, 35.43s/trial, best loss: -0.4836]
47
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [27:57<32:41, 37.01s/trial, best loss: -0.4836]
48
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [28:48<35:47, 41.30s/trial, best loss: -0.4836]
49
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [29:27<34:26, 40.53s/trial, best loss: -0.4836]
50
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [29:54<30:25, 36.51s/trial, best loss: -0.4836]
51
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [30:53<35:10, 43.06s/trial, best loss: -0.4836]
52
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [31:20<30:35, 38.24s/trial, best loss: -0.4836]
53
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [31:53<28:54, 36.90s/trial, best loss: -0.4836]
54
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [33:09<37:07, 48.43s/trial, best loss: -0.4836]
55
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [33:34<31:10, 41.56s/trial, best loss: -0.4836]
56
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [33:56<26:01, 35.48s/trial, best loss: -0.4836]
57
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [34:25<24:02, 33.54s/trial, best loss: -0.4836]
58
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [35:00<23:51, 34.09s/trial, best loss: -0.4836]
59
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [35:53<27:15, 39.88s/trial, best loss: -0.4836]
60
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [36:31<26:10, 39.26s/trial, best loss: -0.4836]
61
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [36:57<22:56, 35.30s/trial, best loss: -0.4836]
62
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [37:32<22:11, 35.04s/trial, best loss: -0.4836]
63
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [37:57<19:47, 32.11s/trial, best loss: -0.4836]
64
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [38:23<18:11, 30.33s/trial, best loss: -0.4836]
65
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [39:08<20:11, 34.62s/trial, best loss: -0.4836]
66
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [39:40<19:14, 33.96s/trial, best loss: -0.4836]
67
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [40:11<18:06, 32.93s/trial, best loss: -0.4836]
68
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [40:36<16:23, 30.74s/trial, best loss: -0.4836]
69
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [41:04<15:20, 29.70s/trial, best loss: -0.4836]
70
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [41:31<14:34, 29.15s/trial, best loss: -0.4836]
71
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [41:55<13:17, 27.51s/trial, best loss: -0.4836]
72
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [42:36<14:45, 31.64s/trial, best loss: -0.4836]
73
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [43:06<13:58, 31.06s/trial, best loss: -0.4836]
74
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [43:34<12:59, 29.97s/trial, best loss: -0.4836]
75
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [44:05<12:43, 30.53s/trial, best loss: -0.4836]
76
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [44:46<13:24, 33.52s/trial, best loss: -0.4836]
77
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [45:22<13:09, 34.35s/trial, best loss: -0.4836]
78
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [45:53<12:11, 33.24s/trial, best loss: -0.4836]
79
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [46:20<10:58, 31.38s/trial, best loss: -0.4836]
80
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [46:45<09:51, 29.59s/trial, best loss: -0.4836]
81
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [47:20<09:53, 31.23s/trial, best loss: -0.4836]
82
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [47:51<09:19, 31.11s/trial, best loss: -0.4836]
83
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [48:23<08:55, 31.49s/trial, best loss: -0.4836]
84
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [49:06<09:14, 34.66s/trial, best loss: -0.4836]
85
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [49:31<07:59, 31.94s/trial, best loss: -0.4836]
86
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [50:18<08:28, 36.32s/trial, best loss: -0.4836]
87
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [51:01<08:20, 38.50s/trial, best loss: -0.4836]
88
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [52:08<09:24, 47.02s/trial, best loss: -0.4836]
89
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [52:57<08:43, 47.60s/trial, best loss: -0.4836]
90
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [53:37<07:31, 45.17s/trial, best loss: -0.4836]
91
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [54:28<07:04, 47.18s/trial, best loss: -0.4836]
92
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [55:14<06:13, 46.70s/trial, best loss: -0.4836]
93
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [56:21<06:08, 52.71s/trial, best loss: -0.4836]
94
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [57:02<04:55, 49.27s/trial, best loss: -0.4836]
95
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [57:39<03:48, 45.62s/trial, best loss: -0.4836]
96
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [58:33<03:12, 48.15s/trial, best loss: -0.4836]
97
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [59:14<02:17, 45.95s/trial, best loss: -0.4836]
98
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [59:54<01:28, 44.22s/trial, best loss: -0.4836]
99
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [1:00:48<00:47, 47.12s/trial, best loss: -0.4836]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
100
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
101
  1%| | 1/100 [00:18<31:06, 18.85s/trial, best loss: -0.3977]
102
  2%|▏ | 2/100 [00:59<52:04, 31.88s/trial, best loss: -0.4107]
103
  3%|β–Ž | 3/100 [01:25<46:42, 28.89s/trial, best loss: -0.4107]
104
  4%|▍ | 4/100 [02:15<59:36, 37.25s/trial, best loss: -0.4107]
105
  5%|β–Œ | 5/100 [02:48<56:54, 35.94s/trial, best loss: -0.4107]
106
  6%|β–Œ | 6/100 [03:16<52:00, 33.20s/trial, best loss: -0.4107]
107
  7%|β–‹ | 7/100 [04:01<57:30, 37.10s/trial, best loss: -0.4107]
108
  8%|β–Š | 8/100 [04:43<58:56, 38.44s/trial, best loss: -0.4107]
109
  9%|β–‰ | 9/100 [05:10<52:53, 34.88s/trial, best loss: -0.4107]
110
  10%|β–ˆ | 10/100 [05:34<47:28, 31.65s/trial, best loss: -0.4107]
111
  11%|β–ˆ | 11/100 [06:25<55:28, 37.39s/trial, best loss: -0.4107]
112
  12%|β–ˆβ– | 12/100 [06:52<50:33, 34.47s/trial, best loss: -0.4107]
113
  13%|β–ˆβ–Ž | 13/100 [07:15<44:44, 30.85s/trial, best loss: -0.4155]
114
  14%|β–ˆβ– | 14/100 [07:47<44:52, 31.31s/trial, best loss: -0.4155]
115
  15%|β–ˆβ–Œ | 15/100 [08:10<40:45, 28.77s/trial, best loss: -0.4161]
116
  16%|β–ˆβ–Œ | 16/100 [08:33<37:35, 26.85s/trial, best loss: -0.4161]
117
  17%|β–ˆβ–‹ | 17/100 [09:15<43:36, 31.53s/trial, best loss: -0.4161]
118
  18%|β–ˆβ–Š | 18/100 [09:51<45:05, 32.99s/trial, best loss: -0.4161]
119
  19%|β–ˆβ–‰ | 19/100 [10:14<40:11, 29.77s/trial, best loss: -0.4161]
120
  20%|β–ˆβ–ˆ | 20/100 [11:04<48:02, 36.03s/trial, best loss: -0.4161]
121
  21%|β–ˆβ–ˆ | 21/100 [11:25<41:14, 31.32s/trial, best loss: -0.4203]
122
  22%|β–ˆβ–ˆβ– | 22/100 [11:51<38:51, 29.89s/trial, best loss: -0.4203]
123
  23%|β–ˆβ–ˆβ–Ž | 23/100 [12:16<36:18, 28.29s/trial, best loss: -0.4203]
124
  24%|β–ˆβ–ˆβ– | 24/100 [12:42<35:07, 27.72s/trial, best loss: -0.4203]
125
  25%|β–ˆβ–ˆβ–Œ | 25/100 [13:04<32:21, 25.88s/trial, best loss: -0.4203]
126
  26%|β–ˆβ–ˆβ–Œ | 26/100 [13:25<30:16, 24.54s/trial, best loss: -0.4203]
127
  27%|β–ˆβ–ˆβ–‹ | 27/100 [13:46<28:42, 23.60s/trial, best loss: -0.4203]
128
  28%|β–ˆβ–ˆβ–Š | 28/100 [14:08<27:40, 23.06s/trial, best loss: -0.4203]
129
  29%|β–ˆβ–ˆβ–‰ | 29/100 [14:33<27:46, 23.47s/trial, best loss: -0.4203]
130
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [14:53<26:12, 22.46s/trial, best loss: -0.4207]
131
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [15:14<25:33, 22.22s/trial, best loss: -0.4254]
132
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [15:36<24:48, 21.90s/trial, best loss: -0.4254]
133
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [15:57<24:20, 21.80s/trial, best loss: -0.4254]
134
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [16:19<23:58, 21.79s/trial, best loss: -0.4254]
135
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [16:47<25:30, 23.55s/trial, best loss: -0.4254]
136
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [17:12<25:35, 24.00s/trial, best loss: -0.4254]
137
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [17:34<24:35, 23.42s/trial, best loss: -0.4254]
138
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [18:02<25:41, 24.86s/trial, best loss: -0.4254]
139
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [18:24<24:19, 23.93s/trial, best loss: -0.4254]
140
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [18:50<24:31, 24.52s/trial, best loss: -0.4254]
141
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [19:17<25:04, 25.51s/trial, best loss: -0.4254]
142
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [19:50<26:51, 27.78s/trial, best loss: -0.4254]
143
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [20:16<25:36, 26.96s/trial, best loss: -0.4254]
144
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [20:49<27:04, 29.00s/trial, best loss: -0.4254]
145
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [21:07<23:36, 25.75s/trial, best loss: -0.4254]
146
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [21:26<21:14, 23.60s/trial, best loss: -0.4254]
147
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [21:49<20:41, 23.42s/trial, best loss: -0.4254]
148
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [22:09<19:27, 22.45s/trial, best loss: -0.4254]
149
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [23:08<28:18, 33.30s/trial, best loss: -0.4254]
150
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [23:33<25:45, 30.90s/trial, best loss: -0.4254]
151
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [23:54<22:51, 27.99s/trial, best loss: -0.4254]
152
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [24:46<28:08, 35.17s/trial, best loss: -0.4255]
153
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [25:19<26:54, 34.35s/trial, best loss: -0.4255]
154
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [26:00<27:54, 36.41s/trial, best loss: -0.4255]
155
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [26:52<30:51, 41.14s/trial, best loss: -0.4255]
156
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [27:21<27:32, 37.55s/trial, best loss: -0.4255]
157
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [27:54<25:48, 36.01s/trial, best loss: -0.4255]
158
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [28:38<27:00, 38.59s/trial, best loss: -0.4308]
159
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [29:22<27:21, 40.03s/trial, best loss: -0.4308]
160
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [29:55<25:16, 37.92s/trial, best loss: -0.4308]
161
  61%|β–ˆβ–ˆοΏ½οΏ½β–ˆβ–ˆβ–ˆ | 61/100 [30:42<26:27, 40.70s/trial, best loss: -0.4308]
162
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [31:22<25:35, 40.40s/trial, best loss: -0.4308]
163
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [32:08<26:04, 42.29s/trial, best loss: -0.4308]
164
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [32:58<26:41, 44.49s/trial, best loss: -0.4308]
165
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [33:35<24:39, 42.28s/trial, best loss: -0.4308]
166
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [34:26<25:30, 45.01s/trial, best loss: -0.4308]
167
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [35:12<24:52, 45.21s/trial, best loss: -0.4308]
168
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [36:03<25:03, 47.00s/trial, best loss: -0.4308]
169
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [36:49<24:05, 46.63s/trial, best loss: -0.4308]
170
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [37:31<22:40, 45.35s/trial, best loss: -0.4308]
171
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [38:07<20:28, 42.35s/trial, best loss: -0.4308]
172
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [38:45<19:12, 41.15s/trial, best loss: -0.4308]
173
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [39:21<17:45, 39.48s/trial, best loss: -0.4308]
174
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [39:55<16:22, 37.80s/trial, best loss: -0.4308]
175
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [40:30<15:26, 37.07s/trial, best loss: -0.4308]
176
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [41:12<15:22, 38.43s/trial, best loss: -0.4308]
177
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [41:43<13:55, 36.31s/trial, best loss: -0.4308]
178
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [42:09<12:10, 33.21s/trial, best loss: -0.4308]
179
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [42:37<11:02, 31.57s/trial, best loss: -0.4308]
180
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [43:10<10:44, 32.23s/trial, best loss: -0.4308]
181
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [43:46<10:28, 33.10s/trial, best loss: -0.4308]
182
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [44:40<11:49, 39.44s/trial, best loss: -0.4317]
183
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [45:16<10:55, 38.57s/trial, best loss: -0.4317]
184
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [46:07<11:13, 42.10s/trial, best loss: -0.4317]
185
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [47:05<11:43, 46.91s/trial, best loss: -0.4317]
186
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [47:54<11:05, 47.51s/trial, best loss: -0.4317]
187
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [48:33<09:44, 44.98s/trial, best loss: -0.4317]
188
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [48:57<07:46, 38.87s/trial, best loss: -0.4317]
189
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [49:25<06:31, 35.56s/trial, best loss: -0.4317]
190
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [50:23<07:01, 42.18s/trial, best loss: -0.4339]
191
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [51:11<06:35, 43.97s/trial, best loss: -0.4339]
192
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [52:08<06:21, 47.75s/trial, best loss: -0.4339]
193
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [52:49<05:21, 45.99s/trial, best loss: -0.4339]
194
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [53:41<04:45, 47.66s/trial, best loss: -0.4339]
195
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [54:27<03:56, 47.24s/trial, best loss: -0.4339]
196
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [55:20<03:14, 48.75s/trial, best loss: -0.4339]
197
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [55:47<02:06, 42.27s/trial, best loss: -0.4339]
198
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [56:52<01:38, 49.05s/trial, best loss: -0.4339]
199
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [57:25<00:44, 44.40s/trial, best loss: -0.4339]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
200
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
201
  1%| | 1/100 [00:28<47:17, 28.66s/trial, best loss: -0.4792]
202
  2%|▏ | 2/100 [01:38<1:25:59, 52.65s/trial, best loss: -0.4833]
203
  3%|β–Ž | 3/100 [02:12<1:11:30, 44.23s/trial, best loss: -0.4833]
204
  4%|▍ | 4/100 [02:44<1:02:52, 39.29s/trial, best loss: -0.4833]
205
  5%|β–Œ | 5/100 [03:08<53:32, 33.81s/trial, best loss: -0.4833]
206
  6%|β–Œ | 6/100 [03:41<52:46, 33.68s/trial, best loss: -0.4833]
207
  7%|β–‹ | 7/100 [04:23<56:25, 36.40s/trial, best loss: -0.4833]
208
  8%|β–Š | 8/100 [05:32<1:11:34, 46.68s/trial, best loss: -0.4833]
209
  9%|β–‰ | 9/100 [06:02<1:02:47, 41.41s/trial, best loss: -0.4864]
210
  10%|β–ˆ | 10/100 [07:04<1:12:04, 48.05s/trial, best loss: -0.4864]
211
  11%|β–ˆ | 11/100 [07:31<1:01:24, 41.40s/trial, best loss: -0.4864]
212
  12%|β–ˆβ– | 12/100 [07:54<52:32, 35.82s/trial, best loss: -0.4864]
213
  13%|β–ˆβ–Ž | 13/100 [09:06<1:07:45, 46.72s/trial, best loss: -0.4878]
214
  14%|β–ˆβ– | 14/100 [09:35<59:23, 41.44s/trial, best loss: -0.4878]
215
  15%|β–ˆβ–Œ | 15/100 [10:15<58:02, 40.98s/trial, best loss: -0.4878]
216
  16%|β–ˆβ–Œ | 16/100 [10:42<51:40, 36.91s/trial, best loss: -0.4878]
217
  17%|β–ˆβ–‹ | 17/100 [11:16<49:36, 35.86s/trial, best loss: -0.4878]
218
  18%|β–ˆβ–Š | 18/100 [11:59<52:13, 38.21s/trial, best loss: -0.4878]
219
  19%|β–ˆβ–‰ | 19/100 [12:54<58:10, 43.09s/trial, best loss: -0.4878]
220
  20%|β–ˆβ–ˆ | 20/100 [13:18<50:04, 37.56s/trial, best loss: -0.4878]
221
  21%|β–ˆβ–ˆ | 21/100 [14:05<53:03, 40.30s/trial, best loss: -0.4878]
222
  22%|β–ˆβ–ˆβ– | 22/100 [14:40<50:06, 38.54s/trial, best loss: -0.4878]
223
  23%|β–ˆβ–ˆβ–Ž | 23/100 [15:37<56:52, 44.32s/trial, best loss: -0.4878]
224
  24%|β–ˆβ–ˆβ– | 24/100 [16:00<47:53, 37.81s/trial, best loss: -0.4878]
225
  25%|β–ˆβ–ˆβ–Œ | 25/100 [17:12<1:00:06, 48.08s/trial, best loss: -0.4878]
226
  26%|β–ˆβ–ˆβ–Œ | 26/100 [17:39<51:24, 41.69s/trial, best loss: -0.4878]
227
  27%|β–ˆβ–ˆβ–‹ | 27/100 [18:33<55:09, 45.34s/trial, best loss: -0.4878]
228
  28%|β–ˆβ–ˆβ–Š | 28/100 [19:15<53:28, 44.56s/trial, best loss: -0.4878]
229
  29%|β–ˆβ–ˆβ–‰ | 29/100 [19:59<52:25, 44.30s/trial, best loss: -0.4878]
230
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [20:24<44:59, 38.56s/trial, best loss: -0.4878]
231
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [21:21<50:25, 43.84s/trial, best loss: -0.4878]
232
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [22:25<56:51, 50.17s/trial, best loss: -0.4878]
233
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [22:54<48:42, 43.62s/trial, best loss: -0.4878]
234
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [23:21<42:43, 38.84s/trial, best loss: -0.4894]
235
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [23:52<39:29, 36.46s/trial, best loss: -0.4894]
236
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [24:14<34:09, 32.02s/trial, best loss: -0.4894]
237
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [25:02<38:37, 36.79s/trial, best loss: -0.4894]
238
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [25:30<35:24, 34.27s/trial, best loss: -0.4894]
239
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [26:02<34:10, 33.62s/trial, best loss: -0.4894]
240
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [26:31<31:57, 31.97s/trial, best loss: -0.4894]
241
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [27:05<32:16, 32.82s/trial, best loss: -0.4894]
242
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [27:45<33:44, 34.91s/trial, best loss: -0.4894]
243
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [28:17<32:15, 33.95s/trial, best loss: -0.4894]
244
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [28:50<31:28, 33.72s/trial, best loss: -0.4894]
245
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [29:24<30:56, 33.75s/trial, best loss: -0.4894]
246
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [30:01<31:23, 34.88s/trial, best loss: -0.4894]
247
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [30:38<31:23, 35.54s/trial, best loss: -0.4894]
248
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [31:05<28:20, 32.71s/trial, best loss: -0.4894]
249
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [31:46<30:03, 35.36s/trial, best loss: -0.4894]
250
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [32:24<30:08, 36.17s/trial, best loss: -0.4894]
251
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [33:17<33:40, 41.24s/trial, best loss: -0.4894]
252
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [33:40<28:34, 35.72s/trial, best loss: -0.4894]
253
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [34:57<37:33, 47.95s/trial, best loss: -0.4894]
254
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [35:22<31:33, 41.17s/trial, best loss: -0.4894]
255
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [36:12<32:59, 43.98s/trial, best loss: -0.4894]
256
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [36:39<28:21, 38.67s/trial, best loss: -0.4894]
257
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [37:38<32:05, 44.79s/trial, best loss: -0.4894]
258
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [38:18<30:26, 43.49s/trial, best loss: -0.4894]
259
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [38:46<26:35, 38.90s/trial, best loss: -0.4894]
260
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [39:14<23:41, 35.55s/trial, best loss: -0.4894]
261
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [40:09<26:51, 41.32s/trial, best loss: -0.4894]
262
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [40:48<25:48, 40.76s/trial, best loss: -0.4894]
263
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [41:20<23:25, 37.97s/trial, best loss: -0.4894]
264
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆοΏ½οΏ½οΏ½ | 64/100 [41:54<22:03, 36.77s/trial, best loss: -0.4894]
265
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [42:27<20:53, 35.82s/trial, best loss: -0.4894]
266
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [43:12<21:46, 38.42s/trial, best loss: -0.4894]
267
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [43:46<20:25, 37.13s/trial, best loss: -0.4894]
268
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [44:18<19:00, 35.65s/trial, best loss: -0.4894]
269
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [44:52<18:09, 35.16s/trial, best loss: -0.4894]
270
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [45:42<19:50, 39.67s/trial, best loss: -0.4894]
271
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [46:24<19:24, 40.15s/trial, best loss: -0.4894]
272
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [46:52<17:05, 36.63s/trial, best loss: -0.4901]
273
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [47:36<17:26, 38.74s/trial, best loss: -0.4901]
274
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [48:08<15:56, 36.80s/trial, best loss: -0.4901]
275
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [48:34<14:00, 33.61s/trial, best loss: -0.4908]
276
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [49:02<12:44, 31.84s/trial, best loss: -0.4908]
277
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [49:28<11:29, 29.97s/trial, best loss: -0.4908]
278
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [49:52<10:22, 28.28s/trial, best loss: -0.4908]
279
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [50:21<10:01, 28.64s/trial, best loss: -0.4908]
280
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [50:46<09:11, 27.56s/trial, best loss: -0.4908]
281
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [51:16<08:53, 28.06s/trial, best loss: -0.4908]
282
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [51:46<08:36, 28.69s/trial, best loss: -0.4908]
283
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [52:15<08:10, 28.85s/trial, best loss: -0.4908]
284
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [52:46<07:51, 29.44s/trial, best loss: -0.4908]
285
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [53:12<07:08, 28.55s/trial, best loss: -0.4908]
286
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [53:43<06:48, 29.21s/trial, best loss: -0.4908]
287
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [54:08<06:03, 27.99s/trial, best loss: -0.4908]
288
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [54:32<05:20, 26.69s/trial, best loss: -0.4908]
289
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [54:56<04:45, 26.00s/trial, best loss: -0.4908]
290
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [55:31<04:45, 28.51s/trial, best loss: -0.4908]
291
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [56:00<04:20, 28.91s/trial, best loss: -0.4908]
292
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [56:37<04:09, 31.18s/trial, best loss: -0.4908]
293
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [57:05<03:31, 30.15s/trial, best loss: -0.4908]
294
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [57:26<02:44, 27.48s/trial, best loss: -0.4908]
295
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [57:53<02:16, 27.34s/trial, best loss: -0.4908]
296
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [58:28<01:58, 29.56s/trial, best loss: -0.4908]
297
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [58:53<01:24, 28.32s/trial, best loss: -0.4908]
298
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [59:16<00:53, 26.57s/trial, best loss: -0.4908]
299
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [59:58<00:31, 31.41s/trial, best loss: -0.4908]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
300
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
301
  1%| | 1/100 [01:02<1:42:38, 62.20s/trial, best loss: -0.4807]
302
  2%|▏ | 2/100 [01:49<1:27:01, 53.28s/trial, best loss: -0.4841]
303
  3%|β–Ž | 3/100 [02:42<1:25:52, 53.12s/trial, best loss: -0.4848]
304
  4%|▍ | 4/100 [03:15<1:12:13, 45.14s/trial, best loss: -0.4916]
305
  5%|β–Œ | 5/100 [04:13<1:19:05, 49.96s/trial, best loss: -0.4916]
306
  6%|β–Œ | 6/100 [05:10<1:22:01, 52.35s/trial, best loss: -0.4916]
307
  7%|β–‹ | 7/100 [05:34<1:06:33, 42.94s/trial, best loss: -0.4916]
308
  8%|β–Š | 8/100 [06:55<1:24:29, 55.10s/trial, best loss: -0.4916]
309
  9%|β–‰ | 9/100 [07:43<1:20:06, 52.82s/trial, best loss: -0.4916]
310
  10%|β–ˆ | 10/100 [08:33<1:18:03, 52.04s/trial, best loss: -0.4916]
311
  11%|β–ˆ | 11/100 [08:58<1:04:48, 43.69s/trial, best loss: -0.4916]
312
  12%|β–ˆβ– | 12/100 [09:36<1:01:44, 42.09s/trial, best loss: -0.4916]
313
  13%|β–ˆβ–Ž | 13/100 [11:00<1:19:31, 54.85s/trial, best loss: -0.4916]
314
  14%|β–ˆβ– | 14/100 [12:01<1:21:08, 56.61s/trial, best loss: -0.4916]
315
  15%|β–ˆβ–Œ | 15/100 [12:29<1:08:01, 48.02s/trial, best loss: -0.4916]
316
  16%|β–ˆβ–Œ | 16/100 [13:15<1:06:13, 47.30s/trial, best loss: -0.4916]
317
  17%|β–ˆβ–‹ | 17/100 [13:36<54:35, 39.46s/trial, best loss: -0.4916]
318
  18%|β–ˆβ–Š | 18/100 [14:34<1:01:25, 44.94s/trial, best loss: -0.4916]
319
  19%|β–ˆβ–‰ | 19/100 [15:04<54:45, 40.56s/trial, best loss: -0.4916]
320
  20%|β–ˆβ–ˆ | 20/100 [16:14<1:05:52, 49.40s/trial, best loss: -0.4916]
321
  21%|β–ˆβ–ˆ | 21/100 [16:54<1:01:24, 46.64s/trial, best loss: -0.4971]
322
  22%|β–ˆβ–ˆβ– | 22/100 [17:30<56:16, 43.29s/trial, best loss: -0.4971]
323
  23%|β–ˆβ–ˆβ–Ž | 23/100 [18:01<51:01, 39.77s/trial, best loss: -0.4971]
324
  24%|β–ˆβ–ˆβ– | 24/100 [18:33<47:11, 37.25s/trial, best loss: -0.4971]
325
  25%|β–ˆβ–ˆβ–Œ | 25/100 [19:12<47:11, 37.75s/trial, best loss: -0.4971]
326
  26%|β–ˆβ–ˆβ–Œ | 26/100 [19:48<45:54, 37.22s/trial, best loss: -0.4971]
327
  27%|β–ˆβ–ˆβ–‹ | 27/100 [20:30<47:14, 38.83s/trial, best loss: -0.4971]
328
  28%|β–ˆβ–ˆβ–Š | 28/100 [21:01<43:51, 36.55s/trial, best loss: -0.4971]
329
  29%|β–ˆβ–ˆβ–‰ | 29/100 [21:48<47:00, 39.73s/trial, best loss: -0.4971]
330
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [22:23<44:41, 38.30s/trial, best loss: -0.4971]
331
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [22:49<39:43, 34.54s/trial, best loss: -0.4971]
332
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [23:13<35:34, 31.39s/trial, best loss: -0.4971]
333
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [23:34<31:37, 28.32s/trial, best loss: -0.4971]
334
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [24:14<35:00, 31.82s/trial, best loss: -0.4971]
335
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [24:59<38:36, 35.64s/trial, best loss: -0.4971]
336
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [25:35<38:10, 35.80s/trial, best loss: -0.4971]
337
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [26:39<46:25, 44.22s/trial, best loss: -0.4971]
338
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [27:04<39:35, 38.31s/trial, best loss: -0.4971]
339
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [27:38<37:49, 37.20s/trial, best loss: -0.4971]
340
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [28:10<35:45, 35.75s/trial, best loss: -0.4971]
341
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [28:34<31:29, 32.03s/trial, best loss: -0.4971]
342
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [29:01<29:39, 30.67s/trial, best loss: -0.4971]
343
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [29:33<29:29, 31.05s/trial, best loss: -0.4971]
344
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [30:15<32:02, 34.33s/trial, best loss: -0.4971]
345
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [30:46<30:33, 33.34s/trial, best loss: -0.4971]
346
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [31:18<29:33, 32.84s/trial, best loss: -0.4971]
347
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [31:55<30:00, 33.97s/trial, best loss: -0.4971]
348
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [32:40<32:31, 37.52s/trial, best loss: -0.4971]
349
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [33:06<28:58, 34.08s/trial, best loss: -0.4971]
350
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [33:29<25:34, 30.69s/trial, best loss: -0.4971]
351
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [33:54<23:39, 28.96s/trial, best loss: -0.4971]
352
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [34:21<22:42, 28.39s/trial, best loss: -0.4971]
353
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [34:57<23:53, 30.51s/trial, best loss: -0.4971]
354
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [35:35<25:16, 32.96s/trial, best loss: -0.4971]
355
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [36:07<24:24, 32.54s/trial, best loss: -0.4971]
356
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [37:12<31:05, 42.40s/trial, best loss: -0.4971]
357
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [37:49<29:04, 40.57s/trial, best loss: -0.4971]
358
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [38:23<27:06, 38.72s/trial, best loss: -0.4971]
359
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [38:56<25:20, 37.08s/trial, best loss: -0.4971]
360
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [39:30<24:08, 36.22s/trial, best loss: -0.4971]
361
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [40:38<29:41, 45.69s/trial, best loss: -0.4971]
362
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [41:09<26:05, 41.21s/trial, best loss: -0.4971]
363
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [41:45<24:28, 39.69s/trial, best loss: -0.4971]
364
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [42:17<22:26, 37.40s/trial, best loss: -0.4971]
365
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [42:46<20:20, 34.88s/trial, best loss: -0.4971]
366
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [43:19<19:23, 34.21s/trial, best loss: -0.4994]
367
  67%|οΏ½οΏ½οΏ½β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [43:52<18:36, 33.85s/trial, best loss: -0.4994]
368
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [44:26<18:10, 34.08s/trial, best loss: -0.4994]
369
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [45:15<19:46, 38.27s/trial, best loss: -0.4994]
370
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [45:56<19:36, 39.23s/trial, best loss: -0.4994]
371
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [46:41<19:51, 41.09s/trial, best loss: -0.4994]
372
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [47:26<19:44, 42.29s/trial, best loss: -0.4994]
373
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [48:36<22:40, 50.38s/trial, best loss: -0.4994]
374
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [49:12<20:01, 46.21s/trial, best loss: -0.4994]
375
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [49:58<19:11, 46.04s/trial, best loss: -0.4994]
376
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [50:36<17:24, 43.52s/trial, best loss: -0.4994]
377
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [51:07<15:19, 39.98s/trial, best loss: -0.4994]
378
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [52:08<16:54, 46.11s/trial, best loss: -0.4994]
379
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [52:46<15:22, 43.92s/trial, best loss: -0.4994]
380
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [53:27<14:18, 42.91s/trial, best loss: -0.4994]
381
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [53:59<12:33, 39.67s/trial, best loss: -0.4994]
382
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [54:47<12:39, 42.19s/trial, best loss: -0.4994]
383
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [55:36<12:30, 44.15s/trial, best loss: -0.4994]
384
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [56:13<11:10, 41.89s/trial, best loss: -0.4994]
385
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [56:50<10:09, 40.66s/trial, best loss: -0.4994]
386
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [57:41<10:11, 43.69s/trial, best loss: -0.4994]
387
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [58:47<10:54, 50.36s/trial, best loss: -0.4994]
388
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [59:26<09:22, 46.84s/trial, best loss: -0.4994]
389
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [1:00:02<08:02, 43.84s/trial, best loss: -0.4994]
390
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [1:00:31<06:33, 39.38s/trial, best loss: -0.4994]
391
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [1:01:09<05:48, 38.76s/trial, best loss: -0.4994]
392
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [1:01:45<05:04, 38.04s/trial, best loss: -0.4994]
393
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [1:02:39<04:59, 42.76s/trial, best loss: -0.4994]
394
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [1:03:06<03:48, 38.12s/trial, best loss: -0.4994]
395
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [1:03:39<03:02, 36.58s/trial, best loss: -0.4994]
396
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [1:04:16<02:26, 36.56s/trial, best loss: -0.4994]
397
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [1:04:51<01:48, 36.21s/trial, best loss: -0.4994]
398
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [1:05:15<01:05, 32.67s/trial, best loss: -0.4994]
399
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [1:05:43<00:31, 31.21s/trial, best loss: -0.4994]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
400
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
401
  1%| | 1/100 [00:54<1:30:09, 54.64s/trial, best loss: -0.5469]
402
  2%|▏ | 2/100 [01:19<1:00:47, 37.22s/trial, best loss: -0.5519]
403
  3%|β–Ž | 3/100 [01:50<55:12, 34.15s/trial, best loss: -0.5519]
404
  4%|▍ | 4/100 [02:25<55:19, 34.57s/trial, best loss: -0.5519]
405
  5%|β–Œ | 5/100 [03:31<1:12:51, 46.01s/trial, best loss: -0.5557]
406
  6%|οΏ½οΏ½ | 6/100 [04:02<1:03:56, 40.81s/trial, best loss: -0.5557]
407
  7%|β–‹ | 7/100 [04:30<56:42, 36.58s/trial, best loss: -0.5557]
408
  8%|β–Š | 8/100 [05:14<59:48, 39.00s/trial, best loss: -0.5557]
409
  9%|β–‰ | 9/100 [05:44<54:59, 36.26s/trial, best loss: -0.5557]
410
  10%|β–ˆ | 10/100 [06:26<56:54, 37.94s/trial, best loss: -0.5557]
411
  11%|β–ˆ | 11/100 [06:56<52:53, 35.66s/trial, best loss: -0.5557]
412
  12%|β–ˆβ– | 12/100 [08:02<1:05:32, 44.69s/trial, best loss: -0.5557]
413
  13%|β–ˆβ–Ž | 13/100 [08:46<1:04:34, 44.53s/trial, best loss: -0.5557]
414
  14%|β–ˆβ– | 14/100 [09:35<1:05:36, 45.77s/trial, best loss: -0.5557]
415
  15%|β–ˆβ–Œ | 15/100 [10:59<1:21:31, 57.55s/trial, best loss: -0.5557]
416
  16%|β–ˆβ–Œ | 16/100 [11:22<1:05:53, 47.07s/trial, best loss: -0.5557]
417
  17%|β–ˆβ–‹ | 17/100 [12:15<1:07:27, 48.77s/trial, best loss: -0.5557]
418
  18%|β–ˆβ–Š | 18/100 [12:46<59:16, 43.37s/trial, best loss: -0.5557]
419
  19%|β–ˆβ–‰ | 19/100 [13:18<54:13, 40.17s/trial, best loss: -0.5557]
420
  20%|β–ˆβ–ˆ | 20/100 [13:43<47:31, 35.64s/trial, best loss: -0.5557]
421
  21%|β–ˆβ–ˆ | 21/100 [14:13<44:40, 33.93s/trial, best loss: -0.5557]
422
  22%|β–ˆβ–ˆβ– | 22/100 [15:23<58:03, 44.67s/trial, best loss: -0.5557]
423
  23%|β–ˆβ–ˆβ–Ž | 23/100 [15:46<49:03, 38.23s/trial, best loss: -0.5557]
424
  24%|β–ˆβ–ˆβ– | 24/100 [16:16<45:01, 35.55s/trial, best loss: -0.5557]
425
  25%|β–ˆβ–ˆβ–Œ | 25/100 [16:48<43:17, 34.64s/trial, best loss: -0.5557]
426
  26%|β–ˆβ–ˆβ–Œ | 26/100 [17:28<44:29, 36.07s/trial, best loss: -0.5557]
427
  27%|β–ˆβ–ˆβ–‹ | 27/100 [17:55<40:51, 33.59s/trial, best loss: -0.5557]
428
  28%|β–ˆβ–ˆβ–Š | 28/100 [18:25<39:01, 32.52s/trial, best loss: -0.556]
429
  29%|β–ˆβ–ˆβ–‰ | 29/100 [19:42<54:10, 45.78s/trial, best loss: -0.556]
430
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [20:16<49:15, 42.23s/trial, best loss: -0.556]
431
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [20:49<45:25, 39.50s/trial, best loss: -0.556]
432
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [21:32<45:48, 40.41s/trial, best loss: -0.556]
433
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [22:16<46:24, 41.57s/trial, best loss: -0.5567]
434
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [22:57<45:31, 41.39s/trial, best loss: -0.5567]
435
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [23:40<45:17, 41.81s/trial, best loss: -0.5567]
436
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [24:46<52:33, 49.28s/trial, best loss: -0.5567]
437
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [25:24<48:09, 45.86s/trial, best loss: -0.558]
438
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [26:06<46:08, 44.65s/trial, best loss: -0.558]
439
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [26:54<46:31, 45.76s/trial, best loss: -0.558]
440
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [27:40<45:35, 45.60s/trial, best loss: -0.558]
441
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [28:19<42:58, 43.71s/trial, best loss: -0.558]
442
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [29:14<45:34, 47.14s/trial, best loss: -0.558]
443
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [29:56<43:11, 45.47s/trial, best loss: -0.558]
444
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [30:58<47:01, 50.39s/trial, best loss: -0.558]
445
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [31:43<44:47, 48.86s/trial, best loss: -0.558]
446
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [32:39<46:01, 51.15s/trial, best loss: -0.558]
447
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [33:32<45:28, 51.48s/trial, best loss: -0.558]
448
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [34:10<41:20, 47.70s/trial, best loss: -0.558]
449
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [34:49<38:16, 45.04s/trial, best loss: -0.558]
450
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [35:28<35:54, 43.09s/trial, best loss: -0.558]
451
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [36:07<34:20, 42.06s/trial, best loss: -0.558]
452
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [36:43<32:09, 40.19s/trial, best loss: -0.558]
453
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [37:19<30:30, 38.94s/trial, best loss: -0.558]
454
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [37:47<27:17, 35.59s/trial, best loss: -0.558]
455
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [38:19<25:50, 34.45s/trial, best loss: -0.558]
456
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [39:05<27:44, 37.83s/trial, best loss: -0.558]
457
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [39:37<25:53, 36.12s/trial, best loss: -0.558]
458
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [40:15<25:40, 36.67s/trial, best loss: -0.558]
459
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [40:53<25:27, 37.25s/trial, best loss: -0.558]
460
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [41:39<26:29, 39.73s/trial, best loss: -0.558]
461
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [42:12<24:36, 37.85s/trial, best loss: -0.558]
462
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [42:45<22:55, 36.21s/trial, best loss: -0.558]
463
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [43:34<24:41, 40.05s/trial, best loss: -0.558]
464
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [43:56<20:46, 34.61s/trial, best loss: -0.558]
465
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [44:36<21:12, 36.36s/trial, best loss: -0.558]
466
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [45:08<19:49, 34.98s/trial, best loss: -0.558]
467
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [45:36<18:03, 32.83s/trial, best loss: -0.558]
468
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [46:02<16:32, 31.03s/trial, best loss: -0.558]
469
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [46:45<17:48, 34.45s/trial, best loss: -0.5588]
470
  70%|β–ˆβ–ˆβ–ˆοΏ½οΏ½β–ˆβ–ˆβ–ˆ | 70/100 [47:26<18:11, 36.38s/trial, best loss: -0.5588]
471
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [48:08<18:24, 38.10s/trial, best loss: -0.5588]
472
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [48:40<16:57, 36.33s/trial, best loss: -0.5588]
473
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [49:47<20:26, 45.41s/trial, best loss: -0.5588]
474
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [50:25<18:42, 43.17s/trial, best loss: -0.5588]
475
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [51:28<20:32, 49.28s/trial, best loss: -0.5588]
476
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [52:21<20:06, 50.28s/trial, best loss: -0.5588]
477
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [53:03<18:18, 47.74s/trial, best loss: -0.5588]
478
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [53:47<17:11, 46.87s/trial, best loss: -0.5588]
479
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [54:27<15:40, 44.78s/trial, best loss: -0.5588]
480
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [55:22<15:58, 47.90s/trial, best loss: -0.5588]
481
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [55:57<13:54, 43.91s/trial, best loss: -0.5588]
482
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [56:31<12:14, 40.78s/trial, best loss: -0.5588]
483
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [57:01<10:39, 37.63s/trial, best loss: -0.5588]
484
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [57:42<10:18, 38.68s/trial, best loss: -0.5588]
485
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [58:32<10:29, 41.95s/trial, best loss: -0.5588]
486
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [59:09<09:27, 40.52s/trial, best loss: -0.5588]
487
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [59:52<08:58, 41.40s/trial, best loss: -0.5588]
488
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [1:00:15<07:08, 35.74s/trial, best loss: -0.5588]
489
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [1:00:53<06:40, 36.37s/trial, best loss: -0.5588]
490
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [1:01:38<06:30, 39.04s/trial, best loss: -0.5588]
491
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [1:02:20<05:59, 39.93s/trial, best loss: -0.5588]
492
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [1:03:11<05:45, 43.19s/trial, best loss: -0.5592]
493
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [1:04:06<05:27, 46.72s/trial, best loss: -0.5592]
494
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [1:05:23<05:34, 55.81s/trial, best loss: -0.5592]
495
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [1:06:36<05:05, 61.13s/trial, best loss: -0.5592]
496
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [1:07:16<03:39, 54.80s/trial, best loss: -0.5592]
497
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [1:07:55<02:30, 50.12s/trial, best loss: -0.5592]
498
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [1:08:36<01:34, 47.21s/trial, best loss: -0.5592]
499
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [1:09:51<00:55, 55.54s/trial, best loss: -0.5592]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
500
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
501
  1%| | 1/100 [01:13<2:01:00, 73.34s/trial, best loss: -0.5479]
502
  2%|▏ | 2/100 [01:43<1:18:00, 47.76s/trial, best loss: -0.5552]
503
  3%|β–Ž | 3/100 [02:04<57:22, 35.48s/trial, best loss: -0.558]
504
  4%|▍ | 4/100 [03:04<1:12:39, 45.41s/trial, best loss: -0.558]
505
  5%|β–Œ | 5/100 [03:45<1:09:30, 43.90s/trial, best loss: -0.558]
506
  6%|β–Œ | 6/100 [04:11<58:53, 37.59s/trial, best loss: -0.5639]
507
  7%|β–‹ | 7/100 [04:54<1:01:02, 39.38s/trial, best loss: -0.5639]
508
  8%|β–Š | 8/100 [05:50<1:08:46, 44.86s/trial, best loss: -0.5639]
509
  9%|β–‰ | 9/100 [06:40<1:10:17, 46.34s/trial, best loss: -0.5639]
510
  10%|β–ˆ | 10/100 [07:29<1:10:30, 47.01s/trial, best loss: -0.5639]
511
  11%|β–ˆ | 11/100 [08:14<1:08:51, 46.42s/trial, best loss: -0.5639]
512
  12%|β–ˆβ– | 12/100 [08:33<56:03, 38.22s/trial, best loss: -0.5639]
513
  13%|β–ˆβ–Ž | 13/100 [08:57<49:03, 33.84s/trial, best loss: -0.5639]
514
  14%|β–ˆβ– | 14/100 [09:20<43:45, 30.53s/trial, best loss: -0.5639]
515
  15%|β–ˆβ–Œ | 15/100 [09:49<42:37, 30.09s/trial, best loss: -0.5639]
516
  16%|β–ˆβ–Œ | 16/100 [11:05<1:01:44, 44.10s/trial, best loss: -0.5639]
517
  17%|β–ˆβ–‹ | 17/100 [11:51<1:01:40, 44.58s/trial, best loss: -0.5639]
518
  18%|β–ˆβ–Š | 18/100 [12:21<55:03, 40.28s/trial, best loss: -0.5639]
519
  19%|β–ˆβ–‰ | 19/100 [12:46<47:51, 35.45s/trial, best loss: -0.5639]
520
  20%|β–ˆβ–ˆ | 20/100 [13:30<50:43, 38.05s/trial, best loss: -0.5639]
521
  21%|β–ˆβ–ˆ | 21/100 [13:54<44:35, 33.86s/trial, best loss: -0.5639]
522
  22%|β–ˆβ–ˆβ– | 22/100 [14:21<41:16, 31.75s/trial, best loss: -0.5639]
523
  23%|β–ˆβ–ˆβ–Ž | 23/100 [14:43<37:04, 28.89s/trial, best loss: -0.5639]
524
  24%|β–ˆβ–ˆβ– | 24/100 [15:09<35:34, 28.08s/trial, best loss: -0.5639]
525
  25%|β–ˆβ–ˆβ–Œ | 25/100 [15:31<32:49, 26.26s/trial, best loss: -0.5639]
526
  26%|β–ˆβ–ˆβ–Œ | 26/100 [15:54<31:08, 25.25s/trial, best loss: -0.5639]
527
  27%|β–ˆβ–ˆβ–‹ | 27/100 [16:19<30:45, 25.28s/trial, best loss: -0.5639]
528
  28%|β–ˆβ–ˆβ–Š | 28/100 [16:46<30:58, 25.81s/trial, best loss: -0.5639]
529
  29%|β–ˆβ–ˆβ–‰ | 29/100 [17:08<28:59, 24.51s/trial, best loss: -0.5639]
530
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [17:43<32:21, 27.74s/trial, best loss: -0.5639]
531
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [18:09<31:10, 27.11s/trial, best loss: -0.5639]
532
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [18:37<31:01, 27.38s/trial, best loss: -0.5639]
533
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [19:01<29:22, 26.31s/trial, best loss: -0.5639]
534
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [19:30<30:00, 27.28s/trial, best loss: -0.5639]
535
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [19:58<29:44, 27.46s/trial, best loss: -0.5639]
536
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [20:22<28:19, 26.55s/trial, best loss: -0.5639]
537
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [21:29<40:25, 38.50s/trial, best loss: -0.5639]
538
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [21:51<34:50, 33.72s/trial, best loss: -0.5639]
539
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [22:17<31:58, 31.44s/trial, best loss: -0.5639]
540
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [22:41<28:57, 28.96s/trial, best loss: -0.5639]
541
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [23:15<30:07, 30.63s/trial, best loss: -0.5639]
542
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [23:39<27:46, 28.74s/trial, best loss: -0.5639]
543
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [24:00<25:01, 26.34s/trial, best loss: -0.5639]
544
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [24:27<24:44, 26.51s/trial, best loss: -0.5639]
545
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [25:06<27:45, 30.28s/trial, best loss: -0.5639]
546
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [26:00<33:30, 37.23s/trial, best loss: -0.5639]
547
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [26:37<32:59, 37.35s/trial, best loss: -0.5639]
548
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [27:20<33:53, 39.11s/trial, best loss: -0.5639]
549
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [28:20<38:25, 45.22s/trial, best loss: -0.5639]
550
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [28:53<34:36, 41.53s/trial, best loss: -0.5639]
551
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [29:31<32:57, 40.36s/trial, best loss: -0.5639]
552
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [30:14<32:59, 41.23s/trial, best loss: -0.5639]
553
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [30:47<30:18, 38.70s/trial, best loss: -0.5639]
554
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [31:18<28:03, 36.61s/trial, best loss: -0.5639]
555
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [31:49<26:11, 34.93s/trial, best loss: -0.5639]
556
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [32:46<30:26, 41.51s/trial, best loss: -0.5639]
557
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [33:33<30:59, 43.25s/trial, best loss: -0.5639]
558
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [34:05<27:50, 39.78s/trial, best loss: -0.5639]
559
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [34:53<28:45, 42.09s/trial, best loss: -0.5639]
560
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [35:17<24:35, 36.90s/trial, best loss: -0.5639]
561
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [35:44<22:03, 33.93s/trial, best loss: -0.5639]
562
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [36:08<19:31, 30.83s/trial, best loss: -0.5639]
563
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [36:36<18:26, 29.91s/trial, best loss: -0.5639]
564
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [36:56<16:16, 27.13s/trial, best loss: -0.5639]
565
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [37:22<15:30, 26.57s/trial, best loss: -0.5639]
566
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [37:54<16:05, 28.41s/trial, best loss: -0.5655]
567
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [38:28<16:32, 30.06s/trial, best loss: -0.5655]
568
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [39:05<17:07, 32.12s/trial, best loss: -0.5655]
569
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [39:35<16:15, 31.48s/trial, best loss: -0.5655]
570
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [40:17<17:17, 34.58s/trial, best loss: -0.5655]
571
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [40:41<15:13, 31.49s/trial, best loss: -0.5655]
572
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [41:26<16:34, 35.53s/trial, best loss: -0.5655]
573
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [41:53<14:51, 33.02s/trial, best loss: -0.5655]
574
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [42:31<14:57, 34.53s/trial, best loss: -0.5655]
575
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [43:02<13:50, 33.22s/trial, best loss: -0.5655]
576
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [43:46<14:37, 36.58s/trial, best loss: -0.5655]
577
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [44:15<13:06, 34.20s/trial, best loss: -0.5655]
578
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [44:47<12:22, 33.75s/trial, best loss: -0.5655]
579
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [45:17<11:20, 32.40s/trial, best loss: -0.5655]
580
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [45:48<10:41, 32.08s/trial, best loss: -0.5655]
581
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [46:27<10:47, 34.07s/trial, best loss: -0.5655]
582
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [47:05<10:36, 35.34s/trial, best loss: -0.5655]
583
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [47:37<09:44, 34.37s/trial, best loss: -0.5655]
584
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [48:20<09:50, 36.90s/trial, best loss: -0.5655]
585
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [48:51<08:46, 35.11s/trial, best loss: -0.5655]
586
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [49:25<08:06, 34.73s/trial, best loss: -0.5655]
587
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [49:56<07:16, 33.56s/trial, best loss: -0.5655]
588
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [50:33<06:56, 34.70s/trial, best loss: -0.566]
589
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [51:19<06:57, 37.99s/trial, best loss: -0.566]
590
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [51:54<06:10, 37.08s/trial, best loss: -0.566]
591
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [52:47<06:18, 42.10s/trial, best loss: -0.566]
592
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [53:24<05:23, 40.43s/trial, best loss: -0.5671]
593
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [54:01<04:36, 39.53s/trial, best loss: -0.5671]
594
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [54:56<04:24, 44.12s/trial, best loss: -0.5671]
595
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [55:34<03:31, 42.24s/trial, best loss: -0.5671]
596
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [56:12<02:43, 40.95s/trial, best loss: -0.5671]
597
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [56:56<02:05, 41.79s/trial, best loss: -0.5671]
598
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [57:43<01:26, 43.42s/trial, best loss: -0.5671]
599
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [58:35<00:45, 45.96s/trial, best loss: -0.5671]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ nohup: ignoring input
2
+ /bin/bash: /opt/conda/lib/libtinfo.so.6: no version information available (required by /bin/bash)
3
+ ==========================================
4
+ LGB CTGAN10000 파일 μ‹€ν–‰ μ‹œμž‘
5
+ μ‹œμž‘ μ‹œκ°„: 2025-12-28 04:29:39
6
+ GPU: 1번 (CUDA_VISIBLE_DEVICES=1)
7
+ ==========================================
8
+
9
+ ----------------------------------------
10
+ μ‹€ν–‰ 쀑: lgb_ctgan10000/LGB_ctgan10000_busan.py
11
+ μ‹œμž‘ μ‹œκ°„: 2025-12-28 04:29:39
12
+ ----------------------------------------
13
+ 데이터 λ‘œλ”© 쀑...
14
+ 데이터 μ „μ²˜λ¦¬ 쀑...
15
+ ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...
16
+
17
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
18
  1%| | 1/100 [01:04<1:47:14, 65.00s/trial, best loss: -0.4238]
19
  2%|▏ | 2/100 [01:54<1:31:25, 55.98s/trial, best loss: -0.4576]
20
  3%|β–Ž | 3/100 [02:31<1:16:36, 47.39s/trial, best loss: -0.4733]
21
  4%|▍ | 4/100 [03:21<1:17:24, 48.38s/trial, best loss: -0.4758]
22
  5%|β–Œ | 5/100 [04:00<1:10:52, 44.77s/trial, best loss: -0.4758]
23
  6%|β–Œ | 6/100 [04:24<59:01, 37.68s/trial, best loss: -0.4758]
24
  7%|β–‹ | 7/100 [04:54<54:54, 35.42s/trial, best loss: -0.4758]
25
  8%|β–Š | 8/100 [05:41<59:49, 39.02s/trial, best loss: -0.4758]
26
  9%|β–‰ | 9/100 [06:04<51:22, 33.87s/trial, best loss: -0.4758]
27
  10%|β–ˆ | 10/100 [06:52<57:39, 38.44s/trial, best loss: -0.4758]
28
  11%|β–ˆ | 11/100 [07:30<56:39, 38.20s/trial, best loss: -0.4835]
29
  12%|β–ˆβ– | 12/100 [08:01<52:39, 35.90s/trial, best loss: -0.4835]
30
  13%|β–ˆβ–Ž | 13/100 [08:23<46:16, 31.91s/trial, best loss: -0.4835]
31
  14%|β–ˆβ– | 14/100 [08:46<41:36, 29.03s/trial, best loss: -0.4835]
32
  15%|β–ˆβ–Œ | 15/100 [09:24<44:58, 31.74s/trial, best loss: -0.4835]
33
  16%|β–ˆβ–Œ | 16/100 [10:12<51:30, 36.80s/trial, best loss: -0.4835]
34
  17%|β–ˆβ–‹ | 17/100 [10:47<50:13, 36.30s/trial, best loss: -0.4835]
35
  18%|β–ˆβ–Š | 18/100 [11:15<46:03, 33.70s/trial, best loss: -0.4835]
36
  19%|β–ˆβ–‰ | 19/100 [11:52<46:41, 34.58s/trial, best loss: -0.4835]
37
  20%|β–ˆβ–ˆ | 20/100 [12:13<40:56, 30.71s/trial, best loss: -0.4835]
38
  21%|β–ˆβ–ˆ | 21/100 [12:44<40:26, 30.71s/trial, best loss: -0.4835]
39
  22%|β–ˆβ–ˆβ– | 22/100 [13:14<39:43, 30.56s/trial, best loss: -0.4836]
40
  23%|β–ˆβ–ˆβ–Ž | 23/100 [13:40<37:14, 29.02s/trial, best loss: -0.4836]
41
  24%|β–ˆβ–ˆβ– | 24/100 [14:23<42:05, 33.24s/trial, best loss: -0.4836]
42
  25%|β–ˆβ–ˆβ–Œ | 25/100 [14:53<40:20, 32.27s/trial, best loss: -0.4836]
43
  26%|β–ˆβ–ˆβ–Œ | 26/100 [15:18<37:18, 30.25s/trial, best loss: -0.4836]
44
  27%|β–ˆβ–ˆβ–‹ | 27/100 [15:47<36:22, 29.90s/trial, best loss: -0.4836]
45
  28%|β–ˆβ–ˆβ–Š | 28/100 [16:40<44:02, 36.70s/trial, best loss: -0.4836]
46
  29%|β–ˆβ–ˆβ–‰ | 29/100 [17:20<44:27, 37.57s/trial, best loss: -0.4836]
47
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [18:02<45:34, 39.06s/trial, best loss: -0.4836]
48
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [18:26<39:34, 34.42s/trial, best loss: -0.4836]
49
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [19:00<39:06, 34.51s/trial, best loss: -0.4836]
50
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [19:37<39:24, 35.29s/trial, best loss: -0.4836]
51
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [20:20<41:17, 37.54s/trial, best loss: -0.4836]
52
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [20:46<36:49, 33.99s/trial, best loss: -0.4836]
53
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [21:42<43:21, 40.65s/trial, best loss: -0.4836]
54
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [22:19<41:21, 39.38s/trial, best loss: -0.4836]
55
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [23:07<43:38, 42.23s/trial, best loss: -0.4836]
56
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [23:30<36:47, 36.19s/trial, best loss: -0.4836]
57
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [24:00<34:29, 34.49s/trial, best loss: -0.4836]
58
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [24:30<32:32, 33.10s/trial, best loss: -0.4836]
59
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [24:56<29:53, 30.93s/trial, best loss: -0.4836]
60
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [25:27<29:21, 30.90s/trial, best loss: -0.4836]
61
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [25:50<26:44, 28.65s/trial, best loss: -0.4836]
62
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [26:40<32:11, 35.13s/trial, best loss: -0.4836]
63
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [27:16<31:53, 35.43s/trial, best loss: -0.4836]
64
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [27:57<32:41, 37.01s/trial, best loss: -0.4836]
65
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [28:48<35:47, 41.30s/trial, best loss: -0.4836]
66
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [29:27<34:26, 40.53s/trial, best loss: -0.4836]
67
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [29:54<30:25, 36.51s/trial, best loss: -0.4836]
68
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [30:53<35:10, 43.06s/trial, best loss: -0.4836]
69
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [31:20<30:35, 38.24s/trial, best loss: -0.4836]
70
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [31:53<28:54, 36.90s/trial, best loss: -0.4836]
71
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [33:09<37:07, 48.43s/trial, best loss: -0.4836]
72
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [33:34<31:10, 41.56s/trial, best loss: -0.4836]
73
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [33:56<26:01, 35.48s/trial, best loss: -0.4836]
74
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [34:25<24:02, 33.54s/trial, best loss: -0.4836]
75
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [35:00<23:51, 34.09s/trial, best loss: -0.4836]
76
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [35:53<27:15, 39.88s/trial, best loss: -0.4836]
77
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [36:31<26:10, 39.26s/trial, best loss: -0.4836]
78
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [36:57<22:56, 35.30s/trial, best loss: -0.4836]
79
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [37:32<22:11, 35.04s/trial, best loss: -0.4836]
80
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [37:57<19:47, 32.11s/trial, best loss: -0.4836]
81
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [38:23<18:11, 30.33s/trial, best loss: -0.4836]
82
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [39:08<20:11, 34.62s/trial, best loss: -0.4836]
83
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [39:40<19:14, 33.96s/trial, best loss: -0.4836]
84
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [40:11<18:06, 32.93s/trial, best loss: -0.4836]
85
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [40:36<16:23, 30.74s/trial, best loss: -0.4836]
86
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [41:04<15:20, 29.70s/trial, best loss: -0.4836]
87
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [41:31<14:34, 29.15s/trial, best loss: -0.4836]
88
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [41:55<13:17, 27.51s/trial, best loss: -0.4836]
89
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [42:36<14:45, 31.64s/trial, best loss: -0.4836]
90
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [43:06<13:58, 31.06s/trial, best loss: -0.4836]
91
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [43:34<12:59, 29.97s/trial, best loss: -0.4836]
92
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [44:05<12:43, 30.53s/trial, best loss: -0.4836]
93
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [44:46<13:24, 33.52s/trial, best loss: -0.4836]
94
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [45:22<13:09, 34.35s/trial, best loss: -0.4836]
95
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [45:53<12:11, 33.24s/trial, best loss: -0.4836]
96
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [46:20<10:58, 31.38s/trial, best loss: -0.4836]
97
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [46:45<09:51, 29.59s/trial, best loss: -0.4836]
98
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [47:20<09:53, 31.23s/trial, best loss: -0.4836]
99
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [47:51<09:19, 31.11s/trial, best loss: -0.4836]
100
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [48:23<08:55, 31.49s/trial, best loss: -0.4836]
101
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [49:06<09:14, 34.66s/trial, best loss: -0.4836]
102
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [49:31<07:59, 31.94s/trial, best loss: -0.4836]
103
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [50:18<08:28, 36.32s/trial, best loss: -0.4836]
104
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [51:01<08:20, 38.50s/trial, best loss: -0.4836]
105
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [52:08<09:24, 47.02s/trial, best loss: -0.4836]
106
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [52:57<08:43, 47.60s/trial, best loss: -0.4836]
107
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [53:37<07:31, 45.17s/trial, best loss: -0.4836]
108
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [54:28<07:04, 47.18s/trial, best loss: -0.4836]
109
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [55:14<06:13, 46.70s/trial, best loss: -0.4836]
110
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [56:21<06:08, 52.71s/trial, best loss: -0.4836]
111
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [57:02<04:55, 49.27s/trial, best loss: -0.4836]
112
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [57:39<03:48, 45.62s/trial, best loss: -0.4836]
113
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [58:33<03:12, 48.15s/trial, best loss: -0.4836]
114
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [59:14<02:17, 45.95s/trial, best loss: -0.4836]
115
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [59:54<01:28, 44.22s/trial, best loss: -0.4836]
116
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [1:00:48<00:47, 47.12s/trial, best loss: -0.4836]
117
+
118
+ μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {'colsample_bytree': 0.7243835590014314, 'learning_rate': 0.052472053724070156, 'max_depth': 15.0, 'min_child_weight': 9.0, 'num_leaves': 120.0, 'reg_alpha': 0.566895668532905, 'reg_lambda': 0.9659771198744264, 'subsample': 0.8425484904296862}
119
+ 졜적 CSI 점수: 0.4836 (loss: -0.4836)
120
+
121
+ μ΅œμ ν™” κ³Όμ • μš”μ•½:
122
+ - 총 μ‹œλ„ 횟수: 100
123
+ - μ„±κ³΅ν•œ μ‹œλ„: 100
124
+ - 졜초 CSI: 0.4238
125
+ - μ΅œμ’… CSI: 0.4676
126
+ - 졜고 CSI: 0.4836
127
+ - μ΅œμ € CSI: 0.4200
128
+ - 평균 CSI: 0.4700
129
+
130
+ μ΅œμ ν™” Trials 객체가 /workspace/visibility_prediction/Analysis_code/optimization_history/lgb_ctgan10000_busan_trials.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
131
+ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...
132
+ Fold 1 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2019], 검증 연도: 2020)
133
+ Fold 1 검증 CSI: 0.3905
134
+ Fold 2 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2020], 검증 연도: 2019)
135
+ Fold 2 검증 CSI: 0.5044
136
+ Fold 3 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2019, 2020], 검증 연도: 2018)
137
+ Fold 3 검증 CSI: 0.4985
138
+ λͺ¨λΈ μ €μž₯ 쀑...
139
+ λͺ¨λΈμ΄ /workspace/visibility_prediction/Analysis_code/save_model/lgb_optima/lgb_ctgan10000_busan.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
140
+
141
+ βœ“ μ™„λ£Œ: lgb_ctgan10000/LGB_ctgan10000_busan.py (μ†Œμš” μ‹œκ°„: 3720초)
142
+
143
+ ----------------------------------------
144
+ μ‹€ν–‰ 쀑: lgb_ctgan10000/LGB_ctgan10000_daegu.py
145
+ μ‹œμž‘ μ‹œκ°„: 2025-12-28 05:31:39
146
+ ----------------------------------------
147
+ 데이터 λ‘œλ”© 쀑...
148
+ 데이터 μ „μ²˜λ¦¬ 쀑...
149
+ ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...
150
+
151
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
152
  1%| | 1/100 [00:18<31:06, 18.85s/trial, best loss: -0.3977]
153
  2%|▏ | 2/100 [00:59<52:04, 31.88s/trial, best loss: -0.4107]
154
  3%|β–Ž | 3/100 [01:25<46:42, 28.89s/trial, best loss: -0.4107]
155
  4%|▍ | 4/100 [02:15<59:36, 37.25s/trial, best loss: -0.4107]
156
  5%|β–Œ | 5/100 [02:48<56:54, 35.94s/trial, best loss: -0.4107]
157
  6%|β–Œ | 6/100 [03:16<52:00, 33.20s/trial, best loss: -0.4107]
158
  7%|β–‹ | 7/100 [04:01<57:30, 37.10s/trial, best loss: -0.4107]
159
  8%|β–Š | 8/100 [04:43<58:56, 38.44s/trial, best loss: -0.4107]
160
  9%|β–‰ | 9/100 [05:10<52:53, 34.88s/trial, best loss: -0.4107]
161
  10%|β–ˆ | 10/100 [05:34<47:28, 31.65s/trial, best loss: -0.4107]
162
  11%|β–ˆ | 11/100 [06:25<55:28, 37.39s/trial, best loss: -0.4107]
163
  12%|β–ˆβ– | 12/100 [06:52<50:33, 34.47s/trial, best loss: -0.4107]
164
  13%|β–ˆβ–Ž | 13/100 [07:15<44:44, 30.85s/trial, best loss: -0.4155]
165
  14%|β–ˆβ– | 14/100 [07:47<44:52, 31.31s/trial, best loss: -0.4155]
166
  15%|β–ˆβ–Œ | 15/100 [08:10<40:45, 28.77s/trial, best loss: -0.4161]
167
  16%|β–ˆβ–Œ | 16/100 [08:33<37:35, 26.85s/trial, best loss: -0.4161]
168
  17%|β–ˆβ–‹ | 17/100 [09:15<43:36, 31.53s/trial, best loss: -0.4161]
169
  18%|β–ˆβ–Š | 18/100 [09:51<45:05, 32.99s/trial, best loss: -0.4161]
170
  19%|β–ˆβ–‰ | 19/100 [10:14<40:11, 29.77s/trial, best loss: -0.4161]
171
  20%|β–ˆβ–ˆ | 20/100 [11:04<48:02, 36.03s/trial, best loss: -0.4161]
172
  21%|β–ˆβ–ˆ | 21/100 [11:25<41:14, 31.32s/trial, best loss: -0.4203]
173
  22%|β–ˆβ–ˆβ– | 22/100 [11:51<38:51, 29.89s/trial, best loss: -0.4203]
174
  23%|β–ˆβ–ˆβ–Ž | 23/100 [12:16<36:18, 28.29s/trial, best loss: -0.4203]
175
  24%|β–ˆβ–ˆβ– | 24/100 [12:42<35:07, 27.72s/trial, best loss: -0.4203]
176
  25%|β–ˆβ–ˆβ–Œ | 25/100 [13:04<32:21, 25.88s/trial, best loss: -0.4203]
177
  26%|β–ˆβ–ˆβ–Œ | 26/100 [13:25<30:16, 24.54s/trial, best loss: -0.4203]
178
  27%|β–ˆβ–ˆβ–‹ | 27/100 [13:46<28:42, 23.60s/trial, best loss: -0.4203]
179
  28%|β–ˆβ–ˆβ–Š | 28/100 [14:08<27:40, 23.06s/trial, best loss: -0.4203]
180
  29%|β–ˆβ–ˆβ–‰ | 29/100 [14:33<27:46, 23.47s/trial, best loss: -0.4203]
181
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [14:53<26:12, 22.46s/trial, best loss: -0.4207]
182
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [15:14<25:33, 22.22s/trial, best loss: -0.4254]
183
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [15:36<24:48, 21.90s/trial, best loss: -0.4254]
184
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [15:57<24:20, 21.80s/trial, best loss: -0.4254]
185
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [16:19<23:58, 21.79s/trial, best loss: -0.4254]
186
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [16:47<25:30, 23.55s/trial, best loss: -0.4254]
187
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [17:12<25:35, 24.00s/trial, best loss: -0.4254]
188
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [17:34<24:35, 23.42s/trial, best loss: -0.4254]
189
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [18:02<25:41, 24.86s/trial, best loss: -0.4254]
190
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [18:24<24:19, 23.93s/trial, best loss: -0.4254]
191
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [18:50<24:31, 24.52s/trial, best loss: -0.4254]
192
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [19:17<25:04, 25.51s/trial, best loss: -0.4254]
193
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [19:50<26:51, 27.78s/trial, best loss: -0.4254]
194
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [20:16<25:36, 26.96s/trial, best loss: -0.4254]
195
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [20:49<27:04, 29.00s/trial, best loss: -0.4254]
196
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [21:07<23:36, 25.75s/trial, best loss: -0.4254]
197
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [21:26<21:14, 23.60s/trial, best loss: -0.4254]
198
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [21:49<20:41, 23.42s/trial, best loss: -0.4254]
199
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [22:09<19:27, 22.45s/trial, best loss: -0.4254]
200
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [23:08<28:18, 33.30s/trial, best loss: -0.4254]
201
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [23:33<25:45, 30.90s/trial, best loss: -0.4254]
202
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [23:54<22:51, 27.99s/trial, best loss: -0.4254]
203
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [24:46<28:08, 35.17s/trial, best loss: -0.4255]
204
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [25:19<26:54, 34.35s/trial, best loss: -0.4255]
205
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [26:00<27:54, 36.41s/trial, best loss: -0.4255]
206
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [26:52<30:51, 41.14s/trial, best loss: -0.4255]
207
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [27:21<27:32, 37.55s/trial, best loss: -0.4255]
208
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [27:54<25:48, 36.01s/trial, best loss: -0.4255]
209
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [28:38<27:00, 38.59s/trial, best loss: -0.4308]
210
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [29:22<27:21, 40.03s/trial, best loss: -0.4308]
211
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [29:55<25:16, 37.92s/trial, best loss: -0.4308]
212
  61%|β–ˆβ–ˆοΏ½οΏ½β–ˆβ–ˆβ–ˆ | 61/100 [30:42<26:27, 40.70s/trial, best loss: -0.4308]
213
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [31:22<25:35, 40.40s/trial, best loss: -0.4308]
214
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [32:08<26:04, 42.29s/trial, best loss: -0.4308]
215
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [32:58<26:41, 44.49s/trial, best loss: -0.4308]
216
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [33:35<24:39, 42.28s/trial, best loss: -0.4308]
217
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [34:26<25:30, 45.01s/trial, best loss: -0.4308]
218
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [35:12<24:52, 45.21s/trial, best loss: -0.4308]
219
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [36:03<25:03, 47.00s/trial, best loss: -0.4308]
220
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [36:49<24:05, 46.63s/trial, best loss: -0.4308]
221
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [37:31<22:40, 45.35s/trial, best loss: -0.4308]
222
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [38:07<20:28, 42.35s/trial, best loss: -0.4308]
223
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [38:45<19:12, 41.15s/trial, best loss: -0.4308]
224
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [39:21<17:45, 39.48s/trial, best loss: -0.4308]
225
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [39:55<16:22, 37.80s/trial, best loss: -0.4308]
226
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [40:30<15:26, 37.07s/trial, best loss: -0.4308]
227
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [41:12<15:22, 38.43s/trial, best loss: -0.4308]
228
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [41:43<13:55, 36.31s/trial, best loss: -0.4308]
229
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [42:09<12:10, 33.21s/trial, best loss: -0.4308]
230
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [42:37<11:02, 31.57s/trial, best loss: -0.4308]
231
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [43:10<10:44, 32.23s/trial, best loss: -0.4308]
232
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [43:46<10:28, 33.10s/trial, best loss: -0.4308]
233
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [44:40<11:49, 39.44s/trial, best loss: -0.4317]
234
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [45:16<10:55, 38.57s/trial, best loss: -0.4317]
235
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [46:07<11:13, 42.10s/trial, best loss: -0.4317]
236
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [47:05<11:43, 46.91s/trial, best loss: -0.4317]
237
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [47:54<11:05, 47.51s/trial, best loss: -0.4317]
238
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [48:33<09:44, 44.98s/trial, best loss: -0.4317]
239
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [48:57<07:46, 38.87s/trial, best loss: -0.4317]
240
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [49:25<06:31, 35.56s/trial, best loss: -0.4317]
241
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [50:23<07:01, 42.18s/trial, best loss: -0.4339]
242
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [51:11<06:35, 43.97s/trial, best loss: -0.4339]
243
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [52:08<06:21, 47.75s/trial, best loss: -0.4339]
244
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [52:49<05:21, 45.99s/trial, best loss: -0.4339]
245
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [53:41<04:45, 47.66s/trial, best loss: -0.4339]
246
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [54:27<03:56, 47.24s/trial, best loss: -0.4339]
247
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [55:20<03:14, 48.75s/trial, best loss: -0.4339]
248
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [55:47<02:06, 42.27s/trial, best loss: -0.4339]
249
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [56:52<01:38, 49.05s/trial, best loss: -0.4339]
250
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [57:25<00:44, 44.40s/trial, best loss: -0.4339]
251
+
252
+ μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {'colsample_bytree': 0.885595994008888, 'learning_rate': 0.010106842270671093, 'max_depth': 14.0, 'min_child_weight': 1.0, 'num_leaves': 122.0, 'reg_alpha': 0.12648188723964116, 'reg_lambda': 0.873682924904797, 'subsample': 0.7806598236159817}
253
+ 졜적 CSI 점수: 0.4339 (loss: -0.4339)
254
+
255
+ μ΅œμ ν™” κ³Όμ • μš”μ•½:
256
+ - 총 μ‹œλ„ 횟수: 100
257
+ - μ„±κ³΅ν•œ μ‹œλ„: 100
258
+ - 졜초 CSI: 0.3977
259
+ - μ΅œμ’… CSI: 0.3974
260
+ - 졜고 CSI: 0.4339
261
+ - μ΅œμ € CSI: 0.3802
262
+ - 평균 CSI: 0.4106
263
+
264
+ μ΅œμ ν™” Trials 객체가 /workspace/visibility_prediction/Analysis_code/optimization_history/lgb_ctgan10000_daegu_trials.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
265
+ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...
266
+ Fold 1 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2019], 검증 연도: 2020)
267
+ Fold 1 검증 CSI: 0.4293
268
+ Fold 2 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2020], 검증 연도: 2019)
269
+ Fold 2 검증 CSI: 0.4656
270
+ Fold 3 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2019, 2020], 검증 연도: 2018)
271
+ Fold 3 검증 CSI: 0.3270
272
+ λͺ¨λΈ μ €μž₯ 쀑...
273
+ λͺ¨λΈμ΄ /workspace/visibility_prediction/Analysis_code/save_model/lgb_optima/lgb_ctgan10000_daegu.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
274
+
275
+ βœ“ μ™„λ£Œ: lgb_ctgan10000/LGB_ctgan10000_daegu.py (μ†Œμš” μ‹œκ°„: 3538초)
276
+
277
+ ----------------------------------------
278
+ μ‹€ν–‰ 쀑: lgb_ctgan10000/LGB_ctgan10000_daejeon.py
279
+ μ‹œμž‘ μ‹œκ°„: 2025-12-28 06:30:37
280
+ ----------------------------------------
281
+ 데이터 λ‘œλ”© 쀑...
282
+ 데이터 μ „μ²˜λ¦¬ 쀑...
283
+ ν•˜οΏ½οΏ½νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...
284
+
285
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
286
  1%| | 1/100 [00:28<47:17, 28.66s/trial, best loss: -0.4792]
287
  2%|▏ | 2/100 [01:38<1:25:59, 52.65s/trial, best loss: -0.4833]
288
  3%|β–Ž | 3/100 [02:12<1:11:30, 44.23s/trial, best loss: -0.4833]
289
  4%|▍ | 4/100 [02:44<1:02:52, 39.29s/trial, best loss: -0.4833]
290
  5%|β–Œ | 5/100 [03:08<53:32, 33.81s/trial, best loss: -0.4833]
291
  6%|β–Œ | 6/100 [03:41<52:46, 33.68s/trial, best loss: -0.4833]
292
  7%|β–‹ | 7/100 [04:23<56:25, 36.40s/trial, best loss: -0.4833]
293
  8%|β–Š | 8/100 [05:32<1:11:34, 46.68s/trial, best loss: -0.4833]
294
  9%|β–‰ | 9/100 [06:02<1:02:47, 41.41s/trial, best loss: -0.4864]
295
  10%|β–ˆ | 10/100 [07:04<1:12:04, 48.05s/trial, best loss: -0.4864]
296
  11%|β–ˆ | 11/100 [07:31<1:01:24, 41.40s/trial, best loss: -0.4864]
297
  12%|β–ˆβ– | 12/100 [07:54<52:32, 35.82s/trial, best loss: -0.4864]
298
  13%|β–ˆβ–Ž | 13/100 [09:06<1:07:45, 46.72s/trial, best loss: -0.4878]
299
  14%|β–ˆβ– | 14/100 [09:35<59:23, 41.44s/trial, best loss: -0.4878]
300
  15%|β–ˆβ–Œ | 15/100 [10:15<58:02, 40.98s/trial, best loss: -0.4878]
301
  16%|β–ˆβ–Œ | 16/100 [10:42<51:40, 36.91s/trial, best loss: -0.4878]
302
  17%|β–ˆβ–‹ | 17/100 [11:16<49:36, 35.86s/trial, best loss: -0.4878]
303
  18%|β–ˆβ–Š | 18/100 [11:59<52:13, 38.21s/trial, best loss: -0.4878]
304
  19%|β–ˆβ–‰ | 19/100 [12:54<58:10, 43.09s/trial, best loss: -0.4878]
305
  20%|β–ˆβ–ˆ | 20/100 [13:18<50:04, 37.56s/trial, best loss: -0.4878]
306
  21%|β–ˆβ–ˆ | 21/100 [14:05<53:03, 40.30s/trial, best loss: -0.4878]
307
  22%|β–ˆβ–ˆβ– | 22/100 [14:40<50:06, 38.54s/trial, best loss: -0.4878]
308
  23%|β–ˆβ–ˆβ–Ž | 23/100 [15:37<56:52, 44.32s/trial, best loss: -0.4878]
309
  24%|β–ˆβ–ˆβ– | 24/100 [16:00<47:53, 37.81s/trial, best loss: -0.4878]
310
  25%|β–ˆβ–ˆβ–Œ | 25/100 [17:12<1:00:06, 48.08s/trial, best loss: -0.4878]
311
  26%|β–ˆβ–ˆβ–Œ | 26/100 [17:39<51:24, 41.69s/trial, best loss: -0.4878]
312
  27%|β–ˆβ–ˆβ–‹ | 27/100 [18:33<55:09, 45.34s/trial, best loss: -0.4878]
313
  28%|β–ˆβ–ˆβ–Š | 28/100 [19:15<53:28, 44.56s/trial, best loss: -0.4878]
314
  29%|β–ˆβ–ˆβ–‰ | 29/100 [19:59<52:25, 44.30s/trial, best loss: -0.4878]
315
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [20:24<44:59, 38.56s/trial, best loss: -0.4878]
316
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [21:21<50:25, 43.84s/trial, best loss: -0.4878]
317
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [22:25<56:51, 50.17s/trial, best loss: -0.4878]
318
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [22:54<48:42, 43.62s/trial, best loss: -0.4878]
319
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [23:21<42:43, 38.84s/trial, best loss: -0.4894]
320
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [23:52<39:29, 36.46s/trial, best loss: -0.4894]
321
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [24:14<34:09, 32.02s/trial, best loss: -0.4894]
322
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [25:02<38:37, 36.79s/trial, best loss: -0.4894]
323
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [25:30<35:24, 34.27s/trial, best loss: -0.4894]
324
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [26:02<34:10, 33.62s/trial, best loss: -0.4894]
325
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [26:31<31:57, 31.97s/trial, best loss: -0.4894]
326
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [27:05<32:16, 32.82s/trial, best loss: -0.4894]
327
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [27:45<33:44, 34.91s/trial, best loss: -0.4894]
328
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [28:17<32:15, 33.95s/trial, best loss: -0.4894]
329
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [28:50<31:28, 33.72s/trial, best loss: -0.4894]
330
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [29:24<30:56, 33.75s/trial, best loss: -0.4894]
331
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [30:01<31:23, 34.88s/trial, best loss: -0.4894]
332
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [30:38<31:23, 35.54s/trial, best loss: -0.4894]
333
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [31:05<28:20, 32.71s/trial, best loss: -0.4894]
334
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [31:46<30:03, 35.36s/trial, best loss: -0.4894]
335
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [32:24<30:08, 36.17s/trial, best loss: -0.4894]
336
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [33:17<33:40, 41.24s/trial, best loss: -0.4894]
337
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [33:40<28:34, 35.72s/trial, best loss: -0.4894]
338
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [34:57<37:33, 47.95s/trial, best loss: -0.4894]
339
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [35:22<31:33, 41.17s/trial, best loss: -0.4894]
340
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [36:12<32:59, 43.98s/trial, best loss: -0.4894]
341
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [36:39<28:21, 38.67s/trial, best loss: -0.4894]
342
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [37:38<32:05, 44.79s/trial, best loss: -0.4894]
343
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [38:18<30:26, 43.49s/trial, best loss: -0.4894]
344
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [38:46<26:35, 38.90s/trial, best loss: -0.4894]
345
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [39:14<23:41, 35.55s/trial, best loss: -0.4894]
346
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [40:09<26:51, 41.32s/trial, best loss: -0.4894]
347
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [40:48<25:48, 40.76s/trial, best loss: -0.4894]
348
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [41:20<23:25, 37.97s/trial, best loss: -0.4894]
349
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆοΏ½οΏ½οΏ½ | 64/100 [41:54<22:03, 36.77s/trial, best loss: -0.4894]
350
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [42:27<20:53, 35.82s/trial, best loss: -0.4894]
351
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [43:12<21:46, 38.42s/trial, best loss: -0.4894]
352
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [43:46<20:25, 37.13s/trial, best loss: -0.4894]
353
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [44:18<19:00, 35.65s/trial, best loss: -0.4894]
354
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [44:52<18:09, 35.16s/trial, best loss: -0.4894]
355
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [45:42<19:50, 39.67s/trial, best loss: -0.4894]
356
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [46:24<19:24, 40.15s/trial, best loss: -0.4894]
357
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [46:52<17:05, 36.63s/trial, best loss: -0.4901]
358
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [47:36<17:26, 38.74s/trial, best loss: -0.4901]
359
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [48:08<15:56, 36.80s/trial, best loss: -0.4901]
360
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [48:34<14:00, 33.61s/trial, best loss: -0.4908]
361
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [49:02<12:44, 31.84s/trial, best loss: -0.4908]
362
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [49:28<11:29, 29.97s/trial, best loss: -0.4908]
363
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [49:52<10:22, 28.28s/trial, best loss: -0.4908]
364
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [50:21<10:01, 28.64s/trial, best loss: -0.4908]
365
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [50:46<09:11, 27.56s/trial, best loss: -0.4908]
366
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [51:16<08:53, 28.06s/trial, best loss: -0.4908]
367
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [51:46<08:36, 28.69s/trial, best loss: -0.4908]
368
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [52:15<08:10, 28.85s/trial, best loss: -0.4908]
369
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [52:46<07:51, 29.44s/trial, best loss: -0.4908]
370
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [53:12<07:08, 28.55s/trial, best loss: -0.4908]
371
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [53:43<06:48, 29.21s/trial, best loss: -0.4908]
372
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [54:08<06:03, 27.99s/trial, best loss: -0.4908]
373
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [54:32<05:20, 26.69s/trial, best loss: -0.4908]
374
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [54:56<04:45, 26.00s/trial, best loss: -0.4908]
375
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [55:31<04:45, 28.51s/trial, best loss: -0.4908]
376
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [56:00<04:20, 28.91s/trial, best loss: -0.4908]
377
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [56:37<04:09, 31.18s/trial, best loss: -0.4908]
378
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [57:05<03:31, 30.15s/trial, best loss: -0.4908]
379
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [57:26<02:44, 27.48s/trial, best loss: -0.4908]
380
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [57:53<02:16, 27.34s/trial, best loss: -0.4908]
381
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [58:28<01:58, 29.56s/trial, best loss: -0.4908]
382
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [58:53<01:24, 28.32s/trial, best loss: -0.4908]
383
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [59:16<00:53, 26.57s/trial, best loss: -0.4908]
384
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [59:58<00:31, 31.41s/trial, best loss: -0.4908]
385
+
386
+ μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {'colsample_bytree': 0.7077604272501928, 'learning_rate': 0.10351387699107398, 'max_depth': 6.0, 'min_child_weight': 4.0, 'num_leaves': 51.0, 'reg_alpha': 0.06973941883143871, 'reg_lambda': 0.8477821589656351, 'subsample': 0.8664583588640111}
387
+ 졜적 CSI 점수: 0.4908 (loss: -0.4908)
388
+
389
+ μ΅œμ ν™” κ³Όμ • μš”μ•½:
390
+ - 총 μ‹œλ„ 횟수: 100
391
+ - μ„±κ³΅ν•œ μ‹œλ„: 100
392
+ - 졜초 CSI: 0.4792
393
+ - μ΅œμ’… CSI: 0.4809
394
+ - 졜고 CSI: 0.4908
395
+ - μ΅œμ € CSI: 0.4682
396
+ - 평균 CSI: 0.4815
397
+
398
+ μ΅œμ ν™” Trials 객체가 /workspace/visibility_prediction/Analysis_code/optimization_history/lgb_ctgan10000_daejeon_trials.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
399
+ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...
400
+ Fold 1 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2019], 검증 연도: 2020)
401
+ Fold 1 검증 CSI: 0.4324
402
+ Fold 2 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2020], 검증 연도: 2019)
403
+ Fold 2 검증 CSI: 0.4714
404
+ Fold 3 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2019, 2020], 검증 연도: 2018)
405
+ Fold 3 검증 CSI: 0.5557
406
+ λͺ¨λΈ μ €μž₯ 쀑...
407
+ λͺ¨λΈμ΄ /workspace/visibility_prediction/Analysis_code/save_model/lgb_optima/lgb_ctgan10000_daejeon.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
408
+
409
+ βœ“ μ™„λ£Œ: lgb_ctgan10000/LGB_ctgan10000_daejeon.py (μ†Œμš” μ‹œκ°„: 3642초)
410
+
411
+ ----------------------------------------
412
+ μ‹€ν–‰ 쀑: lgb_ctgan10000/LGB_ctgan10000_gwangju.py
413
+ μ‹œμž‘ μ‹œκ°„: 2025-12-28 07:31:19
414
+ ----------------------------------------
415
+ 데이터 λ‘œλ”© 쀑...
416
+ 데이터 μ „μ²˜λ¦¬ 쀑...
417
+ ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...
418
+
419
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
420
  1%| | 1/100 [01:02<1:42:38, 62.20s/trial, best loss: -0.4807]
421
  2%|▏ | 2/100 [01:49<1:27:01, 53.28s/trial, best loss: -0.4841]
422
  3%|β–Ž | 3/100 [02:42<1:25:52, 53.12s/trial, best loss: -0.4848]
423
  4%|▍ | 4/100 [03:15<1:12:13, 45.14s/trial, best loss: -0.4916]
424
  5%|β–Œ | 5/100 [04:13<1:19:05, 49.96s/trial, best loss: -0.4916]
425
  6%|β–Œ | 6/100 [05:10<1:22:01, 52.35s/trial, best loss: -0.4916]
426
  7%|β–‹ | 7/100 [05:34<1:06:33, 42.94s/trial, best loss: -0.4916]
427
  8%|β–Š | 8/100 [06:55<1:24:29, 55.10s/trial, best loss: -0.4916]
428
  9%|β–‰ | 9/100 [07:43<1:20:06, 52.82s/trial, best loss: -0.4916]
429
  10%|β–ˆ | 10/100 [08:33<1:18:03, 52.04s/trial, best loss: -0.4916]
430
  11%|β–ˆ | 11/100 [08:58<1:04:48, 43.69s/trial, best loss: -0.4916]
431
  12%|β–ˆβ– | 12/100 [09:36<1:01:44, 42.09s/trial, best loss: -0.4916]
432
  13%|β–ˆβ–Ž | 13/100 [11:00<1:19:31, 54.85s/trial, best loss: -0.4916]
433
  14%|β–ˆβ– | 14/100 [12:01<1:21:08, 56.61s/trial, best loss: -0.4916]
434
  15%|β–ˆβ–Œ | 15/100 [12:29<1:08:01, 48.02s/trial, best loss: -0.4916]
435
  16%|β–ˆβ–Œ | 16/100 [13:15<1:06:13, 47.30s/trial, best loss: -0.4916]
436
  17%|β–ˆβ–‹ | 17/100 [13:36<54:35, 39.46s/trial, best loss: -0.4916]
437
  18%|β–ˆβ–Š | 18/100 [14:34<1:01:25, 44.94s/trial, best loss: -0.4916]
438
  19%|β–ˆβ–‰ | 19/100 [15:04<54:45, 40.56s/trial, best loss: -0.4916]
439
  20%|β–ˆβ–ˆ | 20/100 [16:14<1:05:52, 49.40s/trial, best loss: -0.4916]
440
  21%|β–ˆβ–ˆ | 21/100 [16:54<1:01:24, 46.64s/trial, best loss: -0.4971]
441
  22%|β–ˆβ–ˆβ– | 22/100 [17:30<56:16, 43.29s/trial, best loss: -0.4971]
442
  23%|β–ˆβ–ˆβ–Ž | 23/100 [18:01<51:01, 39.77s/trial, best loss: -0.4971]
443
  24%|β–ˆβ–ˆβ– | 24/100 [18:33<47:11, 37.25s/trial, best loss: -0.4971]
444
  25%|β–ˆβ–ˆβ–Œ | 25/100 [19:12<47:11, 37.75s/trial, best loss: -0.4971]
445
  26%|β–ˆβ–ˆβ–Œ | 26/100 [19:48<45:54, 37.22s/trial, best loss: -0.4971]
446
  27%|β–ˆβ–ˆβ–‹ | 27/100 [20:30<47:14, 38.83s/trial, best loss: -0.4971]
447
  28%|β–ˆβ–ˆβ–Š | 28/100 [21:01<43:51, 36.55s/trial, best loss: -0.4971]
448
  29%|β–ˆβ–ˆβ–‰ | 29/100 [21:48<47:00, 39.73s/trial, best loss: -0.4971]
449
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [22:23<44:41, 38.30s/trial, best loss: -0.4971]
450
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [22:49<39:43, 34.54s/trial, best loss: -0.4971]
451
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [23:13<35:34, 31.39s/trial, best loss: -0.4971]
452
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [23:34<31:37, 28.32s/trial, best loss: -0.4971]
453
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [24:14<35:00, 31.82s/trial, best loss: -0.4971]
454
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [24:59<38:36, 35.64s/trial, best loss: -0.4971]
455
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [25:35<38:10, 35.80s/trial, best loss: -0.4971]
456
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [26:39<46:25, 44.22s/trial, best loss: -0.4971]
457
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [27:04<39:35, 38.31s/trial, best loss: -0.4971]
458
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [27:38<37:49, 37.20s/trial, best loss: -0.4971]
459
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [28:10<35:45, 35.75s/trial, best loss: -0.4971]
460
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [28:34<31:29, 32.03s/trial, best loss: -0.4971]
461
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [29:01<29:39, 30.67s/trial, best loss: -0.4971]
462
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [29:33<29:29, 31.05s/trial, best loss: -0.4971]
463
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [30:15<32:02, 34.33s/trial, best loss: -0.4971]
464
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [30:46<30:33, 33.34s/trial, best loss: -0.4971]
465
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [31:18<29:33, 32.84s/trial, best loss: -0.4971]
466
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [31:55<30:00, 33.97s/trial, best loss: -0.4971]
467
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [32:40<32:31, 37.52s/trial, best loss: -0.4971]
468
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [33:06<28:58, 34.08s/trial, best loss: -0.4971]
469
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [33:29<25:34, 30.69s/trial, best loss: -0.4971]
470
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [33:54<23:39, 28.96s/trial, best loss: -0.4971]
471
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [34:21<22:42, 28.39s/trial, best loss: -0.4971]
472
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [34:57<23:53, 30.51s/trial, best loss: -0.4971]
473
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [35:35<25:16, 32.96s/trial, best loss: -0.4971]
474
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [36:07<24:24, 32.54s/trial, best loss: -0.4971]
475
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [37:12<31:05, 42.40s/trial, best loss: -0.4971]
476
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [37:49<29:04, 40.57s/trial, best loss: -0.4971]
477
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [38:23<27:06, 38.72s/trial, best loss: -0.4971]
478
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [38:56<25:20, 37.08s/trial, best loss: -0.4971]
479
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [39:30<24:08, 36.22s/trial, best loss: -0.4971]
480
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [40:38<29:41, 45.69s/trial, best loss: -0.4971]
481
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [41:09<26:05, 41.21s/trial, best loss: -0.4971]
482
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [41:45<24:28, 39.69s/trial, best loss: -0.4971]
483
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [42:17<22:26, 37.40s/trial, best loss: -0.4971]
484
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [42:46<20:20, 34.88s/trial, best loss: -0.4971]
485
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [43:19<19:23, 34.21s/trial, best loss: -0.4994]
486
  67%|οΏ½οΏ½οΏ½β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [43:52<18:36, 33.85s/trial, best loss: -0.4994]
487
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [44:26<18:10, 34.08s/trial, best loss: -0.4994]
488
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [45:15<19:46, 38.27s/trial, best loss: -0.4994]
489
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [45:56<19:36, 39.23s/trial, best loss: -0.4994]
490
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [46:41<19:51, 41.09s/trial, best loss: -0.4994]
491
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [47:26<19:44, 42.29s/trial, best loss: -0.4994]
492
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [48:36<22:40, 50.38s/trial, best loss: -0.4994]
493
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [49:12<20:01, 46.21s/trial, best loss: -0.4994]
494
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [49:58<19:11, 46.04s/trial, best loss: -0.4994]
495
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [50:36<17:24, 43.52s/trial, best loss: -0.4994]
496
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [51:07<15:19, 39.98s/trial, best loss: -0.4994]
497
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [52:08<16:54, 46.11s/trial, best loss: -0.4994]
498
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [52:46<15:22, 43.92s/trial, best loss: -0.4994]
499
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [53:27<14:18, 42.91s/trial, best loss: -0.4994]
500
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [53:59<12:33, 39.67s/trial, best loss: -0.4994]
501
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [54:47<12:39, 42.19s/trial, best loss: -0.4994]
502
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [55:36<12:30, 44.15s/trial, best loss: -0.4994]
503
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [56:13<11:10, 41.89s/trial, best loss: -0.4994]
504
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [56:50<10:09, 40.66s/trial, best loss: -0.4994]
505
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [57:41<10:11, 43.69s/trial, best loss: -0.4994]
506
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [58:47<10:54, 50.36s/trial, best loss: -0.4994]
507
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [59:26<09:22, 46.84s/trial, best loss: -0.4994]
508
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [1:00:02<08:02, 43.84s/trial, best loss: -0.4994]
509
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [1:00:31<06:33, 39.38s/trial, best loss: -0.4994]
510
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [1:01:09<05:48, 38.76s/trial, best loss: -0.4994]
511
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [1:01:45<05:04, 38.04s/trial, best loss: -0.4994]
512
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [1:02:39<04:59, 42.76s/trial, best loss: -0.4994]
513
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [1:03:06<03:48, 38.12s/trial, best loss: -0.4994]
514
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [1:03:39<03:02, 36.58s/trial, best loss: -0.4994]
515
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [1:04:16<02:26, 36.56s/trial, best loss: -0.4994]
516
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [1:04:51<01:48, 36.21s/trial, best loss: -0.4994]
517
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [1:05:15<01:05, 32.67s/trial, best loss: -0.4994]
518
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [1:05:43<00:31, 31.21s/trial, best loss: -0.4994]
519
+
520
+ μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {'colsample_bytree': 0.9974290644555891, 'learning_rate': 0.03488079849604818, 'max_depth': 15.0, 'min_child_weight': 13.0, 'num_leaves': 47.0, 'reg_alpha': 0.22968749134640387, 'reg_lambda': 0.42745540115072206, 'subsample': 0.9875948361694687}
521
+ 졜적 CSI 점수: 0.4994 (loss: -0.4994)
522
+
523
+ μ΅œμ ν™” κ³Όμ • μš”μ•½:
524
+ - 총 μ‹œλ„ 횟수: 100
525
+ - μ„±κ³΅ν•œ μ‹œλ„: 100
526
+ - 졜초 CSI: 0.4807
527
+ - μ΅œμ’… CSI: 0.4865
528
+ - 졜고 CSI: 0.4994
529
+ - μ΅œμ € CSI: 0.4678
530
+ - 평균 CSI: 0.4866
531
+
532
+ μ΅œμ ν™” Trials 객체가 /workspace/visibility_prediction/Analysis_code/optimization_history/lgb_ctgan10000_gwangju_trials.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
533
+ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...
534
+ Fold 1 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2019], 검증 연도: 2020)
535
+ Fold 1 검증 CSI: 0.4045
536
+ Fold 2 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2020], 검증 연도: 2019)
537
+ Fold 2 검증 CSI: 0.5536
538
+ Fold 3 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2019, 2020], 검증 연도: 2018)
539
+ Fold 3 검증 CSI: 0.5277
540
+ λͺ¨λΈ μ €μž₯ 쀑...
541
+ λͺ¨λΈμ΄ /workspace/visibility_prediction/Analysis_code/save_model/lgb_optima/lgb_ctgan10000_gwangju.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
542
+
543
+ βœ“ μ™„λ£Œ: lgb_ctgan10000/LGB_ctgan10000_gwangju.py (μ†Œμš” μ‹œκ°„: 4001초)
544
+
545
+ ----------------------------------------
546
+ μ‹€ν–‰ 쀑: lgb_ctgan10000/LGB_ctgan10000_incheon.py
547
+ μ‹œμž‘ μ‹œκ°„: 2025-12-28 08:38:00
548
+ ----------------------------------------
549
+ 데이터 λ‘œλ”© 쀑...
550
+ 데이터 μ „μ²˜λ¦¬ 쀑...
551
+ ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...
552
+
553
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
554
  1%| | 1/100 [00:54<1:30:09, 54.64s/trial, best loss: -0.5469]
555
  2%|▏ | 2/100 [01:19<1:00:47, 37.22s/trial, best loss: -0.5519]
556
  3%|β–Ž | 3/100 [01:50<55:12, 34.15s/trial, best loss: -0.5519]
557
  4%|▍ | 4/100 [02:25<55:19, 34.57s/trial, best loss: -0.5519]
558
  5%|β–Œ | 5/100 [03:31<1:12:51, 46.01s/trial, best loss: -0.5557]
559
  6%|οΏ½οΏ½ | 6/100 [04:02<1:03:56, 40.81s/trial, best loss: -0.5557]
560
  7%|β–‹ | 7/100 [04:30<56:42, 36.58s/trial, best loss: -0.5557]
561
  8%|β–Š | 8/100 [05:14<59:48, 39.00s/trial, best loss: -0.5557]
562
  9%|β–‰ | 9/100 [05:44<54:59, 36.26s/trial, best loss: -0.5557]
563
  10%|β–ˆ | 10/100 [06:26<56:54, 37.94s/trial, best loss: -0.5557]
564
  11%|β–ˆ | 11/100 [06:56<52:53, 35.66s/trial, best loss: -0.5557]
565
  12%|β–ˆβ– | 12/100 [08:02<1:05:32, 44.69s/trial, best loss: -0.5557]
566
  13%|β–ˆβ–Ž | 13/100 [08:46<1:04:34, 44.53s/trial, best loss: -0.5557]
567
  14%|β–ˆβ– | 14/100 [09:35<1:05:36, 45.77s/trial, best loss: -0.5557]
568
  15%|β–ˆβ–Œ | 15/100 [10:59<1:21:31, 57.55s/trial, best loss: -0.5557]
569
  16%|β–ˆβ–Œ | 16/100 [11:22<1:05:53, 47.07s/trial, best loss: -0.5557]
570
  17%|β–ˆβ–‹ | 17/100 [12:15<1:07:27, 48.77s/trial, best loss: -0.5557]
571
  18%|β–ˆβ–Š | 18/100 [12:46<59:16, 43.37s/trial, best loss: -0.5557]
572
  19%|β–ˆβ–‰ | 19/100 [13:18<54:13, 40.17s/trial, best loss: -0.5557]
573
  20%|β–ˆβ–ˆ | 20/100 [13:43<47:31, 35.64s/trial, best loss: -0.5557]
574
  21%|β–ˆβ–ˆ | 21/100 [14:13<44:40, 33.93s/trial, best loss: -0.5557]
575
  22%|β–ˆβ–ˆβ– | 22/100 [15:23<58:03, 44.67s/trial, best loss: -0.5557]
576
  23%|β–ˆβ–ˆβ–Ž | 23/100 [15:46<49:03, 38.23s/trial, best loss: -0.5557]
577
  24%|β–ˆβ–ˆβ– | 24/100 [16:16<45:01, 35.55s/trial, best loss: -0.5557]
578
  25%|β–ˆβ–ˆβ–Œ | 25/100 [16:48<43:17, 34.64s/trial, best loss: -0.5557]
579
  26%|β–ˆβ–ˆβ–Œ | 26/100 [17:28<44:29, 36.07s/trial, best loss: -0.5557]
580
  27%|β–ˆβ–ˆβ–‹ | 27/100 [17:55<40:51, 33.59s/trial, best loss: -0.5557]
581
  28%|β–ˆβ–ˆβ–Š | 28/100 [18:25<39:01, 32.52s/trial, best loss: -0.556]
582
  29%|β–ˆβ–ˆβ–‰ | 29/100 [19:42<54:10, 45.78s/trial, best loss: -0.556]
583
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [20:16<49:15, 42.23s/trial, best loss: -0.556]
584
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [20:49<45:25, 39.50s/trial, best loss: -0.556]
585
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [21:32<45:48, 40.41s/trial, best loss: -0.556]
586
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [22:16<46:24, 41.57s/trial, best loss: -0.5567]
587
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [22:57<45:31, 41.39s/trial, best loss: -0.5567]
588
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [23:40<45:17, 41.81s/trial, best loss: -0.5567]
589
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [24:46<52:33, 49.28s/trial, best loss: -0.5567]
590
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [25:24<48:09, 45.86s/trial, best loss: -0.558]
591
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [26:06<46:08, 44.65s/trial, best loss: -0.558]
592
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [26:54<46:31, 45.76s/trial, best loss: -0.558]
593
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [27:40<45:35, 45.60s/trial, best loss: -0.558]
594
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [28:19<42:58, 43.71s/trial, best loss: -0.558]
595
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [29:14<45:34, 47.14s/trial, best loss: -0.558]
596
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [29:56<43:11, 45.47s/trial, best loss: -0.558]
597
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [30:58<47:01, 50.39s/trial, best loss: -0.558]
598
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [31:43<44:47, 48.86s/trial, best loss: -0.558]
599
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [32:39<46:01, 51.15s/trial, best loss: -0.558]
600
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [33:32<45:28, 51.48s/trial, best loss: -0.558]
601
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [34:10<41:20, 47.70s/trial, best loss: -0.558]
602
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [34:49<38:16, 45.04s/trial, best loss: -0.558]
603
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [35:28<35:54, 43.09s/trial, best loss: -0.558]
604
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [36:07<34:20, 42.06s/trial, best loss: -0.558]
605
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [36:43<32:09, 40.19s/trial, best loss: -0.558]
606
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [37:19<30:30, 38.94s/trial, best loss: -0.558]
607
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [37:47<27:17, 35.59s/trial, best loss: -0.558]
608
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [38:19<25:50, 34.45s/trial, best loss: -0.558]
609
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [39:05<27:44, 37.83s/trial, best loss: -0.558]
610
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [39:37<25:53, 36.12s/trial, best loss: -0.558]
611
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [40:15<25:40, 36.67s/trial, best loss: -0.558]
612
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [40:53<25:27, 37.25s/trial, best loss: -0.558]
613
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [41:39<26:29, 39.73s/trial, best loss: -0.558]
614
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [42:12<24:36, 37.85s/trial, best loss: -0.558]
615
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [42:45<22:55, 36.21s/trial, best loss: -0.558]
616
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [43:34<24:41, 40.05s/trial, best loss: -0.558]
617
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [43:56<20:46, 34.61s/trial, best loss: -0.558]
618
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [44:36<21:12, 36.36s/trial, best loss: -0.558]
619
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [45:08<19:49, 34.98s/trial, best loss: -0.558]
620
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [45:36<18:03, 32.83s/trial, best loss: -0.558]
621
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [46:02<16:32, 31.03s/trial, best loss: -0.558]
622
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [46:45<17:48, 34.45s/trial, best loss: -0.5588]
623
  70%|β–ˆβ–ˆβ–ˆοΏ½οΏ½β–ˆβ–ˆβ–ˆ | 70/100 [47:26<18:11, 36.38s/trial, best loss: -0.5588]
624
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [48:08<18:24, 38.10s/trial, best loss: -0.5588]
625
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [48:40<16:57, 36.33s/trial, best loss: -0.5588]
626
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [49:47<20:26, 45.41s/trial, best loss: -0.5588]
627
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [50:25<18:42, 43.17s/trial, best loss: -0.5588]
628
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [51:28<20:32, 49.28s/trial, best loss: -0.5588]
629
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [52:21<20:06, 50.28s/trial, best loss: -0.5588]
630
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [53:03<18:18, 47.74s/trial, best loss: -0.5588]
631
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [53:47<17:11, 46.87s/trial, best loss: -0.5588]
632
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [54:27<15:40, 44.78s/trial, best loss: -0.5588]
633
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [55:22<15:58, 47.90s/trial, best loss: -0.5588]
634
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [55:57<13:54, 43.91s/trial, best loss: -0.5588]
635
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [56:31<12:14, 40.78s/trial, best loss: -0.5588]
636
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [57:01<10:39, 37.63s/trial, best loss: -0.5588]
637
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [57:42<10:18, 38.68s/trial, best loss: -0.5588]
638
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [58:32<10:29, 41.95s/trial, best loss: -0.5588]
639
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [59:09<09:27, 40.52s/trial, best loss: -0.5588]
640
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [59:52<08:58, 41.40s/trial, best loss: -0.5588]
641
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [1:00:15<07:08, 35.74s/trial, best loss: -0.5588]
642
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [1:00:53<06:40, 36.37s/trial, best loss: -0.5588]
643
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [1:01:38<06:30, 39.04s/trial, best loss: -0.5588]
644
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [1:02:20<05:59, 39.93s/trial, best loss: -0.5588]
645
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [1:03:11<05:45, 43.19s/trial, best loss: -0.5592]
646
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [1:04:06<05:27, 46.72s/trial, best loss: -0.5592]
647
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [1:05:23<05:34, 55.81s/trial, best loss: -0.5592]
648
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [1:06:36<05:05, 61.13s/trial, best loss: -0.5592]
649
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [1:07:16<03:39, 54.80s/trial, best loss: -0.5592]
650
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [1:07:55<02:30, 50.12s/trial, best loss: -0.5592]
651
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [1:08:36<01:34, 47.21s/trial, best loss: -0.5592]
652
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [1:09:51<00:55, 55.54s/trial, best loss: -0.5592]
653
+
654
+ μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {'colsample_bytree': 0.7615743363801121, 'learning_rate': 0.032013705340192794, 'max_depth': 12.0, 'min_child_weight': 4.0, 'num_leaves': 135.0, 'reg_alpha': 0.07355917150019742, 'reg_lambda': 0.7693270890686972, 'subsample': 0.8491133431153928}
655
+ 졜적 CSI 점수: 0.5592 (loss: -0.5592)
656
+
657
+ μ΅œμ ν™” κ³Όμ • μš”μ•½:
658
+ - 총 μ‹œλ„ 횟수: 100
659
+ - μ„±κ³΅ν•œ μ‹œλ„: 100
660
+ - 졜초 CSI: 0.5469
661
+ - μ΅œμ’… CSI: 0.5567
662
+ - 졜고 CSI: 0.5592
663
+ - μ΅œμ € CSI: 0.5428
664
+ - 평균 CSI: 0.5520
665
+
666
+ μ΅œμ ν™” Trials 객체가 /workspace/visibility_prediction/Analysis_code/optimization_history/lgb_ctgan10000_incheon_trials.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
667
+ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...
668
+ Fold 1 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2019], 검증 연도: 2020)
669
+ Fold 1 검증 CSI: 0.4967
670
+ Fold 2 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2020], 검증 연도: 2019)
671
+ Fold 2 검증 CSI: 0.6068
672
+ Fold 3 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2019, 2020], 검증 연도: 2018)
673
+ Fold 3 검증 CSI: 0.5748
674
+ λͺ¨λΈ μ €μž₯ 쀑...
675
+ λͺ¨λΈμ΄ /workspace/visibility_prediction/Analysis_code/save_model/lgb_optima/lgb_ctgan10000_incheon.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
676
+
677
+ βœ“ μ™„λ£Œ: lgb_ctgan10000/LGB_ctgan10000_incheon.py (μ†Œμš” μ‹œκ°„: 4299초)
678
+
679
+ ----------------------------------------
680
+ μ‹€ν–‰ 쀑: lgb_ctgan10000/LGB_ctgan10000_seoul.py
681
+ μ‹œμž‘ μ‹œκ°„: 2025-12-28 09:49:39
682
+ ----------------------------------------
683
+ 데이터 λ‘œλ”© 쀑...
684
+ 데이터 μ „μ²˜λ¦¬ 쀑...
685
+ ν•˜μ΄νΌνŒŒλΌλ―Έν„° μ΅œμ ν™” μ‹œμž‘...
686
+
687
  0%| | 0/100 [00:00<?, ?trial/s, best loss=?]
688
  1%| | 1/100 [01:13<2:01:00, 73.34s/trial, best loss: -0.5479]
689
  2%|▏ | 2/100 [01:43<1:18:00, 47.76s/trial, best loss: -0.5552]
690
  3%|β–Ž | 3/100 [02:04<57:22, 35.48s/trial, best loss: -0.558]
691
  4%|▍ | 4/100 [03:04<1:12:39, 45.41s/trial, best loss: -0.558]
692
  5%|β–Œ | 5/100 [03:45<1:09:30, 43.90s/trial, best loss: -0.558]
693
  6%|β–Œ | 6/100 [04:11<58:53, 37.59s/trial, best loss: -0.5639]
694
  7%|β–‹ | 7/100 [04:54<1:01:02, 39.38s/trial, best loss: -0.5639]
695
  8%|β–Š | 8/100 [05:50<1:08:46, 44.86s/trial, best loss: -0.5639]
696
  9%|β–‰ | 9/100 [06:40<1:10:17, 46.34s/trial, best loss: -0.5639]
697
  10%|β–ˆ | 10/100 [07:29<1:10:30, 47.01s/trial, best loss: -0.5639]
698
  11%|β–ˆ | 11/100 [08:14<1:08:51, 46.42s/trial, best loss: -0.5639]
699
  12%|β–ˆβ– | 12/100 [08:33<56:03, 38.22s/trial, best loss: -0.5639]
700
  13%|β–ˆβ–Ž | 13/100 [08:57<49:03, 33.84s/trial, best loss: -0.5639]
701
  14%|β–ˆβ– | 14/100 [09:20<43:45, 30.53s/trial, best loss: -0.5639]
702
  15%|β–ˆβ–Œ | 15/100 [09:49<42:37, 30.09s/trial, best loss: -0.5639]
703
  16%|β–ˆβ–Œ | 16/100 [11:05<1:01:44, 44.10s/trial, best loss: -0.5639]
704
  17%|β–ˆβ–‹ | 17/100 [11:51<1:01:40, 44.58s/trial, best loss: -0.5639]
705
  18%|β–ˆβ–Š | 18/100 [12:21<55:03, 40.28s/trial, best loss: -0.5639]
706
  19%|β–ˆβ–‰ | 19/100 [12:46<47:51, 35.45s/trial, best loss: -0.5639]
707
  20%|β–ˆβ–ˆ | 20/100 [13:30<50:43, 38.05s/trial, best loss: -0.5639]
708
  21%|β–ˆβ–ˆ | 21/100 [13:54<44:35, 33.86s/trial, best loss: -0.5639]
709
  22%|β–ˆβ–ˆβ– | 22/100 [14:21<41:16, 31.75s/trial, best loss: -0.5639]
710
  23%|β–ˆβ–ˆβ–Ž | 23/100 [14:43<37:04, 28.89s/trial, best loss: -0.5639]
711
  24%|β–ˆβ–ˆβ– | 24/100 [15:09<35:34, 28.08s/trial, best loss: -0.5639]
712
  25%|β–ˆβ–ˆβ–Œ | 25/100 [15:31<32:49, 26.26s/trial, best loss: -0.5639]
713
  26%|β–ˆβ–ˆβ–Œ | 26/100 [15:54<31:08, 25.25s/trial, best loss: -0.5639]
714
  27%|β–ˆβ–ˆβ–‹ | 27/100 [16:19<30:45, 25.28s/trial, best loss: -0.5639]
715
  28%|β–ˆβ–ˆβ–Š | 28/100 [16:46<30:58, 25.81s/trial, best loss: -0.5639]
716
  29%|β–ˆβ–ˆβ–‰ | 29/100 [17:08<28:59, 24.51s/trial, best loss: -0.5639]
717
  30%|β–ˆβ–ˆβ–ˆ | 30/100 [17:43<32:21, 27.74s/trial, best loss: -0.5639]
718
  31%|β–ˆβ–ˆβ–ˆ | 31/100 [18:09<31:10, 27.11s/trial, best loss: -0.5639]
719
  32%|β–ˆβ–ˆβ–ˆβ– | 32/100 [18:37<31:01, 27.38s/trial, best loss: -0.5639]
720
  33%|β–ˆβ–ˆβ–ˆβ–Ž | 33/100 [19:01<29:22, 26.31s/trial, best loss: -0.5639]
721
  34%|β–ˆβ–ˆβ–ˆβ– | 34/100 [19:30<30:00, 27.28s/trial, best loss: -0.5639]
722
  35%|β–ˆβ–ˆβ–ˆβ–Œ | 35/100 [19:58<29:44, 27.46s/trial, best loss: -0.5639]
723
  36%|β–ˆβ–ˆβ–ˆβ–Œ | 36/100 [20:22<28:19, 26.55s/trial, best loss: -0.5639]
724
  37%|β–ˆβ–ˆβ–ˆβ–‹ | 37/100 [21:29<40:25, 38.50s/trial, best loss: -0.5639]
725
  38%|β–ˆβ–ˆβ–ˆβ–Š | 38/100 [21:51<34:50, 33.72s/trial, best loss: -0.5639]
726
  39%|β–ˆβ–ˆβ–ˆβ–‰ | 39/100 [22:17<31:58, 31.44s/trial, best loss: -0.5639]
727
  40%|β–ˆβ–ˆβ–ˆβ–ˆ | 40/100 [22:41<28:57, 28.96s/trial, best loss: -0.5639]
728
  41%|β–ˆβ–ˆβ–ˆβ–ˆ | 41/100 [23:15<30:07, 30.63s/trial, best loss: -0.5639]
729
  42%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 42/100 [23:39<27:46, 28.74s/trial, best loss: -0.5639]
730
  43%|β–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 43/100 [24:00<25:01, 26.34s/trial, best loss: -0.5639]
731
  44%|β–ˆβ–ˆβ–ˆβ–ˆβ– | 44/100 [24:27<24:44, 26.51s/trial, best loss: -0.5639]
732
  45%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 45/100 [25:06<27:45, 30.28s/trial, best loss: -0.5639]
733
  46%|β–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 46/100 [26:00<33:30, 37.23s/trial, best loss: -0.5639]
734
  47%|β–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 47/100 [26:37<32:59, 37.35s/trial, best loss: -0.5639]
735
  48%|β–ˆβ–ˆβ–ˆβ–ˆβ–Š | 48/100 [27:20<33:53, 39.11s/trial, best loss: -0.5639]
736
  49%|β–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 49/100 [28:20<38:25, 45.22s/trial, best loss: -0.5639]
737
  50%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 50/100 [28:53<34:36, 41.53s/trial, best loss: -0.5639]
738
  51%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 51/100 [29:31<32:57, 40.36s/trial, best loss: -0.5639]
739
  52%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 52/100 [30:14<32:59, 41.23s/trial, best loss: -0.5639]
740
  53%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 53/100 [30:47<30:18, 38.70s/trial, best loss: -0.5639]
741
  54%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 54/100 [31:18<28:03, 36.61s/trial, best loss: -0.5639]
742
  55%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 55/100 [31:49<26:11, 34.93s/trial, best loss: -0.5639]
743
  56%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 56/100 [32:46<30:26, 41.51s/trial, best loss: -0.5639]
744
  57%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 57/100 [33:33<30:59, 43.25s/trial, best loss: -0.5639]
745
  58%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 58/100 [34:05<27:50, 39.78s/trial, best loss: -0.5639]
746
  59%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 59/100 [34:53<28:45, 42.09s/trial, best loss: -0.5639]
747
  60%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 60/100 [35:17<24:35, 36.90s/trial, best loss: -0.5639]
748
  61%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 61/100 [35:44<22:03, 33.93s/trial, best loss: -0.5639]
749
  62%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 62/100 [36:08<19:31, 30.83s/trial, best loss: -0.5639]
750
  63%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 63/100 [36:36<18:26, 29.91s/trial, best loss: -0.5639]
751
  64%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 64/100 [36:56<16:16, 27.13s/trial, best loss: -0.5639]
752
  65%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 65/100 [37:22<15:30, 26.57s/trial, best loss: -0.5639]
753
  66%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 66/100 [37:54<16:05, 28.41s/trial, best loss: -0.5655]
754
  67%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 67/100 [38:28<16:32, 30.06s/trial, best loss: -0.5655]
755
  68%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 68/100 [39:05<17:07, 32.12s/trial, best loss: -0.5655]
756
  69%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 69/100 [39:35<16:15, 31.48s/trial, best loss: -0.5655]
757
  70%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 70/100 [40:17<17:17, 34.58s/trial, best loss: -0.5655]
758
  71%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 71/100 [40:41<15:13, 31.49s/trial, best loss: -0.5655]
759
  72%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 72/100 [41:26<16:34, 35.53s/trial, best loss: -0.5655]
760
  73%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 73/100 [41:53<14:51, 33.02s/trial, best loss: -0.5655]
761
  74%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 74/100 [42:31<14:57, 34.53s/trial, best loss: -0.5655]
762
  75%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 75/100 [43:02<13:50, 33.22s/trial, best loss: -0.5655]
763
  76%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 76/100 [43:46<14:37, 36.58s/trial, best loss: -0.5655]
764
  77%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 77/100 [44:15<13:06, 34.20s/trial, best loss: -0.5655]
765
  78%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 78/100 [44:47<12:22, 33.75s/trial, best loss: -0.5655]
766
  79%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 79/100 [45:17<11:20, 32.40s/trial, best loss: -0.5655]
767
  80%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 80/100 [45:48<10:41, 32.08s/trial, best loss: -0.5655]
768
  81%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 81/100 [46:27<10:47, 34.07s/trial, best loss: -0.5655]
769
  82%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 82/100 [47:05<10:36, 35.34s/trial, best loss: -0.5655]
770
  83%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž | 83/100 [47:37<09:44, 34.37s/trial, best loss: -0.5655]
771
  84%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 84/100 [48:20<09:50, 36.90s/trial, best loss: -0.5655]
772
  85%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 85/100 [48:51<08:46, 35.11s/trial, best loss: -0.5655]
773
  86%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 86/100 [49:25<08:06, 34.73s/trial, best loss: -0.5655]
774
  87%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 87/100 [49:56<07:16, 33.56s/trial, best loss: -0.5655]
775
  88%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š | 88/100 [50:33<06:56, 34.70s/trial, best loss: -0.566]
776
  89%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 89/100 [51:19<06:57, 37.99s/trial, best loss: -0.566]
777
  90%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 90/100 [51:54<06:10, 37.08s/trial, best loss: -0.566]
778
  91%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 91/100 [52:47<06:18, 42.10s/trial, best loss: -0.566]
779
  92%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 92/100 [53:24<05:23, 40.43s/trial, best loss: -0.5671]
780
  93%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Ž| 93/100 [54:01<04:36, 39.53s/trial, best loss: -0.5671]
781
  94%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–| 94/100 [54:56<04:24, 44.12s/trial, best loss: -0.5671]
782
  95%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 95/100 [55:34<03:31, 42.24s/trial, best loss: -0.5671]
783
  96%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ| 96/100 [56:12<02:43, 40.95s/trial, best loss: -0.5671]
784
  97%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹| 97/100 [56:56<02:05, 41.79s/trial, best loss: -0.5671]
785
  98%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Š| 98/100 [57:43<01:26, 43.42s/trial, best loss: -0.5671]
786
  99%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰| 99/100 [58:35<00:45, 45.96s/trial, best loss: -0.5671]
787
+
788
+ μ΅œμ ν™” μ™„λ£Œ. 졜적 νŒŒλΌλ―Έν„°: {'colsample_bytree': 0.661683034534645, 'learning_rate': 0.02117850018558707, 'max_depth': 15.0, 'min_child_weight': 16.0, 'num_leaves': 83.0, 'reg_alpha': 0.6438462886327296, 'reg_lambda': 0.8929153518940249, 'subsample': 0.9547922722157274}
789
+ 졜적 CSI 점수: 0.5671 (loss: -0.5671)
790
+
791
+ μ΅œμ ν™” κ³Όμ • μš”μ•½:
792
+ - 총 μ‹œλ„ 횟수: 100
793
+ - μ„±κ³΅ν•œ μ‹œλ„: 100
794
+ - 졜초 CSI: 0.5479
795
+ - μ΅œμ’… CSI: 0.5505
796
+ - 졜고 CSI: 0.5671
797
+ - μ΅œμ € CSI: 0.5432
798
+ - 평균 CSI: 0.5579
799
+
800
+ μ΅œμ ν™” Trials 객체가 /workspace/visibility_prediction/Analysis_code/optimization_history/lgb_ctgan10000_seoul_trials.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
801
+ μ΅œμ’… λͺ¨λΈ ν•™μŠ΅ μ‹œμž‘...
802
+ Fold 1 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2019], 검증 연도: 2020)
803
+ Fold 1 검증 CSI: 0.4967
804
+ Fold 2 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2018, 2020], 검증 연도: 2019)
805
+ Fold 2 검증 CSI: 0.5994
806
+ Fold 3 ν•™μŠ΅ 쀑... (ν•™μŠ΅ 연도: [2019, 2020], 검증 연도: 2018)
807
+ Fold 3 검증 CSI: 0.5777
808
+ λͺ¨λΈ μ €μž₯ 쀑...
809
+ λͺ¨λΈμ΄ /workspace/visibility_prediction/Analysis_code/save_model/lgb_optima/lgb_ctgan10000_seoul.pkl에 μ €μž₯λ˜μ—ˆμŠ΅λ‹ˆλ‹€.
810
+
811
+ βœ“ μ™„λ£Œ: lgb_ctgan10000/LGB_ctgan10000_seoul.py (μ†Œμš” μ‹œκ°„: 3571초)
812
+
813
+ ==========================================
814
+ LGB CTGAN10000 파일 μ‹€ν–‰ μ™„λ£Œ
815
+ μ’…λ£Œ μ‹œκ°„: 2025-12-28 10:49:10
816
+ 총 μ†Œμš” μ‹œκ°„: 6μ‹œκ°„ 19λΆ„ 31초
817
+ 성곡: 6개
818
+ μ‹€νŒ¨: 0개
819
+ ==========================================