davidrmiller / biosim4

Biological evolution simulator
Other
3.17k stars 451 forks source link

Questions about Random Number Generation + more #104

Open bigbanda opened 1 month ago

bigbanda commented 1 month ago

Hello! I am just a kid from school who thinks your biosim is the greatest thing ever. I'm trying my own personal project that is inspired by your work! I don't have another way to contact you so I figured I'd ask on here.

  1. Why did you implement your own random number generator? You could have saved time implementing your own by just going with standard library random generators right? Did you run into time complexity issues, and therefore feel the need to implement faster algorithms?

  2. I am really interested in the intersection of neural networks and biological brains. I think your implementation of an ANN is interesting in that its efficacy improves because of evolutionary operators, not backpropogation. It reminds me a lot of a discrete time system though, something that moves from one state to the next in each time step. One idea I really want to explore is moving away from the notion of a neural network being synchronous (where all connections in the brain are evaluated together) and discrete. Instead I want to try tinkering with networks that are decentralized and asynchronous (like in real brains where a neuron can fire whenever it wants) and non-discrete (if there is some smart way to remove the notion of discrete time intervals). Do you have any advice on that? Because it's what my project is about and I thought you might have good insight into that. I am aware though that just by the nature of how digital computers work, it might not really even be possible unless computers were analog.

Thanks for being a huge inspiration!

davidrmiller commented 1 month ago

Hi @bigbanda, thanks so much for the kind words. Your intuition about the random numbers is correct. The simulator needs a lot of random numbers inside its innermost loop, and it was spending a lot of time inside the standard library functions. So I found some quick-and-dirty random number generators with less overhead. They're not cryptographic quality, but they seem to serve the purpose well enough.

The idea of an asynchronous neural network is fascinating. I don't have personal experience with them, but check out artificial spiking neural networks. I believe the idea is to have event-driven neurons that break away from the discrete time domain and deterministic ordering, more like biological brains.

If you feel so inclined, let us know what you learn from your experiments. Good luck!

bigbanda commented 1 month ago

Thank you so much! Of course I will return here to post any findings if I come up with something interesting!