Inspiration

I am very interested in environmental sustainability. I have learned the due to the current climate plants are losing their nutrients. According to Research led by Sam Myers, Director of the Planetary Health Alliance at the Harvard Chan School, found that when food crops like wheat, corn, rice and soy are exposed to CO2 at levels predicted for 2050, the plants lose as much as 10% of their zinc, 5% of their iron, and 8% of their protein content. This inspired me to try and make something that could possibly simulate these changes using genetic algorithms to see how the plant will change.

What it does

Evo-Tree allows a current population of trees to evolve with the climate conditions that are specified by the user to see how the tree will change in appearance and "genetic" traits, this is all done with the use of a genetic algorithm.

How I built it

This project is programmed using python. I first had to start out with creating a physical traits of the tree, then I moved on to "genetic" features of the tree.

The hardest part was modeling the behaviors and relationships. I had to use some functions in order to calculate the amount of water needed and light needed based on the tree's "genetic" makeup.

Challenges I ran into

Displaying the data I am very new to the world of graphics. I know nothing about pygame so I had to do quick reading of the documentation and get by tree to appear the way I wanted to according to the tree's phenotypes.

Behavior/Relationship/Environmental Modeling Having to model a tree in a virtual setting in a matter of three days proved to be very challenging..... The hardest part would be the behaviors and relationships. It was difficult to find functions that would calculate the water and light absorption/Need. (For example I could have a lot of leaves to absorb a lot of light, but that means I would need to keep the plant in a lot of light and water due to the high amount of leaves). I underestimated how much time these models would take to create.

Accomplishments that I am proud of

I am excited to have completed my first ever hackathon! It was very challenging having to stay awake and continue especially working by myself. I am proud to have finished my project.

What I learned

PyGame I learned so much about pygame. I learned how to draw shapes and I also learned how to create a window and how to update it. I have never used pygame but I learned what I could in the time limit that I had.

Genetic Algorithms

I have only learned the theory behind a genetic algorithm but now I actually got to implement it with a unique problem. I learned how to do score each organism within a population, I learned how to select a species at random so their genes could spread, I learned how to do cross over and how to come up with my own crossover algorithm. Finally I learned how to mutate an organism with a given probability

Website

https://mario5648.github.io/Evo-Tree/

Built With

Share this project:

Updates