Policies.GenericAggregation module¶
The GenericAggregation aggregation bandit algorithm: use a bandit policy A (master), managing several “slave” algorithms, \(A_1, ..., A_N\).
At every step, one slave algorithm A_i is selected, by the master policy A.
Then its decision is listen to, played by the master algorithm, and a feedback reward is received.
All slaves receive the observation (arm, reward).
The master also receives the same observation.
-
Policies.GenericAggregation.
random
() → x in the interval [0, 1).¶
-
class
Policies.GenericAggregation.
GenericAggregation
(nbArms, master=None, children=None, lower=0.0, amplitude=1.0)[source]¶ Bases:
Policies.BasePolicy.BasePolicy
The GenericAggregation aggregation bandit algorithm.
-
nbArms
= None¶ Number of arms.
-
lower
= None¶ Lower values for rewards.
-
amplitude
= None¶ Larger values for rewards.
-
last_choice
= None¶ Remember the index of the last child trusted for a decision.
-
children
= None¶ List of slave algorithms.
-
choiceFromSubSet
(availableArms='all')[source]¶ Trust one of the slave and listen to his choiceFromSubSet.
-
__module__
= 'Policies.GenericAggregation'¶
-
choiceIMP
(nb=1, startWithChoiceMultiple=True)[source]¶ Trust one of the slave and listen to his choiceIMP.
-