質問編集履歴

1

2021/02/15 12:39

投稿

3naoki
3naoki

スコア12

test CHANGED
File without changes
test CHANGED
@@ -13,59 +13,3 @@
13
13
 
14
14
 
15
15
  参考サイト:[Github_LightGBM](https://github.com/Microsoft/LightGBM/blob/master/examples/python-guide/advanced_example.py)
16
-
17
- ```python
18
-
19
- train_data = lgb.Dataset(
20
-
21
- train_X,
22
-
23
- label=train_Y,
24
-
25
- categorical_feature='auto'
26
-
27
- )
28
-
29
- avg_best_num_boost_round=100
30
-
31
- params = {
32
-
33
- 'task': 'train',
34
-
35
- 'objective': 'regression',
36
-
37
- 'boosting_type': 'gbdt',
38
-
39
- 'metric': 'rmse',
40
-
41
- 'num_leaves': 8,
42
-
43
- 'max_depth': 8,
44
-
45
- 'min_data_in_leaf': 5,
46
-
47
- 'learning_rate': 0.01,
48
-
49
- 'random_state':random_state,
50
-
51
- 'n_jobs': n_jobs,
52
-
53
- 'save_binary':True,
54
-
55
- }
56
-
57
- gbm = lgb.train(
58
-
59
- params,
60
-
61
- train_data,
62
-
63
- num_boost_round=avg_best_num_boost_round,
64
-
65
- init_model=model_name,
66
-
67
- )
68
-
69
-
70
-
71
- ```