Class EpsilonGreedyExploration<T>
- Namespace
- AiDotNet.ReinforcementLearning.Policies.Exploration
- Assembly
- AiDotNet.dll
Epsilon-greedy exploration: with probability epsilon, select random action.
public class EpsilonGreedyExploration<T> : ExplorationStrategyBase<T>, IExplorationStrategy<T>
Type Parameters
TThe numeric type used for calculations.
- Inheritance
-
EpsilonGreedyExploration<T>
- Implements
- Inherited Members
Constructors
EpsilonGreedyExploration(double, double, double)
public EpsilonGreedyExploration(double epsilonStart = 1, double epsilonEnd = 0.01, double epsilonDecay = 0.995)
Parameters
Properties
CurrentEpsilon
public double CurrentEpsilon { get; }
Property Value
Methods
GetExplorationAction(Vector<T>, Vector<T>, int, Random)
Modifies or replaces the policy's action for exploration.
public override Vector<T> GetExplorationAction(Vector<T> state, Vector<T> policyAction, int actionSpaceSize, Random random)
Parameters
stateVector<T>The current state.
policyActionVector<T>The action suggested by the policy.
actionSpaceSizeintThe number of possible actions.
randomRandomRandom number generator for stochastic exploration.
Returns
- Vector<T>
The action to take after applying exploration.
Reset()
Resets internal state (e.g., for new episodes or training sessions).
public override void Reset()
Update()
Updates internal parameters (e.g., epsilon decay, noise reduction). Called after each training step.
public override void Update()