Skip to content

Commit

Permalink
continue keras core integration
Browse files Browse the repository at this point in the history
  • Loading branch information
PatReis committed Sep 21, 2023
1 parent 4c838d3 commit 89cd3d9
Show file tree
Hide file tree
Showing 6 changed files with 374 additions and 149 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
/training_core/results/*/*/scaler*.npz
/training_core/results/*/*/*.keras
/training_core/results/*/*/*.pickle
/training_core/results/*/*/scaler_*.json
/training_core/results/*/*/*.png
/training_core/results/*/*/*.weights.h5
/develop/
Expand Down
24 changes: 14 additions & 10 deletions training_core/hyper/hyper_esol.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,6 @@
"compile": {
"optimizer": {"class_name": "Adam", "config": {"learning_rate": 1e-03}},
"loss": "mean_absolute_error",
"metrics": [{"class_name": "kgcnn>ScaledMeanAbsoluteError",
"config": {"name": "mean_absolute_error"}},
{"class_name": "kgcnn>ScaledRootMeanSquaredError",
"config": {"name": "root_mean_squared_error"}}]
},
"scaler": {"class_name": "StandardLabelScaler", "module_name": "kgcnn.data.transform.scaler.standard",
"config": {"with_std": True, "with_mean": True, "copy": True}},
Expand Down Expand Up @@ -110,9 +106,13 @@
},
"compile": {
"optimizer": {"class_name": "Adam", "config": {"learning_rate": 0.0005}},
"loss": "mean_absolute_error",
"metrics": [{"class_name": "MeanAbsoluteError", "config": {"dtype": "float64"}},
{"class_name": "RootMeanSquaredError", "config": {"dtype": "float64"}}]
"loss": {"class_name": "kgcnn>MeanAbsoluteError", "config": {"dtype": "float64"}},
"metrics": [
{"class_name": "MeanAbsoluteError",
"config": {"dtype": "float64", "name": "scaled_mean_absolute_error"}},
{"class_name": "RootMeanSquaredError",
"config": {"dtype": "float64", "name": "scaled_root_mean_squared_error"}}
]
}
},
"data": {},
Expand Down Expand Up @@ -173,9 +173,13 @@
},
"compile": {
"optimizer": {"class_name": "Adam", "config": {"learning_rate": 5e-03}},
"loss": "mean_absolute_error",
"metrics": [{"class_name": "MeanAbsoluteError", "config": {"dtype": "float64"}},
{"class_name": "RootMeanSquaredError", "config": {"dtype": "float64"}}]
"loss": {"class_name": "kgcnn>MeanAbsoluteError", "config": {"dtype": "float64"}},
"metrics": [
{"class_name": "MeanAbsoluteError",
"config": {"dtype": "float64", "name": "scaled_mean_absolute_error"}},
{"class_name": "RootMeanSquaredError",
"config": {"dtype": "float64", "name": "scaled_root_mean_squared_error"}}
]
},
"scaler": {"class_name": "StandardLabelScaler", "module_name": "kgcnn.data.transform.scaler.standard",
"config": {"with_std": True, "with_mean": True, "copy": True}},
Expand Down
226 changes: 113 additions & 113 deletions training_core/results/ESOLDataset/GCN/GCN_ESOLDataset_score.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
OS: nt_win32
backend: jax
backend: tensorflow
cuda_available: 'False'
data_unit: mol/L
date_time: '2023-09-17 23:13:16'
device_id: '[0]'
device_memory: '[None]'
device_name: '[CpuDevice(id=0)]'
date_time: '2023-09-21 15:19:49'
device_id: '[LogicalDevice(name=''/device:CPU:0'', device_type=''CPU'')]'
device_memory: '[]'
device_name: '[{}]'
epochs:
- 800
- 800
Expand All @@ -21,134 +21,134 @@ learning_rate:
- 5.1727271056734025e-05
- 5.1727271056734025e-05
loss:
- 0.015133836306631565
- 0.014123351313173771
- 0.012902331538498402
- 0.011374394409358501
- 0.009070469997823238
- 0.014700263738632202
- 0.013396141119301319
- 0.011277776211500168
- 0.014349170960485935
- 0.01143904123455286
max_learning_rate:
- 0.0010000000474974513
- 0.0010000000474974513
- 0.0010000000474974513
- 0.0010000000474974513
- 0.0010000000474974513
max_loss:
- 1.51412832736969
- 1.5016895532608032
- 1.621337652206421
- 1.6178152561187744
- 1.5621287822723389
max_mean_absolute_error:
- 1.5357917547225952
- 1.5254226922988892
- 1.6039842367172241
- 1.6273863315582275
- 1.5761184692382812
max_root_mean_squared_error:
- 1.918033480644226
- 1.8930559158325195
- 2.0253753662109375
- 2.0398333072662354
- 1.9330493211746216
- 0.7641133069992065
- 0.7424471378326416
- 0.745108962059021
- 0.7430174350738525
- 0.7755040526390076
max_scaled_mean_absolute_error:
- 1.588536024093628
- 1.561904788017273
- 1.5957443714141846
- 1.5703060626983643
- 1.6362876892089844
max_scaled_root_mean_squared_error:
- 1.9688690900802612
- 1.9602442979812622
- 1.9943281412124634
- 1.9636659622192383
- 2.007398843765259
max_val_loss:
- 0.6922479271888733
- 0.656682014465332
- 0.9420702457427979
- 0.9071367979049683
- 0.566788375377655
max_val_mean_absolute_error:
- 0.6621466875076294
- 0.6777573823928833
- 0.8895420432090759
- 0.8363233208656311
- 0.566788375377655
max_val_root_mean_squared_error:
- 0.9364566802978516
- 0.8861027359962463
- 1.095849871635437
- 1.0854592323303223
- 0.7563754916191101
mean_absolute_error:
- 0.015225407667458057
- 0.01431678980588913
- 0.012784791179001331
- 0.01137979980558157
- 0.009164807386696339
- 0.37646061182022095
- 0.3912653625011444
- 0.3479542136192322
- 0.36888691782951355
- 0.3552423119544983
max_val_scaled_mean_absolute_error:
- 0.7251210808753967
- 0.8881072998046875
- 0.7157034873962402
- 0.7646072506904602
- 0.745976448059082
max_val_scaled_root_mean_squared_error:
- 1.0473613739013672
- 1.0891436338424683
- 0.9292598366737366
- 0.9997423887252808
- 0.9514607191085815
min_learning_rate:
- 5.1727271056734025e-05
- 5.1727271056734025e-05
- 5.1727271056734025e-05
- 5.1727271056734025e-05
- 5.1727271056734025e-05
min_loss:
- 0.015133836306631565
- 0.014123351313173771
- 0.012902331538498402
- 0.011374394409358501
- 0.009070469997823238
min_mean_absolute_error:
- 0.015225407667458057
- 0.01431678980588913
- 0.012784791179001331
- 0.01137979980558157
- 0.009164807386696339
min_root_mean_squared_error:
- 0.06683880090713501
- 0.06312859803438187
- 0.05362653359770775
- 0.04734046384692192
- 0.036896370351314545
- 0.012154624797403812
- 0.011357437819242477
- 0.011277776211500168
- 0.010577977634966373
- 0.011433130130171776
min_scaled_mean_absolute_error:
- 0.025809645652770996
- 0.02442621998488903
- 0.024177635088562965
- 0.022636910900473595
- 0.02436179481446743
min_scaled_root_mean_squared_error:
- 0.06934428960084915
- 0.08029545098543167
- 0.07034015655517578
- 0.06601940840482712
- 0.047117479145526886
min_val_loss:
- 0.48386263847351074
- 0.4261545240879059
- 0.4654020071029663
- 0.4218893349170685
- 0.41208165884017944
min_val_mean_absolute_error:
- 0.4786438047885895
- 0.4198172688484192
- 0.43209898471832275
- 0.4470202922821045
- 0.41208165884017944
min_val_root_mean_squared_error:
- 0.7219273447990417
- 0.5574941635131836
- 0.6329845786094666
- 0.6092503666877747
- 0.5708439946174622
- 0.24208006262779236
- 0.20231576263904572
- 0.23847146332263947
- 0.2084009349346161
- 0.21117988228797913
min_val_scaled_mean_absolute_error:
- 0.5018375515937805
- 0.4533664286136627
- 0.45695292949676514
- 0.4631824493408203
- 0.44345852732658386
min_val_scaled_root_mean_squared_error:
- 0.7365378737449646
- 0.601824939250946
- 0.6605672240257263
- 0.6202259659767151
- 0.6119416356086731
model_class: make_model
model_name: GCN
model_version: 2023.09.30
model_version: '2023-09-30'
multi_target_indices: null
number_histories: 5
root_mean_squared_error:
- 0.0669766366481781
- 0.06312859803438187
- 0.05363968387246132
- 0.04734046384692192
- 0.036896370351314545
scaled_mean_absolute_error:
- 0.030948080122470856
- 0.028739066794514656
- 0.024177635088562965
- 0.03059293143451214
- 0.02436179481446743
scaled_root_mean_squared_error:
- 0.07311341911554337
- 0.0803653746843338
- 0.0703764334321022
- 0.0688292384147644
- 0.04794161394238472
seed: 42
time_list:
- '0:08:57.131873'
- '0:08:51.857452'
- '0:08:53.591406'
- '0:08:58.488845'
- '0:08:53.481242'
- '0:04:41.873803'
- '0:05:37.398287'
- '0:09:14.968248'
- '0:13:34.497785'
- '0:17:04.563790'
val_loss:
- 0.5129508972167969
- 0.46785056591033936
- 0.5138030052185059
- 0.47180789709091187
- 0.4505428373813629
val_mean_absolute_error:
- 0.5046505331993103
- 0.4409920573234558
- 0.4513247311115265
- 0.46418580412864685
- 0.4505428373813629
val_root_mean_squared_error:
- 0.732132613658905
- 0.5994848012924194
- 0.6798126697540283
- 0.6416217684745789
- 0.6304311752319336
- 0.2544833719730377
- 0.20889292657375336
- 0.27367258071899414
- 0.2199447751045227
- 0.2312503159046173
val_scaled_mean_absolute_error:
- 0.5288447737693787
- 0.4802064001560211
- 0.5416200160980225
- 0.48129501938819885
- 0.48560455441474915
val_scaled_root_mean_squared_error:
- 0.7877314686775208
- 0.6519739627838135
- 0.7435009479522705
- 0.6704958081245422
- 0.6541447639465332
2 changes: 1 addition & 1 deletion training_core/results/ESOLDataset/GCN/GCN_hyper.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"model": {"class_name": "make_model", "module_name": "kgcnn.literature_core.GCN", "config": {"name": "GCN", "inputs": [{"shape": [null, 41], "name": "node_attributes", "dtype": "float32"}, {"shape": [null, 1], "name": "edge_weights", "dtype": "float32"}, {"shape": [null, 2], "name": "edge_indices", "dtype": "int64"}, {"shape": [], "name": "total_nodes", "dtype": "int64"}, {"shape": [], "name": "total_edges", "dtype": "int64"}], "cast_disjoint_kwargs": {"padded_disjoint": true}, "input_node_embedding": {"input_dim": 95, "output_dim": 64}, "input_edge_embedding": {"input_dim": 25, "output_dim": 1}, "gcn_args": {"units": 140, "use_bias": true, "activation": "relu"}, "depth": 5, "verbose": 10, "output_embedding": "graph", "output_mlp": {"use_bias": [true, true, false], "units": [140, 70, 1], "activation": ["relu", "relu", "linear"]}, "output_scaling": {"name": "StandardLabelScaler"}}}, "training": {"fit": {"batch_size": 32, "epochs": 800, "validation_freq": 10, "verbose": 2, "callbacks": [{"class_name": "kgcnn>LinearLearningRateScheduler", "config": {"learning_rate_start": 0.001, "learning_rate_stop": 5e-05, "epo_min": 250, "epo": 800, "verbose": 0}}]}, "compile": {"optimizer": {"class_name": "Adam", "config": {"learning_rate": 0.001}}, "loss": "mean_absolute_error", "metrics": [{"class_name": "MeanAbsoluteError", "config": {"dtype": "float64"}}, {"class_name": "RootMeanSquaredError", "config": {"dtype": "float64"}}]}, "scaler": {"class_name": "StandardLabelScaler", "module_name": "kgcnn.data.transform.scaler.standard", "config": {"with_std": true, "with_mean": true, "copy": true}}}, "dataset": {"class_name": "ESOLDataset", "module_name": "kgcnn.data.datasets.ESOLDataset", "config": {}, "methods": [{"set_attributes": {}}, {"set_train_test_indices_k_fold": {"n_splits": 5, "random_state": 42, "shuffle": true}}, {"map_list": {"method": "normalize_edge_weights_sym"}}, {"map_list": {"method": "count_nodes_and_edges"}}]}, "data": {"data_unit": "mol/L"}, "info": {"postfix": "", "postfix_file": "", "kgcnn_version": "4.0.0"}}
{"model": {"class_name": "make_model", "module_name": "kgcnn.literature_core.GCN", "config": {"name": "GCN", "inputs": [{"shape": [null, 41], "name": "node_attributes", "dtype": "float32"}, {"shape": [null, 1], "name": "edge_weights", "dtype": "float32"}, {"shape": [null, 2], "name": "edge_indices", "dtype": "int64"}, {"shape": [], "name": "total_nodes", "dtype": "int64"}, {"shape": [], "name": "total_edges", "dtype": "int64"}], "cast_disjoint_kwargs": {"padded_disjoint": false}, "input_node_embedding": {"input_dim": 95, "output_dim": 64}, "input_edge_embedding": {"input_dim": 25, "output_dim": 1}, "gcn_args": {"units": 140, "use_bias": true, "activation": "relu"}, "depth": 5, "verbose": 10, "output_embedding": "graph", "output_mlp": {"use_bias": [true, true, false], "units": [140, 70, 1], "activation": ["relu", "relu", "linear"]}}}, "training": {"fit": {"batch_size": 32, "epochs": 800, "validation_freq": 10, "verbose": 2, "callbacks": [{"class_name": "kgcnn>LinearLearningRateScheduler", "config": {"learning_rate_start": 0.001, "learning_rate_stop": 5e-05, "epo_min": 250, "epo": 800, "verbose": 0}}]}, "compile": {"optimizer": {"class_name": "Adam", "config": {"learning_rate": 0.001}}, "loss": "mean_absolute_error"}, "scaler": {"class_name": "StandardLabelScaler", "module_name": "kgcnn.data.transform.scaler.standard", "config": {"with_std": true, "with_mean": true, "copy": true}}}, "dataset": {"class_name": "ESOLDataset", "module_name": "kgcnn.data.datasets.ESOLDataset", "config": {}, "methods": [{"set_attributes": {}}, {"set_train_test_indices_k_fold": {"n_splits": 5, "random_state": 42, "shuffle": true}}, {"map_list": {"method": "normalize_edge_weights_sym"}}, {"map_list": {"method": "count_nodes_and_edges"}}]}, "data": {"data_unit": "mol/L"}, "info": {"postfix": "", "postfix_file": "", "kgcnn_version": "4.0.0"}}
Loading

0 comments on commit 89cd3d9

Please sign in to comment.