public static class SARSCollector.UniformRandomSARSCollector extends SARSCollector
StateGenerator
by choosing actions uniformly at random.SARSCollector.UniformRandomSARSCollector
actions
Constructor and Description |
---|
SARSCollector.UniformRandomSARSCollector(Domain domain)
Initializes the collector's action set using the actions that are part of the domain.
|
SARSCollector.UniformRandomSARSCollector(java.util.List<Action> actions)
Initializes this collector's action set to use for collecting data.
|
Modifier and Type | Method and Description |
---|---|
SARSData |
collectDataFrom(State s,
RewardFunction rf,
int maxSteps,
TerminalFunction tf,
SARSData intoDataset)
Collects data from an initial state until either a terminal state is reached or until the maximum number of steps is taken.
|
collectNInstances
public SARSCollector.UniformRandomSARSCollector(Domain domain)
domain
- the domain containing the actions to usepublic SARSCollector.UniformRandomSARSCollector(java.util.List<Action> actions)
actions
- the action set to use for collecting data.public SARSData collectDataFrom(State s, RewardFunction rf, int maxSteps, TerminalFunction tf, SARSData intoDataset)
SARSCollector
collectDataFrom
in class SARSCollector
s
- the initial state from which data should be collected.rf
- the reward function from which rewards are tracks.maxSteps
- the maximum number of steps that can be taken.tf
- the terminal function that ends data collection.intoDataset
- the dataset into which data will be stored. If null, a dataset is created.