| Homepage | Demos | Overview | Downloads | Tutorials | Reference | Credits |
#include <karmedbandit.h>
Uses algorithms described in: The non-stochastic multi-armed bandit problem Auer, Cesa-Bianchi, Freund, and Schapire October 14, 2002
Definition at line 16 of file karmedbandit.h.
Public Member Functions | |
| karmedbanditExp3 (unsigned int k, double gammap) | |
| constructor, pass the number of arms | |
| unsigned int | decide () |
| returns the next choice, [0:k-1] | |
| void | reward (bool r) |
| call this if you want to reward (r==true) or penalize (r==false) the previous decision | |
| void | reset () |
| resets weights | |
| double | getGamma () |
| gets gamma parameter | |
| void | setGamma (double gammap) |
| sets gamma parameter | |
| unsigned int | getK () |
| gets k parameter | |
Protected Attributes | |
| std::vector< double > | w |
| the weights | |
| double | lastp |
| prob of last choice | |
| unsigned int | last |
| the last choice | |
| double | g |
| gamma | |
|
||||||||||||
|
constructor, pass the number of arms
Definition at line 19 of file karmedbandit.h. |
|
|
returns the next choice, [0:k-1]
Definition at line 24 of file karmedbandit.h. |
|
|
gets gamma parameter
Definition at line 66 of file karmedbandit.h. References g. |
|
|
gets k parameter
Definition at line 70 of file karmedbandit.h. References w. |
|
|
resets weights
Definition at line 61 of file karmedbandit.h. References w. |
|
|
call this if you want to reward (r==true) or penalize (r==false) the previous decision
Definition at line 53 of file karmedbandit.h. |
|
|
sets gamma parameter
Definition at line 68 of file karmedbandit.h. References g. |
|
|
gamma
Definition at line 75 of file karmedbandit.h. |
|
|
the last choice
Definition at line 74 of file karmedbandit.h. |
|
|
prob of last choice
Definition at line 73 of file karmedbandit.h. |
|
|
the weights
Definition at line 72 of file karmedbandit.h. |
|
Tekkotsu v1.5 |
Generated Fri Oct 10 15:56:18 2003 by Doxygen 1.3.4 |