Skip to content

Commit 6fcbddd

Browse files
author
Github Actions
committed
Ravin Kohli: Merge pull request #105 from nabenabe0928/refactoring-base-dataset
1 parent 9e848ac commit 6fcbddd

File tree

11 files changed

+261
-143
lines changed

11 files changed

+261
-143
lines changed
Binary file not shown.
Binary file not shown.

refactor_development/_sources/examples/example_image_classification.rst.txt

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -82,25 +82,20 @@ Image Classification
8282
________________________________________
8383
Configuration:
8484
image_augmenter:GaussianBlur:use_augmenter, Value: False
85-
image_augmenter:GaussianNoise:sigma_offset, Value: 1.98731511231425
85+
image_augmenter:GaussianNoise:sigma_offset, Value: 0.5614286279360542
8686
image_augmenter:GaussianNoise:use_augmenter, Value: True
87-
image_augmenter:RandomAffine:rotate, Value: 50
88-
image_augmenter:RandomAffine:scale_offset, Value: 0.014555060261484254
89-
image_augmenter:RandomAffine:shear, Value: 37
90-
image_augmenter:RandomAffine:translate_percent_offset, Value: 0.25465139302111295
91-
image_augmenter:RandomAffine:use_augmenter, Value: True
92-
image_augmenter:RandomCutout:p, Value: 0.4035801393808609
93-
image_augmenter:RandomCutout:use_augmenter, Value: True
94-
image_augmenter:Resize:use_augmenter, Value: False
95-
image_augmenter:ZeroPadAndCrop:percent, Value: 0.23991178688053533
96-
normalizer:__choice__, Value: 'ImageNormalizer'
87+
image_augmenter:RandomAffine:use_augmenter, Value: False
88+
image_augmenter:RandomCutout:use_augmenter, Value: False
89+
image_augmenter:Resize:use_augmenter, Value: True
90+
image_augmenter:ZeroPadAndCrop:percent, Value: 0.2076158247310454
91+
normalizer:__choice__, Value: 'NoNormalizer'
9792

9893
Fitting the pipeline...
9994
________________________________________
10095
ImageClassificationPipeline
10196
________________________________________
10297
0-) normalizer:
103-
ImageNormalizer
98+
NoNormalizer
10499

105100
1-) preprocessing:
106101
EarlyPreprocessing
@@ -172,7 +167,7 @@ Image Classification
172167
173168
.. rst-class:: sphx-glr-timing
174169

175-
**Total running time of the script:** ( 0 minutes 11.818 seconds)
170+
**Total running time of the script:** ( 0 minutes 9.520 seconds)
176171

177172

178173
.. _sphx_glr_download_examples_example_image_classification.py:

refactor_development/_sources/examples/example_tabular_classification.rst.txt

Lines changed: 81 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ with AutoPyTorch
3636

3737
.. code-block:: none
3838
39-
<smac.runhistory.runhistory.RunHistory object at 0x7f42044b7c10> [TrajEntry(train_perf=2147483648, incumbent_id=1, incumbent=Configuration:
39+
<smac.runhistory.runhistory.RunHistory object at 0x7ff7fbf2b190> [TrajEntry(train_perf=2147483648, incumbent_id=1, incumbent=Configuration:
4040
data_loader:batch_size, Value: 32
4141
encoder:__choice__, Value: 'OneHotEncoder'
4242
feature_preprocessor:__choice__, Value: 'NoFeaturePreprocessor'
@@ -77,7 +77,7 @@ with AutoPyTorch
7777
scaler:__choice__, Value: 'StandardScaler'
7878
trainer:StandardTrainer:weighted_loss, Value: True
7979
trainer:__choice__, Value: 'StandardTrainer'
80-
, ta_runs=0, ta_time_used=0.0, wallclock_time=0.0021822452545166016, budget=0), TrajEntry(train_perf=0.1871345029239766, incumbent_id=1, incumbent=Configuration:
80+
, ta_runs=0, ta_time_used=0.0, wallclock_time=0.0019752979278564453, budget=0), TrajEntry(train_perf=0.216374269005848, incumbent_id=1, incumbent=Configuration:
8181
data_loader:batch_size, Value: 32
8282
encoder:__choice__, Value: 'OneHotEncoder'
8383
feature_preprocessor:__choice__, Value: 'NoFeaturePreprocessor'
@@ -118,60 +118,92 @@ with AutoPyTorch
118118
scaler:__choice__, Value: 'StandardScaler'
119119
trainer:StandardTrainer:weighted_loss, Value: True
120120
trainer:__choice__, Value: 'StandardTrainer'
121-
, ta_runs=1, ta_time_used=4.781935930252075, wallclock_time=6.252290487289429, budget=5.555555555555555), TrajEntry(train_perf=0.14619883040935677, incumbent_id=2, incumbent=Configuration:
122-
data_loader:batch_size, Value: 295
123-
encoder:__choice__, Value: 'OneHotEncoder'
124-
feature_preprocessor:__choice__, Value: 'NoFeaturePreprocessor'
121+
, ta_runs=1, ta_time_used=5.269052505493164, wallclock_time=6.652451276779175, budget=5.555555555555555), TrajEntry(train_perf=0.21052631578947367, incumbent_id=2, incumbent=Configuration:
122+
data_loader:batch_size, Value: 472
123+
encoder:__choice__, Value: 'NoEncoder'
124+
feature_preprocessor:Nystroem:gamma, Value: 0.07411722362589628
125+
feature_preprocessor:Nystroem:kernel, Value: 'rbf'
126+
feature_preprocessor:Nystroem:n_components, Value: 5
127+
feature_preprocessor:__choice__, Value: 'Nystroem'
125128
imputer:categorical_strategy, Value: 'constant_!missing!'
126-
imputer:numerical_strategy, Value: 'median'
127-
lr_scheduler:ReduceLROnPlateau:factor, Value: 0.7683488018951772
128-
lr_scheduler:ReduceLROnPlateau:mode, Value: 'min'
129-
lr_scheduler:ReduceLROnPlateau:patience, Value: 7
130-
lr_scheduler:__choice__, Value: 'ReduceLROnPlateau'
129+
imputer:numerical_strategy, Value: 'constant_zero'
130+
lr_scheduler:__choice__, Value: 'NoScheduler'
131131
network_backbone:ShapedMLPBackbone:activation, Value: 'tanh'
132-
network_backbone:ShapedMLPBackbone:max_units, Value: 316
132+
network_backbone:ShapedMLPBackbone:max_units, Value: 766
133+
network_backbone:ShapedMLPBackbone:mlp_shape, Value: 'diamond'
134+
network_backbone:ShapedMLPBackbone:num_groups, Value: 9
135+
network_backbone:ShapedMLPBackbone:output_dim, Value: 243
136+
network_backbone:ShapedMLPBackbone:use_dropout, Value: False
137+
network_backbone:__choice__, Value: 'ShapedMLPBackbone'
138+
network_embedding:__choice__, Value: 'NoEmbedding'
139+
network_head:__choice__, Value: 'fully_connected'
140+
network_head:fully_connected:activation, Value: 'tanh'
141+
network_head:fully_connected:num_layers, Value: 3
142+
network_head:fully_connected:units_layer_1, Value: 323
143+
network_head:fully_connected:units_layer_2, Value: 332
144+
network_init:KaimingInit:bias_strategy, Value: 'Normal'
145+
network_init:__choice__, Value: 'KaimingInit'
146+
optimizer:SGDOptimizer:lr, Value: 0.0024087824203718427
147+
optimizer:SGDOptimizer:momentum, Value: 0.418322885741585
148+
optimizer:SGDOptimizer:weight_decay, Value: 0.015250671878609713
149+
optimizer:__choice__, Value: 'SGDOptimizer'
150+
scaler:__choice__, Value: 'NoScaler'
151+
trainer:MixUpTrainer:alpha, Value: 0.4043218849947128
152+
trainer:MixUpTrainer:weighted_loss, Value: True
153+
trainer:__choice__, Value: 'MixUpTrainer'
154+
, ta_runs=3, ta_time_used=40.172093629837036, wallclock_time=46.57782244682312, budget=5.555555555555555), TrajEntry(train_perf=0.17543859649122806, incumbent_id=3, incumbent=Configuration:
155+
data_loader:batch_size, Value: 224
156+
encoder:__choice__, Value: 'OneHotEncoder'
157+
feature_preprocessor:KernelPCA:gamma, Value: 0.6217858094449208
158+
feature_preprocessor:KernelPCA:kernel, Value: 'rbf'
159+
feature_preprocessor:KernelPCA:n_components, Value: 4
160+
feature_preprocessor:__choice__, Value: 'KernelPCA'
161+
imputer:categorical_strategy, Value: 'constant_!missing!'
162+
imputer:numerical_strategy, Value: 'most_frequent'
163+
lr_scheduler:CosineAnnealingWarmRestarts:T_0, Value: 10
164+
lr_scheduler:CosineAnnealingWarmRestarts:T_mult, Value: 1.9483254217071713
165+
lr_scheduler:__choice__, Value: 'CosineAnnealingWarmRestarts'
166+
network_backbone:ShapedMLPBackbone:activation, Value: 'relu'
167+
network_backbone:ShapedMLPBackbone:max_units, Value: 948
133168
network_backbone:ShapedMLPBackbone:mlp_shape, Value: 'long_funnel'
134-
network_backbone:ShapedMLPBackbone:num_groups, Value: 6
135-
network_backbone:ShapedMLPBackbone:output_dim, Value: 425
169+
network_backbone:ShapedMLPBackbone:num_groups, Value: 13
170+
network_backbone:ShapedMLPBackbone:output_dim, Value: 761
136171
network_backbone:ShapedMLPBackbone:use_dropout, Value: False
137172
network_backbone:__choice__, Value: 'ShapedMLPBackbone'
138173
network_embedding:__choice__, Value: 'NoEmbedding'
139174
network_head:__choice__, Value: 'fully_connected'
140-
network_head:fully_connected:activation, Value: 'relu'
141-
network_head:fully_connected:num_layers, Value: 2
142-
network_head:fully_connected:units_layer_1, Value: 424
143-
network_init:OrthogonalInit:bias_strategy, Value: 'Zero'
144-
network_init:__choice__, Value: 'OrthogonalInit'
145-
optimizer:RMSpropOptimizer:alpha, Value: 0.6699215268945383
146-
optimizer:RMSpropOptimizer:lr, Value: 0.0009911973694107326
147-
optimizer:RMSpropOptimizer:momentum, Value: 0.11786464509318967
148-
optimizer:RMSpropOptimizer:weight_decay, Value: 0.04607537154099883
175+
network_head:fully_connected:num_layers, Value: 1
176+
network_init:KaimingInit:bias_strategy, Value: 'Zero'
177+
network_init:__choice__, Value: 'KaimingInit'
178+
optimizer:RMSpropOptimizer:alpha, Value: 0.19641480830908647
179+
optimizer:RMSpropOptimizer:lr, Value: 5.575047339285285e-05
180+
optimizer:RMSpropOptimizer:momentum, Value: 0.9188318520804722
181+
optimizer:RMSpropOptimizer:weight_decay, Value: 0.03663295762981204
149182
optimizer:__choice__, Value: 'RMSpropOptimizer'
150-
scaler:Normalizer:norm, Value: 'max'
151-
scaler:__choice__, Value: 'Normalizer'
152-
trainer:StandardTrainer:weighted_loss, Value: False
153-
trainer:__choice__, Value: 'StandardTrainer'
154-
, ta_runs=20, ta_time_used=229.40343284606934, wallclock_time=290.8017210960388, budget=50.0)]
155-
{'accuracy': 0.8670520231213873}
156-
| | Preprocessing | Estimator | Weight |
157-
|---:|:------------------------------------------------------------------|:----------------------------------------------------------------|---------:|
158-
| 0 | SimpleImputer,OneHotEncoder,Normalizer,NoFeaturePreprocessing | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.14 |
159-
| 1 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.1 |
160-
| 2 | None | SVC | 0.1 |
161-
| 3 | None | ExtraTreesClassifier | 0.08 |
162-
| 4 | None | KNNClassifier | 0.08 |
163-
| 5 | None | RFClassifier | 0.08 |
164-
| 6 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.06 |
165-
| 7 | SimpleImputer,OneHotEncoder,Normalizer,NoFeaturePreprocessing | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.06 |
166-
| 8 | SimpleImputer,OneHotEncoder,MinMaxScaler,PolynomialFeatures | embedding,ResNetBackbone,FullyConnectedHead,nn.Sequential | 0.06 |
167-
| 9 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.04 |
168-
| 10 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.04 |
169-
| 11 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.04 |
170-
| 12 | None | LGBMClassifier | 0.04 |
171-
| 13 | SimpleImputer,OneHotEncoder,NoScaler,NoFeaturePreprocessing | embedding,ShapedResNetBackbone,FullyConnectedHead,nn.Sequential | 0.02 |
172-
| 14 | SimpleImputer,NoEncoder,MinMaxScaler,TruncSVD | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.02 |
173-
| 15 | SimpleImputer,OneHotEncoder,StandardScaler,NoFeaturePreprocessing | embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.02 |
174-
| 16 | SimpleImputer,OneHotEncoder,StandardScaler,NoFeaturePreprocessing | embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.02 |
183+
scaler:__choice__, Value: 'StandardScaler'
184+
trainer:MixUpTrainer:alpha, Value: 0.7490557199071863
185+
trainer:MixUpTrainer:weighted_loss, Value: False
186+
trainer:__choice__, Value: 'MixUpTrainer'
187+
, ta_runs=4, ta_time_used=48.74088931083679, wallclock_time=56.56371068954468, budget=5.555555555555555)]
188+
{'accuracy': 0.861271676300578}
189+
| | Preprocessing | Estimator | Weight |
190+
|---:|:------------------------------------------------------------------|:-------------------------------------------------------------------|---------:|
191+
| 0 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.14 |
192+
| 1 | None | ExtraTreesClassifier | 0.12 |
193+
| 2 | None | KNNClassifier | 0.12 |
194+
| 3 | SimpleImputer,OneHotEncoder,Normalizer,NoFeaturePreprocessing | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.1 |
195+
| 4 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.08 |
196+
| 5 | SimpleImputer,OneHotEncoder,Normalizer,KitchenSink | no embedding,ShapedResNetBackbone,FullyConnectedHead,nn.Sequential | 0.08 |
197+
| 6 | SimpleImputer,OneHotEncoder,NoScaler,TruncSVD | no embedding,ShapedResNetBackbone,FullyConnectedHead,nn.Sequential | 0.08 |
198+
| 7 | SimpleImputer,NoEncoder,NoScaler,Nystroem | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.06 |
199+
| 8 | SimpleImputer,OneHotEncoder,MinMaxScaler,PolynomialFeatures | embedding,ResNetBackbone,FullyConnectedHead,nn.Sequential | 0.06 |
200+
| 9 | SimpleImputer,OneHotEncoder,StandardScaler,KernelPCA | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.04 |
201+
| 10 | SimpleImputer,NoEncoder,NoScaler,Nystroem | no embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.02 |
202+
| 11 | None | LGBMClassifier | 0.02 |
203+
| 12 | None | RFClassifier | 0.02 |
204+
| 13 | None | SVC | 0.02 |
205+
| 14 | SimpleImputer,OneHotEncoder,StandardScaler,NoFeaturePreprocessing | embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.02 |
206+
| 15 | SimpleImputer,OneHotEncoder,StandardScaler,NoFeaturePreprocessing | embedding,ShapedMLPBackbone,FullyConnectedHead,nn.Sequential | 0.02 |
175207
176208
177209
@@ -263,7 +295,7 @@ with AutoPyTorch
263295
264296
.. rst-class:: sphx-glr-timing
265297

266-
**Total running time of the script:** ( 9 minutes 17.694 seconds)
298+
**Total running time of the script:** ( 9 minutes 22.257 seconds)
267299

268300

269301
.. _sphx_glr_download_examples_example_tabular_classification.py:

refactor_development/_sources/examples/example_tabular_regression.rst.txt

Lines changed: 37 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ with AutoPyTorch
3636

3737
.. code-block:: none
3838
39-
<smac.runhistory.runhistory.RunHistory object at 0x7f41fc4762e0> [TrajEntry(train_perf=2147483648, incumbent_id=1, incumbent=Configuration:
39+
<smac.runhistory.runhistory.RunHistory object at 0x7ff7fa161700> [TrajEntry(train_perf=2147483648, incumbent_id=1, incumbent=Configuration:
4040
data_loader:batch_size, Value: 32
4141
encoder:__choice__, Value: 'NoEncoder'
4242
imputer:numerical_strategy, Value: 'mean'
@@ -65,7 +65,7 @@ with AutoPyTorch
6565
optimizer:__choice__, Value: 'AdamOptimizer'
6666
scaler:__choice__, Value: 'StandardScaler'
6767
trainer:__choice__, Value: 'StandardTrainer'
68-
, ta_runs=0, ta_time_used=0.0, wallclock_time=0.0018343925476074219, budget=0), TrajEntry(train_perf=0.0006981695502918939, incumbent_id=1, incumbent=Configuration:
68+
, ta_runs=0, ta_time_used=0.0, wallclock_time=0.001894235610961914, budget=0), TrajEntry(train_perf=0.0033956446141917285, incumbent_id=1, incumbent=Configuration:
6969
data_loader:batch_size, Value: 32
7070
encoder:__choice__, Value: 'NoEncoder'
7171
imputer:numerical_strategy, Value: 'mean'
@@ -94,8 +94,40 @@ with AutoPyTorch
9494
optimizer:__choice__, Value: 'AdamOptimizer'
9595
scaler:__choice__, Value: 'StandardScaler'
9696
trainer:__choice__, Value: 'StandardTrainer'
97-
, ta_runs=1, ta_time_used=7.188728332519531, wallclock_time=10.688534498214722, budget=5.555555555555555)]
98-
{'r2': 0.9998706896933107}
97+
, ta_runs=1, ta_time_used=8.826370239257812, wallclock_time=12.347334861755371, budget=5.555555555555555), TrajEntry(train_perf=0.16943683190326564, incumbent_id=2, incumbent=Configuration:
98+
data_loader:batch_size, Value: 324
99+
encoder:__choice__, Value: 'NoEncoder'
100+
imputer:numerical_strategy, Value: 'median'
101+
lr_scheduler:CosineAnnealingLR:T_max, Value: 58
102+
lr_scheduler:__choice__, Value: 'CosineAnnealingLR'
103+
network_backbone:ShapedMLPBackbone:activation, Value: 'relu'
104+
network_backbone:ShapedMLPBackbone:max_dropout, Value: 0.08110946585949352
105+
network_backbone:ShapedMLPBackbone:max_units, Value: 77
106+
network_backbone:ShapedMLPBackbone:mlp_shape, Value: 'diamond'
107+
network_backbone:ShapedMLPBackbone:num_groups, Value: 12
108+
network_backbone:ShapedMLPBackbone:output_dim, Value: 383
109+
network_backbone:ShapedMLPBackbone:use_dropout, Value: True
110+
network_backbone:__choice__, Value: 'ShapedMLPBackbone'
111+
network_embedding:__choice__, Value: 'NoEmbedding'
112+
network_head:__choice__, Value: 'fully_connected'
113+
network_head:fully_connected:activation, Value: 'relu'
114+
network_head:fully_connected:num_layers, Value: 4
115+
network_head:fully_connected:units_layer_1, Value: 376
116+
network_head:fully_connected:units_layer_2, Value: 67
117+
network_head:fully_connected:units_layer_3, Value: 333
118+
network_init:KaimingInit:bias_strategy, Value: 'Zero'
119+
network_init:__choice__, Value: 'KaimingInit'
120+
optimizer:RMSpropOptimizer:alpha, Value: 0.3647734535713807
121+
optimizer:RMSpropOptimizer:lr, Value: 0.00037624565303773076
122+
optimizer:RMSpropOptimizer:momentum, Value: 0.9118730100154911
123+
optimizer:RMSpropOptimizer:weight_decay, Value: 0.039774901898577665
124+
optimizer:__choice__, Value: 'RMSpropOptimizer'
125+
scaler:Normalizer:norm, Value: 'mean_abs'
126+
scaler:__choice__, Value: 'Normalizer'
127+
trainer:MixUpTrainer:alpha, Value: 0.6330663830411708
128+
trainer:__choice__, Value: 'MixUpTrainer'
129+
, ta_runs=17, ta_time_used=394.7455403804779, wallclock_time=445.0417649745941, budget=50.0)]
130+
{'r2': 0.9992392159989721}
99131
100132
101133
@@ -218,7 +250,7 @@ with AutoPyTorch
218250
219251
.. rst-class:: sphx-glr-timing
220252

221-
**Total running time of the script:** ( 8 minutes 33.280 seconds)
253+
**Total running time of the script:** ( 8 minutes 37.201 seconds)
222254

223255

224256
.. _sphx_glr_download_examples_example_tabular_regression.py:

0 commit comments

Comments
 (0)