SIENTIAPDE-1430: Introduce comprehensive integration testing with JSON-based scenarios and detailed README documentation. Enhance training workflow to support advanced model configurations, including polynomial regression with mandatory scaler validation. Ensure robust prediction handling by calculating training predictions (y_train_pred) before denormalization and automatically configuring datetime indices for time-series operations.

This commit is contained in:
Bruno Domingues
2025-12-18 17:05:10 -03:00
parent 6e8f87b2a3
commit 06fd08dc70
18 changed files with 631 additions and 37 deletions

View File

@@ -248,6 +248,12 @@ class TrainModelParams:
f'degree must be at least 2 for Polynomial Regression, got {self.degree}'
)
if self.model_name == 'Polynomial Regression' and self.scaler_name == 'None':
raise ValueError(
'scaler_name must be set (e.g., "Standard Scaler") for Polynomial Regression '
'to avoid numerical overflow with large feature values'
)
if self.model_name == 'Linear Regression' and self.degree != 1:
raise ValueError(f'degree must be 1 for Linear Regression, got {self.degree}')