-
Notifications
You must be signed in to change notification settings - Fork 51
Open
Description
Problem
The trian_and_predict function in app/services/gaze_tracker.py had inconsistent logic for determining which models should use GridSearchCV with hyperparameters versus simple model fitting:
- "Elastic Net" and "Support Vector Regressor" had hyperparameters defined in
config.pybut were using simple model fitting - "Random Forest Regressor" had no hyperparameters defined in
config.pybut was attempting to useGridSearchCV
Solution
Update the conditional logic in trian_and_predict to properly align model usage with hyperparameter availability:
- Models without hyperparameters (Linear Regression, Random Forest Regressor) now use simple fitting
- Models with hyperparameters (Elastic Net, SVR, Ridge, Lasso, Bayesian Ridge, SGD) now use
GridSearchCV
Impact
This change ensures that:
- Models with hyperparameter configurations properly utilize
GridSearchCVfor optimization - Models without hyperparameter configurations use efficient simple fitting
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels