Created
October 19, 2020 13:45
-
-
Save zaleslaw/59e1bc927487e4a7fec61ff4c894c17c to your computer and use it in GitHub Desktop.
Manual hyperparameter tuning in Apache Ignite ML
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Tune hyper-parameters with K-fold Cross-Validation on the split training set. | |
int[] pSet = new int[] {1, 2}; | |
int[] maxDeepSet = new int[] {1, 2, 3, 4, 5, 10, 20}; | |
int bestP = 1; | |
int bestMaxDeep = 1; | |
double avg = Double.MIN_VALUE; | |
for (int p : pSet) { | |
for (int maxDeep : maxDeepSet) { | |
Preprocessor<Integer, Vector> normalizationPreprocessor = new NormalizationTrainer<Integer, Vector>() | |
.withP(p) | |
.fit( | |
ignite, | |
dataCache, | |
minMaxScalerPreprocessor | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment