energy_fault_detector.quick_fault_detection.optimization
- automatic_hyper_opt(config, train_data, normal_index, pca_code_size, num_trials)
Uses optuna to optimize the autoencoder hyperparameters ‘batch_size’, ‘epochs’, ‘learning_rate’, ‘layers’, and ‘code_size’ with respect to the MSE of the reconstructions on the validation data.
- Parameters:
config (Config) – Config object
train_data (pd.DataFrame) – DataFrame containing training data
normal_index (Union[pd.Series, None]) – Series containing boolean information about the training data status. Can also be omitted.
pca_code_size (int) – recommended code_size based on a 99% variance explaining PCA.
num_trials (int) – number of trials for the hyperparameter optimization
- Returns:
Dictionary containing parameter names as keys and optimized values as values.
- Return type: