optunaz.utils package
Subpackages
- optunaz.utils.enums package
- Submodules
- optunaz.utils.enums.building_configuration_enum module
- optunaz.utils.enums.configuration_enum module
- optunaz.utils.enums.interface_enum module
- optunaz.utils.enums.model_runner_enum module
- optunaz.utils.enums.objective_enum module
- optunaz.utils.enums.optimization_configuration_enum module
- optunaz.utils.enums.prediction_configuration_enum module
- optunaz.utils.enums.return_values_enum module
- optunaz.utils.enums.visualization_enum module
- Module contents
- optunaz.utils.preprocessing package
Submodules
optunaz.utils.files_paths module
optunaz.utils.load_json module
optunaz.utils.mlflow module
- class optunaz.utils.mlflow.MLflowCallback(trial_number_offset, tracking_uri=None, optconfig=None)[source]
Bases:
object
Callback to track Optuna trials with MLflow.
This callback adds Optuna-tracked information to MLflow. The MLflow experiment will be named after the Optuna study name. MLflow runs will be named after Optuna trial numbers.
- trial_number_offset
- tracking_uri = None
The URI of the MLflow tracking server. Please refer to mlflow.set_tracking_uri for more details.
- optconfig = None
optunaz.utils.retraining module
- exception optunaz.utils.retraining.NoRetrainingDataConvention(task, message='input-directory file [{0}] does not contain a date format %Y-%m-%d')[source]
Bases:
Exception
Raised if a file in input-directory does not follow the %Y-%m-%d convention
- exception optunaz.utils.retraining.NoNewRetrainingData[source]
Bases:
Exception
Raised if no new retraining data is available
- exception optunaz.utils.retraining.NoDifferingRetrainingData[source]
Bases:
Exception
Raised if no different retraining data is available between previous & current time bins
- exception optunaz.utils.retraining.RetrainingHeadersIssue[source]
Bases:
Exception
Raised when issue with retraining headers in a file (columns unknown)
- exception optunaz.utils.retraining.RetrainingIsAlreadyProcessed(task, message='Retraining[{0}] already processed')[source]
Bases:
Exception
Raised when retraining is processed
- exception optunaz.utils.retraining.RetrainingIsLocked(task, message='Retraining[{0}] is locked')[source]
Bases:
Exception
Raised when retraining is locked
- exception optunaz.utils.retraining.TemporalPredsPredicted(task, message='Retraining[{0}] code is predicted')[source]
Bases:
Exception
Raised when a temporal prediction is already predicted.
- exception optunaz.utils.retraining.NoPreviousModel(prev_model_name, message='No previous model found for [{0}]')[source]
Bases:
Exception
Raised when no previous model exists for a retraining point
- exception optunaz.utils.retraining.SamePreviousModel(task, message='Retraining[{0}] already processed')[source]
Bases:
Exception
Raised when a temporal prediction would be for the same (identical) model training
- exception optunaz.utils.retraining.TimepointSkipped(task, message='Retraining[{0}] set to be skipped')[source]
Bases:
Exception
Raised when a timepoint should be skipped
- exception optunaz.utils.retraining.SlurmNoLog[source]
Bases:
Exception
Raised when a SLURM job file is not present for submitted itcode jobs
- exception optunaz.utils.retraining.SlurmTimeLimitExceeded[source]
Bases:
Exception
Raised when a past SLURM job time was exceeded
- exception optunaz.utils.retraining.SlurmMemoryExceeded[source]
Bases:
Exception
Raised when a past SLURM memory was exceeded
optunaz.utils.schema module
optunaz.utils.tracking module
- class optunaz.utils.tracking.TrackingData(trial_number, trial_value, scoring, trial_state, all_cv_test_scores, buildconfig, algorith_hash)[source]
Bases:
object
Dataclass defining internal tracking format
- trial_number
- trial_value
- scoring
- trial_state
- all_cv_test_scores
- buildconfig
- algorith_hash
- class optunaz.utils.tracking.InternalTrackingCallback(optconfig, trial_number_offset)[source]
Bases:
object
Callback to track (log) Optimization progress using internal tracking format
- optconfig
- trial_number_offset
- class optunaz.utils.tracking.Datapoint(smiles: str, expected: float, predicted: float)[source]
Bases:
object
- smiles
- expected
- predicted
- class optunaz.utils.tracking.Calpoint(bin_edges: float, frac_true: float, frac_pred: float)[source]
Bases:
object
- bin_edges
- frac_true
- frac_pred