17 #include "ann_activation_functions.h" 20 #include "properties.h" 30 extern bool g_use_AVX;
34 PROPERTY(mutation_normal_distribution,
37 "Use normal (instead of uniform) distribution for mutations");
39 PROPERTY(mutation_std_dev,
42 "Mutation standard deviation. Used if mutation_normal_distribution is true.");
44 PROPERTY(connection_range,
float, 64,
"Initial connection values range");
45 PROPERTY(connection_resolution,
float, 0.01f,
"Connection values resolution");
47 PROPERTY(sparse_weights,
50 "Generate sparse weights for the initial (random) population");
52 PROPERTY(weights_density,
55 "Probability of non-zero weights (if sparse_weights is true)");
65 return int(w / resolution) * resolution;
72 template <
class T,
class RND>
75 std::normal_distribution<T> dist(value, std_dev);
79 std::uniform_real_distribution<T> dist(-range, range);
float connection_resolution
"Connection values resolution"
Definition: ann_utils.h:45
void mutateValue(T &value, RND &rnd, T std_dev)
Mutate a value.
Definition: ann_utils.h:73
bool mutation_normal_distribution
"Use normal (instead of uniform) distribution for mutations"
Definition: ann_utils.h:37
The foundation for data structures supporting runtime reflection.
Definition: properties.h:388
float roundWeight(float w)
Ajust a value by rounding to Config::connection_resolution.
Definition: ann_utils.h:63
Artificial Neural Networks (ANN) building blocks.
Definition: ann_activation_functions.cpp:17
The ANN library configuration.
Definition: ann_utils.h:33
float connection_range
"Initial connection values range"
Definition: ann_utils.h:44