*Petition to change the name:* cellular automata to celluar automata. I can't believe I miss-spelled that haha project source code: github.com/TanTanDev/3d_celluar_automata learning article: softologyblog.wordpress.com/2019/12/28/3d-cellular-automata-3/
For faster recompilation on Linux, I can highly recommend the mold linker. Linking is one of the slowest steps when incrementally working on a rust project
Heyo, dint get to see much of the code, but you can replace the hashmap by just an array and send it to a compute shader to calculate the new states, since calculating the new state of each cell is independent from the others. I think you could get great performance :D
@@shadamethyst1258 If you have a 1D array to store all the states, you could use a hilbert curve to map 1D array indexes to 3D coordinates. A property of the hilbert curve is that things close together in the 1D array are close together in X Y Z space, and because you're checking a cells neighbors in X Y Z space, a 1D array mapped to a 3D space via a hilbert curve means that neighbors will be closer together in memory, on average. That might be able to reduce cache misses?
Nice video, I really enjoyed it! Cool animations to look at, cute voxels, funny devlog, rap in the end :D To be honest, I would have loved to get some more insights about the code and your optimization journey though. I think getting worse performance out of multithreading for smaller input sizes is very common btw.
@@Tantandev Yeah I guess at some point the coordination/synchronization between threads takes longer than the actual work they do. If you're relatively new to multithreading in rust, maybe take a look at atomics (primitive numeric types that can be safely mutated through shared references) and at channels (e.g. crossbeam or flume), just to expand your toolbox. And consider using the mutex/rw lock from the crate parking_lot. It's basically a drop in replacement that performs much better, so that could be an easy win for your simulation :)
That's it, now Tantan has to release a rap album after that video ending. Great video as always! And I hope that your audience retention rate increases over time on the coding parts...
This has probably been suggested before but 7:33 proves it for me. Your musical sections would be MUCH better with on-screen lyrics. I can barely understand anything most of the time
bevy has a feature you can enable called trace_chrome it will produce a file when you close the program that you can then load into a website called ui.perfetto.dev I learnt about it reading in bevys github page: bevy/docs/profiling
Awesome!!! Definitely something to add to the toolbox. This seems like the key to being able to explore the space of possibilities with particle effects. Like say if you were making a game set on an alien planet, and explosions needed to be "different" and the clouds needed to move in strange ways...
Cellular automata are trivially parallelizable, as long as you give each thread the same amount of work and don't waste too much time on synchronization you'll be fine
Loved the video, very creative song as well! Wish you talked more about the code implementation and the theory behind it, I understand that maybe not everyone wants it, but I am sure it is possible to find a good balance like for example Sebastian Lague
I have been wondering this for weeks now, What is the tpose zombie dj looking dude? He looks dope but i just cant figure out if he is supposed to represent something 😭
This is great! I also love cellular automata, and simulations! I've made Conway's Game of Life in pure Kotlin (with my own engine :)) and I did a simulation called Verlet Integration in Go :D
I think you could have put the rules into an asset and use bevys hot reloading to not need to recompile (or I'm stupid and that is still a feature yet to be implemented)
Aah cellular automata rabbit hole, it took me years to get out of it and move on aha. For beast-tier speed you could try compute shaders, which seem perfectly well fitted for CA ^^
Literally came here for the code, not to watch a programmer pretend to be pewdiepie.....Thats a thumbs down from me dawg. The news in Idiocracy was a point of ridicule, not something to aspire to....
*Petition to change the name:* cellular automata to celluar automata. I can't believe I miss-spelled that haha
project source code: github.com/TanTanDev/3d_celluar_automata
learning article: softologyblog.wordpress.com/2019/12/28/3d-cellular-automata-3/
WHERE IS THE INTERACTIVE PART OF THE SOFTWARE
🤣 just go with it haha
*cellular
*misspelled
For faster recompilation on Linux, I can highly recommend the mold linker. Linking is one of the slowest steps when incrementally working on a rust project
I've never heard of it! I shall try it out thanks for the tip!
These videos are a great balance of informative and funny, great job!
Three comments!
I WANT YOU TO TALK ABOUT THE COOOODE~
Tantan is literally the only youtuber for whom I pause and like the video, when he reminds me to do so :)
You always have such wonderful project ideas TanTan. Keep it up! We're here for the long haul.
It's so mesmerising to see these live and very well explained. I really like the cute blocks!
Love it, I've been into celluar automata for a long time now and I'm glad you made a video on it
Epic song at the end.
You make really unique videos, I love it.
One comment
This would be amazing for some magic effects in a voxel game. Nicely done!
Heyo, dint get to see much of the code, but you can replace the hashmap by just an array and send it to a compute shader to calculate the new states, since calculating the new state of each cell is independent from the others. I think you could get great performance :D
The conversion from hashmap to array would make the code much faster even if it was on the CPU only
yup, did that. ~10x faster single threaded. and scales perfectly across multiple cores.
@@shadamethyst1258 If you have a 1D array to store all the states, you could use a hilbert curve to map 1D array indexes to 3D coordinates. A property of the hilbert curve is that things close together in the 1D array are close together in X Y Z space, and because you're checking a cells neighbors in X Y Z space, a 1D array mapped to a 3D space via a hilbert curve means that neighbors will be closer together in memory, on average. That might be able to reduce cache misses?
@@terezip2213 It would maybe reduce cache misses, but it would also make it a lot harder for the compiler to vectorize the code
Nice video, I really enjoyed it! Cool animations to look at, cute voxels, funny devlog, rap in the end :D To be honest, I would have loved to get some more insights about the code and your optimization journey though. I think getting worse performance out of multithreading for smaller input sizes is very common btw.
"worse performance out of multithreading for smaller input sizes". Man I didn't think of that but that makes sense
@@Tantandev Yeah I guess at some point the coordination/synchronization between threads takes longer than the actual work they do. If you're relatively new to multithreading in rust, maybe take a look at atomics (primitive numeric types that can be safely mutated through shared references) and at channels (e.g. crossbeam or flume), just to expand your toolbox. And consider using the mutex/rw lock from the crate parking_lot. It's basically a drop in replacement that performs much better, so that could be an easy win for your simulation :)
Noooooo, don't cut the CODE😭😭😭😭😭😭
I always love the raps in your videos!
People are watching a programming channel but don't care about the code? I actually want more!
YES ANOTHER TANTAN VIDEO
That's it, now Tantan has to release a rap album after that video ending.
Great video as always! And I hope that your audience retention rate increases over time on the coding parts...
This has probably been suggested before but 7:33 proves it for me. Your musical sections would be MUCH better with on-screen lyrics. I can barely understand anything most of the time
I wish I could be this happy and enthusiastic in life, that's really all one needs.
i think instead of a Arc you could use one of the several concurrent hashmaps available that are made for performance
6:17 What is that program? I don't know many debug tools for Rust...
bevy has a feature you can enable called trace_chrome
it will produce a file when you close the program that you can then load into a website called ui.perfetto.dev
I learnt about it reading in bevys github page: bevy/docs/profiling
@@Tantandev Oh, that's cool. Thx!
There's hotspot that I've used to profile my code, it's really easy to get to use it
Please talk about the code!
Been waiting for another rap, my good sir, excellent video
WOO 16k subs for TanTan!
Awesome!!! Definitely something to add to the toolbox. This seems like the key to being able to explore the space of possibilities with particle effects. Like say if you were making a game set on an alien planet, and explosions needed to be "different" and the clouds needed to move in strange ways...
Typo in the video Tantan, you wrote "Celluar", but. I think it should be "Cellular"
Unless I'm wrong maye ?
true! I can't believe I missed that!
So much beauty
The rap. OMG the rap.
Now combine your keyboard snake project with your automata project and put conway's game of life on your keyboard
Best outro
I like this crazy man and his crazy Linux.
not the VIEWER RETENTION!!
Dude i love your videos
1:34 I'm curious how you animated this? Is it in a 3D program like Blender?
I drew the face expressions in gimp, default Unity cube, and then animated everything with the Animator. It took me quite some time...
What profiler are you using?
crazy dude strikes again
TALK ABOUT THE CODE TALK ABOUT THE CODE
what about 4D CA then?
Cellular?
would c# parallel.for work here? it's fairly lightweight and way easier to use than async. (I'm thinking of doing this in unity).
Cellular automata are trivially parallelizable, as long as you give each thread the same amount of work and don't waste too much time on synchronization you'll be fine
Loved the video, very creative song as well! Wish you talked more about the code implementation and the theory behind it, I understand that maybe not everyone wants it, but I am sure it is possible to find a good balance like for example Sebastian Lague
I have been wondering this for weeks now, What is the tpose zombie dj looking dude?
He looks dope but i just cant figure out if he is supposed to represent something 😭
I love your videos!
ok now this is epic
i heard factorio and subricbed as fast as possible
I love your channel
This is great! I also love cellular automata, and simulations! I've made Conway's Game of Life in pure Kotlin (with my own engine :)) and I did a simulation called Verlet Integration in Go :D
Yo! o/ What did you use to see how much time the operation took? Greate videos btw \O/,
You forgot the bevy song hahaha 😂, nice ending
Please talk more about the code
I'd love a long video about the code.
I think you could have put the rules into an asset and use bevys hot reloading to not need to recompile (or I'm stupid and that is still a feature yet to be implemented)
Please talk more about the code, imma trying to learn something here
TALK ABOUT THE CODE
Please talk about the code
Why not play factorio in linux?
You can have non-blocking autosaves, which is very nice and productive
This would be perfect for the GPU. It would probably run a lot faster.
Aah cellular automata rabbit hole, it took me years to get out of it and move on aha. For beast-tier speed you could try compute shaders, which seem perfectly well fitted for CA ^^
You should make the song at the end of the video as a different video
Impressive.
you can setup your own rules, in the game
gpu acceleration
X-torch gpu tpu multithreading framework
fun fun
Please, talk about the code!
more code overview in the video please :)
Your reward was punishment!!
😆
use egui to change the rules live
Amazing rap♥
I literally just watched that video
TALK ABOUT THE CODE!
Cool
Factorio runs on Linux
talk about the code is also intresting
My man uses arch.. oh wait.
idk why every time i see your videos i feel like u are a programing god ... everything seems harf af
3D Celluwar AutomaTA! XD
Two comments
@@tqwewe what do you mean to say?
I'd like more code videos. Code if fun!
nice ;D
compute shaders
More raps pleeeeeaseeeee
WHERE IS THE INTERACTIVE PART OF THE SOFTWARE
Noo! Talk about the code!
More rap please!
loool, epic rap !
duel booting my pc killed my pc..... :D twice
RUclips will be blocked in Russia, and what will I do?
I like this channel, I want to watch it, but the state forbids me
Literally came here for the code, not to watch a programmer pretend to be pewdiepie.....Thats a thumbs down from me dawg.
The news in Idiocracy was a point of ridicule, not something to aspire to....
You look Greek