cppn2
DESCRIPTION
Computational pattern producing networks.TRANSCRIPT
![Page 1: CPPN2](https://reader035.vdocuments.net/reader035/viewer/2022081908/5695d2d91a28ab9b029bed80/html5/thumbnails/1.jpg)
How do CPPNs work?
![Page 2: CPPN2](https://reader035.vdocuments.net/reader035/viewer/2022081908/5695d2d91a28ab9b029bed80/html5/thumbnails/2.jpg)
Steps
• Step 1: Randomly generate a genome
• Step 2: Pass the genome through a set of predefined functions to get the phenotype
• Step 3: Calculate fitness
• Repeat step 2 and step 3 if newFitness > lastFitness
![Page 3: CPPN2](https://reader035.vdocuments.net/reader035/viewer/2022081908/5695d2d91a28ab9b029bed80/html5/thumbnails/3.jpg)
Step 1: Random generation of genomes
Example: 256*256 pixels
Assign some random number to each pixel
![Page 4: CPPN2](https://reader035.vdocuments.net/reader035/viewer/2022081908/5695d2d91a28ab9b029bed80/html5/thumbnails/4.jpg)
Step 2: Express the phenotype
• Predefined functions (hardcoded):
– E.g.: If the value at a pixel is 2 new pixel value is Sin(2)
• Phenotype => new color of that pixel
GenotypeCPPN
Phenotype
![Page 5: CPPN2](https://reader035.vdocuments.net/reader035/viewer/2022081908/5695d2d91a28ab9b029bed80/html5/thumbnails/5.jpg)
Step 3: Calculate the fitness
• Fitness is calculated here to test whether the actual image is closer to the phenotype
• Fitness = Expressed color – Actual color (at one pixel position)
• Repeat step 2 and step 3 if
– currentFitness > lastFitness
![Page 6: CPPN2](https://reader035.vdocuments.net/reader035/viewer/2022081908/5695d2d91a28ab9b029bed80/html5/thumbnails/6.jpg)
Conclusion
• Functions in the CPPN are hardcoded (fixed for a set of images)
• From initial random pixel values , a CPPN can produce the actual image
• By mutating (i.e. weight change) or crossing of two CPPNs, we can build a new CPPN (I am yet to verify this)