From 0460985d38d137fd02db4919c66d316a83d2919e Mon Sep 17 00:00:00 2001 From: sanine-a Date: Thu, 10 Aug 2023 14:57:01 -0500 Subject: use average weight in mutation and add README.md --- src/genome/README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 src/genome/README.md (limited to 'src/genome/README.md') diff --git a/src/genome/README.md b/src/genome/README.md new file mode 100644 index 0000000..1135ed0 --- /dev/null +++ b/src/genome/README.md @@ -0,0 +1,12 @@ +src/genome +========== + +Genomes represent the neural network that underlies a creature. They are an array of tuples of the form `[ source, sink, weight ]`, where: + + * `source` is an integer in the range `[0, N - num_outputs)`, representing the index of the source neuron + * `sink` is an integer in the range `[num_inputs, N)`, representing the index of the sink neuron + * `weight` is a floating-point value in the range `[-4, 4]`, representing the weight of the connection + +`num_input` and `num_output` are fixed by the environment (as they are the input senses and output actions of the creature, respectively). +`N` is not fixed, but is instead determined by the maximum index present in the genome. As long as the maximum index is greater than or +equal to `num_input + num_output`, the genome is considered valid. -- cgit v1.2.1