-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adaptive Windowing for Multi-Armed Bandits #71
base: develop
Are you sure you want to change the base?
Conversation
035259b
to
bdba9e4
Compare
0f98552
to
913968d
Compare
### Changes: * Added adaptive windowing mechanism to detect and handle concept drift in MAB models. * Introduced ActionsManager class to handle action memory and updates with configurable window sizes. * Refactored Model class hierarchy to support model resetting and memory management. * Added support for infinite and fixed-size windows with change detection via delta parameter. * Enhanced test coverage for adaptive windowing functionality across MAB variants.
913968d
to
92df9b1
Compare
window_length = len(rewards_window) | ||
if window_length < 2: | ||
return _NO_CHANGE_POINT | ||
cumulative_reward = np.cumsum(np.array(rewards_window), axis=0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I may be wrong but reward may be encoded -1/1 instead of 0/1 (in Hive I think). Did you make sure that the encoding was correct for cumsum?
NonNegativeInt | ||
The last change point for the given action. -1 if no change point is found. | ||
""" | ||
action_index = np.where([a == action_id for a in self.actions_memory])[0].tolist() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is action_memory?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would need further details in the code if possible. Thx! (and sorry)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Amazing work!
Changes: