Giter VIP home page Giter VIP logo

fishbowl's People

Contributors

leshchenko1979 avatar

Watchers

 avatar  avatar

fishbowl's Issues

Save and restore genome

So that further mutations are standing on the shoulders of giants instead of starting from scratch each time the app is launched

Start fish brain mutations

  • decide on generations design
    • for now mutations only on respawn
    • splitted fish refers to the same brain in the neat. population array as its parent
  • fish respawn after X frames
  • implement a fitness function
    • the total size of all fish sharing this brain after X frames + max witnessed size of all fish sharing this brain
  • a block with mutation parameters
  • handle mutation on split
  • handle mutation on respawn after all fish die

Test lab for vision

All fish start from one point in the direction of one food
Food is positioned randomly in the area where all the fish are directed
Fitness is 1 / closest dist to the food
Shorter gen duration (approx the time it takes the fish to reach the food directly plus some leeway)
Sim running until all fish in the generation hit the food

SURVIVAL MODE - Switch to a new way of fish selection

  1. The fitness function is how long a certain fish has survived.
  2. One of the fish (or both of them) mutates on split.
  3. When the simulation time elapses for a generation, surviving fish are evaluated on their lifetime.
  4. When the simulation ends because all of the fish have died out, the score is proportional on the recorded lifetime of the corresponding fish.
  • start recording birthFrame in Critter() constructor
  • on split clone brain and add it to neat
  • mutate fish on split
  • reset birthFrame on split?
  • when a fish dies, set its brain's score to the fish lifetime
  • calculate neat.population[i].score based on lifetime (currentFrame - birthFrame)
  • entirely replace neat.population on generation change instead of neat.mutate()

Originally posted by @leshchenko1979 in #20 (comment)

Add stats

  • generation no. / frame no.
  • max genome size
  • current max fitness
  • NN response distribution

Vision and steering

It’s time to implement vision and turn steering actions back on again.

Food perception can be implemented effectively through reading the foodDensity array instead of trying to analyze the position of every food piece.

Other fish can be sensed just by going through the fish array and incrementing a counter by 1/distance.

  • fish perception
  • food perception
  • turn on turning actions
  • introduce acceleration???

Elitism is broken

Should probably try neat.evolve () instead of producing offspring one by one

Food amount parameter should be replaced

Food density as a way to discover different evolution strategies doesn't serve its role.

Food density in the eyes of fish is proportional to the (amount of food / area of the fishbowl / fish max speed). Secondly, although the starting amount of food may be high, the amount of other fish may quickly drive it down.

So, the "food amount parameter" should be replaced with food density at least, or, maybe, with food density / fish density.

Conical vision

Conical vision makes it easier to gradually zoom in on the target as you move. Linear vision (like now) makes the fish lose a moving target and miss a lot of food that's away from the view axis.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.