Structure for simplifying the transmission of LearningParameters to functions.
More...
#include <learningParameters.h>
Structure for simplifying the transmission of LearningParameters to functions.
When modifying this structure and its comments, you must also update the functions in the ParameterParser namespace.
◆ archiveSizeComment
const std::string Learn::LearningParameters::archiveSizeComment |
|
inlinestatic |
Initial value:=
"// Number of recordings held in the Archive.\n"
"// \"archiveSize\" : 50, // Default value"
JSon comment.
◆ archivingProbabilityComment
const std::string Learn::LearningParameters::archivingProbabilityComment |
|
inlinestatic |
Initial value:=
"// Probability of archiving the result of each Program "
"execution.\n"
"// \"archivingProbability\" : 0.05, // Default value"
JSon comment.
◆ doValidation
bool Learn::LearningParameters::doValidation = false |
Boolean set to true if the user wants a validation after each training, and false otherwise
◆ doValidationComment
const std::string Learn::LearningParameters::doValidationComment |
|
inlinestatic |
Initial value:=
"// Boolean used to activate an evaluation of the surviving roots "
"in validation\n"
"// mode after the training at each generation.\n"
"// \"doValidation\" : false, // Default value"
JSon comment.
◆ maxNbActionsPerEval
uint64_t Learn::LearningParameters::maxNbActionsPerEval = 1000 |
Maximum number of actions performed on the learning environment during the each evaluation of a root
◆ maxNbActionsPerEvalComment
const std::string Learn::LearningParameters::maxNbActionsPerEvalComment |
|
inlinestatic |
Initial value:=
"// Maximum number of actions performed on the learning "
"environment during the\n"
"// each evaluation of a root.\n"
"// \"maxNbActionsPerEval\" : 1000, // Default value"
JSon comment.
◆ maxNbEvaluationPerPolicy
size_t Learn::LearningParameters::maxNbEvaluationPerPolicy = 1000 |
Maximum number of times a given policy (i.e. a root TPGVertex) is evaluated.
◆ maxNbEvaluationPerPolicyComment
const std::string Learn::LearningParameters::maxNbEvaluationPerPolicyComment |
|
inlinestatic |
Initial value:=
"// Maximum number of times a given root is evaluated."
"After this number is\n"
"// reached, possibly after several generations, the score of the "
"root will be\n"
"// fixed, and no further evaluation will be done.\n"
"// \"maxNbEvaluationPerPolicy\" : 1000, // Default value"
JSon comment.
◆ mutation
MutationParameters for controlling stochastic aspects of the learning process.
◆ nbGenerationsComment
const std::string Learn::LearningParameters::nbGenerationsComment |
|
inlinestatic |
Initial value:=
"// Number of generations of the training.\n"
"// \"nbGenerations\" : 500, // Default value"
JSon comment.
◆ nbIterationsPerJob
size_t Learn::LearningParameters::nbIterationsPerJob = 1 |
Number of evaluations done for each job.
In some situations where the environments is not determinist, i.e. if the agent does exactly the same thing at the same moment but he can still make different scores in different runs, then it can be a good thing to evaluate several times a single job. It will statistically be more representative of the job.
Note than in LearningAgent and ParallelLearningAgent it is currently unused as the number of eval per job will simply be nbIterationsPerPolicyEvaluation.
The default value is to 1, that means a given job will be evaluated a single time and there will be as many jobs as nbIterationsPerPolicyEvaluation.
◆ nbIterationsPerJobComment
const std::string Learn::LearningParameters::nbIterationsPerJobComment |
|
inlinestatic |
Initial value:=
"// [Only used in AdversarialLearningAgent.]\n"
"// Number of times each job is evaluated in the learning "
"process.\n"
"// Each root may belong to several jobs, hence this parameter "
"should be lower\n"
"// than the nbIterationsPerPolicyEvaluation parameter.\n"
"// \"nbIterationsPerJob\" : 1, // Default value"
JSon comment.
◆ nbIterationsPerPolicyEvaluation
uint64_t Learn::LearningParameters::nbIterationsPerPolicyEvaluation = 5 |
Number of evaluation of each policy per generation.
In LearningAgent and ParallelLearningAgent it is just the number of times the evaluations are repeated (that can produce a more representative result in non-deterministic environments). In adversarial mode, that represents the minimum number of evaluation of each root. Each root will be evaluated in several jobs, each job can be evaluated several times, but the total number of times a root appears in an evaluation will be nbIterationsPerPolicyEvaluation or a bit higher.
◆ nbIterationsPerPolicyEvaluationComment
const std::string Learn::LearningParameters::nbIterationsPerPolicyEvaluationComment |
|
inlinestatic |
Initial value:=
"// Number of evaluation of each root per generation.\n"
"// \"nbIterationsPerPolicyEvaluation\" : 5, // Default value"
JSon comment.
◆ nbProgramConstantComment
const std::string Learn::LearningParameters::nbProgramConstantComment |
|
inlinestatic |
Initial value:=
"// Number of Constant available in each Program.\n"
"// \"nbProgramConstant\" : 0, // Default value"
JSon comment.
◆ nbRegistersComment
const std::string Learn::LearningParameters::nbRegistersComment |
|
inlinestatic |
Initial value:=
"// Number of registers for the Program execution.\n"
"// \"nbRegisters\" : 8, // Default value"
JSon comment.
◆ nbThreads
size_t Learn::LearningParameters::nbThreads = std::thread::hardware_concurrency() |
Number of threads (ParallelLearningAgent only)
Integer parameter controlling the number of threads used for parallel execution. Possible values are:
- default : Let the runtime decide using std::thread::hardware_concurrency().
0
or 1
: Do not use parallelism.
n > 1
: Set the number of threads explicitly.
◆ nbThreadsComment
const std::string Learn::LearningParameters::nbThreadsComment |
|
inlinestatic |
Initial value:=
"// [Only used in ParallelLearningAgent and child classes.]\n"
"// Number of threads used for the training process.\n"
"// When undefined in the json file, this parameter is "
"automatically set to the\n"
"// number of cores of the CPU.\n"
"// /* \"nbThreads\" : 0,*/ // Commented by default"
JSon comment.
◆ ratioDeletedRoots
double Learn::LearningParameters::ratioDeletedRoots = 0.5 |
Percentage of deleted (and regenerated) root TPGVertex at each generation.
◆ ratioDeletedRootsComment
const std::string Learn::LearningParameters::ratioDeletedRootsComment |
|
inlinestatic |
Initial value:=
"// Percentage of deleted (and regenerated) root TPGVertex at each "
"generation.\n"
"// \"ratioDeletedRoots\" : 0.5, // Default value"
JSon comment.
The documentation for this struct was generated from the following file: