Neural Network Encoding Methods Review
Neural Network Encoding Methods Review
3
5
|
N1: N2: N3: N4: 1, 2 N5: 1, 2, 3
2
3
5
|
6
connecting two existing nodes with a new one. Another A) 5 0.2 0.1 B) 3
possibility is to add a new edge, what means creating a i2 o2
4
new connection gene from one existing node to another. Number of
To fine-tune the weights of a created network, the hidden neurons 5
algorithm can also mutate the weights in the “edge Figure 9. Simple encoding of feed-forward network with one hidden
chromosome”. layer and the back-propagation learning algorithm. Chromosome (A)
Crossover in NEAT uses the aforementioned contains the number of hidden neurons and parameters of the learning
algorithm. Final network (B) for the example genome has 5 neurons in
historical markers to align genes. It improves the the hidden layer.
validity of the offspring, since only compatible
modifications are crossed-over (Figure 8). B. Layer-based encoding
1 => 4 2 => 4 3 => 4 2 => 5 5 => 4 1 => 5
For some neural network applications it can be
Parent 1 Innov 1 Innov 2 Innov 3 Innov 4 Innov 5 Innov 8
DISAB
assumed that the optimal solution will be found as a
1 => 4 2 => 4 3 => 4 2 => 5 5 => 4 5 => 6 6 => 4 3 => 5 1 => 6
multi-layer feed-forward network. In that case, it might
Parent 2 Innov 1 Innov 2 Innov 3 Innov 4 Innov 5 Innov 6 Innov 7 Innov 9 Innov 10
DISAB DISAB
be useful to apply the layer-based encoding. This
encoding supposes a multi-layer feed-forward
architecture and the back-propagation learning
Parent 1 1 => 4 2 => 4 3 => 4 2 => 5 5 => 4
algorithm. The genotype of this encoding contains back-
1 => 5
(aligned) Innov 1 Innov 2 Innov 3 Innov 4 Innov 5 Innov 8 propagation learning parameters (learning rate and
DISAB
momentum) and parameters of a variable number of
1 => 4 2 => 4 3 => 4 2 => 5 5 => 4 5 => 6 6 => 4 3 => 5 1 => 6
Parent 2 Innov 1 Innov 2 Innov 3 Innov 4 Innov 5 Innov 6 Innov 7 Innov 9 Innov 10 individual layers (Figure 10). Layer parameters contain
(aligned) DISAB DISAB
(disjoint) (disjoint) (excess) (excess)
information about the number of neurons in the layer
and information about the output connections (to the
1 => 4 2 => 4 3 => 4 2 => 5 5 => 4 5 => 6 6 => 4 1 => 5 3 => 5 1 => 6
Offspring Innov 1 Innov 2 Innov 3 Innov 4 Innov 5 Innov 6 Innov 7 Innov 8 Innov 9 Innov 10 following layer) and the input connections (from
DISAB DISAB
previous layers).
Figure 8. Aligned crossover of networks encoded by NEAT encoding.
An one-point crossover operator is used to exchange
III. PARAMETRIC ENCODING layers between individuals. A two-point crossover
operator is used to exchange bigger parts of genotypes
The following approaches describe networks as between individuals. To maintain the consistency of the
genes with a set of parameters, from which the network chromosomes, they are cut at the layer level.
is created by given rules. In this case, the topology of This encoding uses relative mutation operator, which
the network can be assumed from the problem domain, slowly changes genes of randomly chosen individuals.
but the evolutionary algorithm is used to fine-tune the Besides the minimum and the maximum value, all genes
setting of the network. contain also the maximum amount of change.
A. Simple feedforward network encoding
B) Learning Rate Momentum
Typical example of parametric encoding is a simple
encoding of a feed-forward network with one hidden Network
A) Layer 1 Layer N
layer. When designing this kind of network, the back- Parameters
A) PAR END B) 0 0 0 3
SEQ PAR REC Embedded Cellular Graph
0 Figure 14. Basic elements of a cellular graph grammar encoding. (A)
REC END displays a general rewrite rule with non-terminal on the left side and a
Output Output Output Output
cellular graph on the right side with possible connections for source
Figure 13. Example of a cellular encoded network. Instructions of the
and target labels. When NB in the rewrite rule is replaced by another
genetic tree (A) are sequentially applied to the nodes of the growing
cellular graph, the embedded cellular graph is connected to the outer
network (B). Basic instructions include SEQ – serial splitting of node
by similar source and target labes (B).
(B.2), PAR – parallel splitting of node (B.3), REC – repeated
application of genetic tree instructions (B.4) and END – replacing
node by terminal and finishing its growth (e.g. node 0 in B.2). To make the encoding flexible enough to handle the
most possible situations during evolution, all rewrite
Crossover and mutation operation are applied rules evolved by grammar have added sets of labels.
according to the common GP paradigm. That means that Then, when embedding a new sub-graph into actually
when mutating a chromosome tree, a random node of growing network, all the connections are created by the
the tree is chosen and it is replaced by a different similarity of the labels on appropriate positions. This
instruction of the same arity, or the whole sub-tree embedding principle is shown on Figure 14. In the top
under it is replaced by a random sub-tree. Crossover is part (A), there is a single cellular grammar production
done by exchanging random sub-trees between rule. NG on the left side is a label a hyper-edge to
chromosomes of two individuals. rewrite. The right side of the rule is a cellular graph, by
which the hyper-edge will be replaced. In this graph, b
D. Cellular graph grammars
denotes begin nodes, e denotes end nodes, TA is a
The cellular graph grammar approach to evolve terminal symbol and NB is a label of another non-
network topology proposed in [13] is also based on the terminal hyper-edge (of course, the cellular graph can
similarity of the network growing with the biological contain a different set of terminals and non-terminals).
processes of growth. However, instead of a fixed set of As mentioned above, after the replacement of a hyper-
rules (like in the cellular encoding), also the grammar edge, the embedded cellular graph is connected to the
generating the networks evolves through generations. outer graph through its begin and end nodes by the
Another notable difference is the use of hyper-edge similar source (s) and target (t) labels. Direction and
replacement instead of node replacement. That means available levels of connections are displayed by gray
that in the beginning of the growth process, there exist arrows in the cellular graph. Part (B) of the image
only one hyper-edge connecting inputs with outputs, shows the way of label matching in detail. Two labels
instead of a cell connecting them. Then all of the rewrite are matched (and then connected), when their Euclidian
rules are applied on hyper-edges and the final network distance is smaller than a given threshold.
nodes (neurons) are also created by replacing a hyper- In this approach, only the genetic operator of
edge with a grammar terminal. mutation has been left. That is caused by using only a
single grammar for the whole population and the
individuals defined only by the label of the starting
hyper-edge. Then the movement of genetic material
caused by the crossover operator is also handled by the
operator of mutation, because mutating one production
rule modifies all individuals using that rule in their
growth.
The operator of mutation operates on a single [9] Kitano, H. “Designing neural networks using genetic algorithms
with graph generation systems,” Complex Systems, vol. 4, issue
production rule, where it modifies one of the following 4, pp. 461-476, 1990.
lists: list of non-terminals, list of terminals, list of begin [10] Jacob Ch. and Rehder J. “Evolution of neural net architectures
nodes and list of end nodes. It randomly removes an by a hierarchical grammar-based genetic system,” Proc.
existing item from the list or adds a new item to it. International Conference on Artificial Neural Networks and
Genetic Algorithms, pp. 72-79, 1993.
V. CONCLUSIONS [11] Stanley K. [Link] Miikkulainen R. “Evolving neural networks
through augmenting topologies,” Evolutionary Computation,
As can be seen along this paper , the differences in MIT Press, vol. 10, number 2, pp. 99-127, 2002.
the three types of encoding methods are quite [12] Gruau F. 1994. “Neural network synthesis using cellular
significant. Each of them is predetermined to solve encoding and the genetic algorithm.” Dissertation, l’Ecole
different kind of problems. Among them, the most Normale Superieure de Lyon , France, 159 p.
flexible one seems to be cellular encoding and cellular [13] Luerssen M. “Experimental Investigations into Graph Grammar
Evolution : A Novel Approach to Evolutionary Design.
graph grammar-based encoding. However, the Saarbrucken.” Saarbrucken : VDM Verlag Dr. Müller, 2009,
implementation of such sophisticated algorithms and 204 p.
their need for modularity might be a big overhead for
real use in automation and control industry. For control AUTHOR BIOGRAPHIES
purposes, well known topologies are typically used and
their parameters can be found by an evolutionary JOZEF FEKIAČ is a postgraduate
algorithm using the parametric encoding. student at Tomas Bata University in
When a network designer does not design the Zlin. Topic of his thesis is the use of
network directly and he decides to use evolutionary artificial life methods in optimisation.
heuristics, he is facing the problem of selecting the right His research is concerned in modular
method of encoding; what is still some kind of “black neural network evolution for inteligent agent control
art” and has to be done intuitively. However, we believe and synthesis of networks used in stegoanalysis. His e-
that this paper will make the process of choosing the mail address is: jfekiac@[Link]
right method more straightforward.
Presently we are working on a hybrid method of IVAN ZELINKA was born in Czech
network encoding, combining the standard GP approach Republic, and went to the Technical
of the cellular encoding and the flexibility of the cellular University of Brno, where he studied
graph grammar evolution to design large modular technical cybernetics and obtained his
networks that could be described by a single compact degree in 1995. He obtained his Ph.D.
genotype. degree in Technical Cybernetics in 2001
at Tomas Bata University in Zlin, He is now a Professor
ACKNOWLEDGMENT at the Technical University in Ostrava, Czech Republic.
This research is supported by the Internal Grant His specialization is artificial intelligence and its
Agency of Tomas Bata University under the project interdisciplinary use and applications. His e-mail
Artificial Life in Optimization No. IGA/28/FAI/10/D address is: [Link]@[Link] and his Web-site is
and by the European Regional Development Fund under at: [Link]
the Project CEBIA-Tech No. CZ.1.05/2.1.00/03.0089.
JUAN C. BURGUILLO received the
REFERENCES [Link]. degree in Telecommunication
[1] Hussain T. S. and Browse R. A. “Genetic Encoding of Neural Engineering in 1995, and the Ph.D.
Networks using Attribute Grammars,”
degree in Telematics (cum laude) in
[2] Boers, E. J. W. and Kuiper H. 1992. “Biological metaphors and
the design of modular artificial neural networks.” Mater’s thesis,
2001; both at the University of Vigo,
Leiden University, the Netherlands, 104p. Spain. He is currently an associate
[3] Lindenmayer, A. and Prusinkiewicz P. “The algorithmic beauty professor at the Department of Telematic Engineering at
of plants.” New York: Springer-Verlag, 1990, 240 p. the same university. He has participated in several R&D
[4] Holland, J. H. “Adaptation in natural and artificial systems.” projects in the areas of Telecommunications and
Ann Arbor: University of Michigan Press, 1975, 228 p. Software Engineering, and has published more than one
[5] Koza, J. R. “Genetic programming: A paradigm for genetically hundred papers in journals and conference proceedings.
breeding populations of computer programs to solve problems.”
Stanford: Stanford University, 1990, 131 p. His research interests include game theory,
[6] Koza, J. R. and Rice, J. P. “Genetic generation of both the optimization, telematic services, autonomous agents and
weights and architecture for a neural network,” in Seattle multi-agent systems. His e-mail address is:
International Joint Conference on Neural Networks, vol. 2, pp. jrial@[Link] and his Web-site is at:
397-404, Jule 1991. [Link]
[7] Schiffmann, W. “Encoding Feedforward Networks for Topology
Optimization by Simulated Evolution,” Fourth International
Conference on Knowledge-Based Intelligent Information
Engineering Systems & Allied Technologies, pp. 361-364, 2000.
[8] Mandischer, M. “Representation and Evolution of Neural
Networks,” Proceedings of the International Joint Conference on
Neural Networks and Genetic Algorithms, pp. 643-694, 1993.