SIENTIAPDE-1231
SIENTIAPDE-1222 Enhance MLFlow and MLFlowRepository with model configuration support - Introduced `model_config` parameter in MLFlow methods to streamline model handling and configuration management. - Updated `retrain_model`, `transform`, and `predict` methods to accept `model_config` and `metadata` for improved flexibility and logging. - Added `detect_and_parse_datetime_index` method to handle datetime index parsing with enhanced error handling and logging. - Refactored model experiment creation to include transformation and prediction flavors, along with compression options. - Improved documentation and type hints across methods for better clarity and usability.
This commit is contained in:
@@ -225,6 +225,7 @@ class MLFlow(BaseActivity):
|
||||
metadata = input_data['metadata']
|
||||
data = DataFrame(input_data['data'])
|
||||
model_name = input_data['model_name']
|
||||
model_config = input_data.get('model_config', {})
|
||||
|
||||
self.info(f'Retraining model {model_name}...', metadata)
|
||||
|
||||
@@ -245,7 +246,8 @@ class MLFlow(BaseActivity):
|
||||
try:
|
||||
retrain_output, experiment = self.model_monitoring_repository.retrain_model(
|
||||
data=data,
|
||||
model_name=model_name
|
||||
model_name=model_name,
|
||||
model_config=model_config
|
||||
)
|
||||
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user