Fix Model Selection in batch_predict Endpoint#54
Open
sohampirale wants to merge 2 commits intoruxailab:mainfrom
Open
Fix Model Selection in batch_predict Endpoint#54sohampirale wants to merge 2 commits intoruxailab:mainfrom
sohampirale wants to merge 2 commits intoruxailab:mainfrom
Conversation
…-feature X-axis prediction and enables proper model selection for predict_new_data_simple function
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description:
This PR resolves an issue where the
batch_predictendpoint was ignoringuser-selected ML models and always using hardcoded Ridge regression models.
Fixes : #53
Changes Made:
models_gaze_engineereddictionary for X-axis models that operateon the 5-feature engineered input space.
modelsdictionary for Y-axis models that operateon the 2-feature input space.
batch_predictfunction to correctly pass model parametersto
predict_new_data_simple.model_name_Xandmodel_name_Yfor improved consistency and clarity.
Problem Solved:
Previously, users could select different ML models in the frontend, but the
batch_predictendpoint always defaulted to Ridge regression, ignoringthe selected options. This change ensures that the chosen models are
properly propagated through the backend and used for real-time gaze
prediction as intended.
Files Changed:
/app/routes/session.py— Updatedbatch_predictfunction/app/services/gaze_tracker.py— Addedmodels_gaze_engineereddictionary and updated
predict_new_data_simpleScreenshots : All models are working