Neat AI does Predator Boids

Sdílet
Vložit
  • čas přidán 12. 06. 2024
  • This one builds on the last video and adds flocking, object avoidance and predator boids to the mix..
    Inspiration was taken from the implementation located here. Note that its written in antiquated VB6
    github.com/miorsoft/VB6-3D-Fl...
    also
    eater.net/boids
    Lots of Boids info located here:
    www.red3d.com/cwr/boids/
    Music :
    www.bensound.com/
    Boids
    From Wikipedia, the free encyclopedia : en.wikipedia.org/wiki/Boids
    Boids is an artificial life program, developed by Craig Reynolds in 1986, which simulates the flocking behaviour of birds. His paper on this topic was published in 1987 in the proceedings of the ACM SIGGRAPH conference. [1] The name "boid" corresponds to a shortened version of "bird-oid object", which refers to a bird-like object.[2] Incidentally, "boid" is also a New York Metropolitan dialect pronunciation for "bird."
    Rules applied in simple Boids
    Separation
    Alignment
    Cohesion
    As with most artificial life simulations, Boids is an example of emergent behavior; that is, the complexity of Boids arises from the interaction of individual agents (the boids, in this case) adhering to a set of simple rules. The rules applied in the simplest Boids world are as follows:
    separation: steer to avoid crowding local flockmates
    alignment: steer towards the average heading of local flockmates
    cohesion: steer to move towards the average position (center of mass) of local flockmates
    More complex rules can be added, such as obstacle avoidance and goal seeking.
    The basic model has been extended in several different ways since Reynolds proposed it. For instance, Delgado-Mata et al.[3] extended the basic model to incorporate the effects of fear. Olfaction was used to transmit emotion between animals, through pheromones modelled as particles in a free expansion gas. Hartman and Benes[4] introduced a complementary force to the alignment that they call the change of leadership. This steer defines the chance of the boid to become a leader and try to escape.
    The movement of Boids can be characterized as either chaotic (splitting groups and wild behaviour) or orderly. Unexpected behaviours, such as splitting flocks and reuniting after avoiding obstacles, can be considered emergent.
    The boids framework is often used in computer graphics, providing realistic-looking representations of flocks of birds and other creatures, such as schools of fish or herds of animals. It was for instance used in the 1998 video game Half-Life for the flying bird-like creatures seen at the end of the game on Xen, named "boid" in the game files.
    The Boids model can be used for direct control and stabilization of teams of simple Unmanned Ground Vehicles (UGV)[5] or Micro Aerial Vehicles (MAV)[6] in swarm robotics. For stabilization of heterogeneous UAV-UGV teams, the model was adapted for using onboard relative localization by Saska et al.[7]
    At the time of proposal, Reynolds' approach represented a giant step forward compared to the traditional techniques used in computer animation for motion pictures. The first animation created with the model was Stanley and Stella in: Breaking the Ice (1987), followed by a feature film debut in Tim Burton's film Batman Returns (1992) with computer generated bat swarms and armies of penguins marching through the streets of Gotham City.[8]
    The boids model has been used for other interesting applications. It has been applied to automatically program Internet multi-channel radio stations.[9] It has also been used for visualizing information[10] and for optimization tasks.[1
    Swarm intelligence (SI) is the collective behavior of decentralized, self-organized systems, natural or artificial. The concept is employed in work on artificial intelligence. The expression was introduced by Gerardo Beni and Jing Wang in 1989, in the context of cellular robotic systems.[1]
    SI systems consist typically of a population of simple agents or boids interacting locally with one another and with their environment. The inspiration often comes from nature, especially biological systems. The agents follow very simple rules, and although there is no centralized control structure dictating how individual agents should behave, local, and to a certain degree random, interactions between such agents lead to the emergence of "intelligent" global behavior, unknown to the individual agents. Examples of swarm intelligence in natural systems include ant colonies, bee colonies, bird flocking, hawks hunting, animal herding, bacterial growth, fish schooling and microbial intelligence.
    The application of swarm principles to robots is called swarm robotics while swarm intelligence refers to the more general set of algorithms. Swarm prediction has been used in the context of forecasting problems. Similar approaches to those proposed for swarm robotics are considered for genetically modified organisms in synthetic collective intelligence.[2]

Komentáře • 103

  • @DaemonWorx
    @DaemonWorx Před 2 lety +201

    Sometimes when you say “the boids” it sounds like you’re saying “the bois” and I really like that

    • @Lord_Drakostar
      @Lord_Drakostar Před 2 lety +18

      Me and the boids avoiding predators

    • @rowandaly2826
      @rowandaly2826 Před 2 lety +2

      Exactly! I’m gonna keep thinking he says that because it’s just an amazing name for the simulations; ‘the boys flock together’ fuck yea we do

    • @aguywhodoesntexist
      @aguywhodoesntexist Před 2 lety +3

      Boids will be boids

    • @PunmasterSTP
      @PunmasterSTP Před 2 lety

      @@aguywhodoesntexist You boider believe that!

  • @jacklipper-sagehorn4935
    @jacklipper-sagehorn4935 Před 2 lety +41

    Fun fact: predators irl have front facing eyes. Prey usually have eyes on the sides of their heads so they get a mostly complete 360 view. Don’t look to closely at big bird from sesame street.

  • @kinspower
    @kinspower Před 2 lety +101

    You should've increased it's fov when it's out of the flock, like it's moving it's head looking. I think that would lead to more fluid pods coming and going

    • @neatai6702
      @neatai6702  Před 2 lety +26

      Good point.. I get it to start increasing the range it uses when checking for nearby boids.. Never occurred to me to also increase its FOV. which would mimic it turning its head.. I'll add it to the list..

    • @liamwhite3522
      @liamwhite3522 Před 2 lety +15

      @@neatai6702 Predators could also have a smaller field of view, to reflect front-facing eyes vs. side-facing eyes of prey boids.

  • @DirtMaster
    @DirtMaster Před 2 lety +113

    How have I just found you, and how do you only have 300 Subscribers? The quality is great, educational while simultaneously entertaining. Bigger CZcamsrs have had worse starts and if you're starting like this, I'm excited for what you have to offer in a while :) Keep going man :D

    • @neatai6702
      @neatai6702  Před 2 lety +16

      Thanks Dirtmaster.. I'll keep going while its fun.. up to 400 subs now !

    • @DirtMaster
      @DirtMaster Před 2 lety +3

      @@neatai6702 Great work mate , I'll be watching your progress with great interest

    • @charlesgraham9135
      @charlesgraham9135 Před 2 lety +2

      Couldnt have said it better

    • @PixelThorn
      @PixelThorn Před 2 lety +4

      Almost 6k in 2 months - not bad!

    • @DirtMaster
      @DirtMaster Před 2 lety +4

      @@PixelThorn WOAH Neat blew up! As Deserved. His content is phenomenal

  • @peterkonrad4364
    @peterkonrad4364 Před 2 lety +23

    you know what the actual beauty of the starling murmurations comes from? i think this has never been actually captured by any simulation yet: they all need to do certain body movements to maneuver in the air. so for example to stop they have to spread their wings, and to dive they have to tuck their wings in. to fly curves they have to steer with their tail feathers. and so on. so not only are these murmurations in three dimensions instead of two, and with actualy newtonian physics, and not only are the starlings 3d objects viewed from different angles. but they also change shape during flight. and they all have to do the same shape change in roughly the same place in the swarm. that is what gives it the characteristic look. it is similar to sports fans in a stadium when they do the "wave". they stand up and sit down again in a wave pattern that moves around the stadium. in am not aware of a boids implementation that does this, because it would basically mean you would have to simulate bird flight.

    • @neatai6702
      @neatai6702  Před 2 lety +2

      once I get started in Unity I'm going to give it a go.. thanks for sharing !

  • @Zwerggoldhamster
    @Zwerggoldhamster Před 2 lety +27

    It's bothering me so much that the predators just ignore collisions ^^

  • @the.other.ian.
    @the.other.ian. Před 2 lety +39

    Would be interesting to add a few more features. Could have some sort of residual memory function for things outside of the field of view (which I know kinda steps outside of the idea of each time step only being a function of the previous one, so it might not be in the spirit of the simulation). Alternatively, you could have a second function for the area outside of their field of view that is weighted lower, to represent hearing and memory-ish. I suggest this because I notice that the prey tend to run from the predators briefly and then turn around and go back toward them because of proximity to their own flock members and no longer seeing the predators. Another thought is that you could have the object/nonhpreditor avoidance parameter be lowered in proximity to predictors, which might help with this (and be a bit more realistic, maybe?).

    • @tomasfiorentini4126
      @tomasfiorentini4126 Před 2 lety +1

      The thing about the range could be implemented without the memory, like having lower resolution in your peripheral view so you measure things at the wrong distance.

    • @the.other.ian.
      @the.other.ian. Před 2 lety +1

      @@tomasfiorentini4126 I like the idea of having more discreet peripheral vision with inaccuracies in angle and/or distance measurements (could actually be random error rather than low resolution sampling). Possibly a differently shaped dropoff function for distance for predators in peripheral/behind, as well. One thing to note is that the prey should also have a much wider field of vision than is used in this, because prey species tend to not have binocular vision and instead have wide fields of view specifically to spot predators.

  • @NovaStorm93
    @NovaStorm93 Před 2 lety +5

    me 'n the boids

  • @nyscersul42
    @nyscersul42 Před 2 lety +1

    The comment about how the field of view affects the behaviour proved rather useful, for me. I have programmed a rather complex example of swarm mechanics into a computer game i am building, in full 3d, and... well you just neatly identified an issue i have been having. Thanks! (If interested to see, reply here!)

    • @neatai6702
      @neatai6702  Před 2 lety +2

      Glad it helped.. It really does have an impact on how they swarm and move about..

  • @samuelgibson780
    @samuelgibson780 Před 2 lety

    Oh that is very neat. What an awesome way to visualize interacting forces! Thank you for introducing me to this.

  • @joshuavancuyck2669
    @joshuavancuyck2669 Před 2 lety +3

    This is awesome! What software do you use to display this graphically?

  • @momomalo8098
    @momomalo8098 Před 2 lety +2

    when i coded my flocks ai, i took one step further and add some cycling : spawn random "vegetation", herbivore take vegetation to reproduce, predator eat herbivore to reproduce. I also implemented a code which slows down predator when entering vegetation, to let herbivore population regrow when predator are numerous. Just to give you ideas ! ;)

    • @momomalo8098
      @momomalo8098 Před 2 lety +2

      also, you should make boids rotate when velocity = 0, as a "search flock" function

  • @paxtoncargill4661
    @paxtoncargill4661 Před 2 lety +24

    Everyone gangster until the us federal government deploys the boids

    • @exmo7
      @exmo7 Před 2 lety +4

      we dem BOIDS

  • @propnotch3466
    @propnotch3466 Před 2 lety +2

    Noithin's boyter than boid watchin'

  • @DeitiesDogma
    @DeitiesDogma Před 2 lety +1

    I have seen boids mentioned EVERYWHERE and I swear they're talking about theae

  • @comit8077
    @comit8077 Před 2 lety +2

    That's pretty *neat*

  • @aleratz
    @aleratz Před 2 lety +1

    Me and the boids playing videogames

  • @operator8014
    @operator8014 Před 2 lety +2

    I wonder if they would exhibit a wavelike formation if you restricted their view to only the front 120ish degrees, but NOT the frontmost 20 or 30 degrees, giving them a frontal blindspot, similar to some fish and birds.

  • @jpeg23
    @jpeg23 Před 2 lety +7

    Ngl when looking at your subscriber count I thought I would see 300000 not 300

  • @turtlenecker223
    @turtlenecker223 Před 2 lety

    love this channel

  • @benschulz9140
    @benschulz9140 Před 2 lety +2

    Lotka-Volterra (Predator/prey) is one of the inspirations Cowan had for his neuroscience equations for brain dynamics.

  • @phillipneal8194
    @phillipneal8194 Před 2 lety +1

    Great work. Thank you !

  • @shikikankillzone4239
    @shikikankillzone4239 Před 2 lety +1

    Me and the boids being controlled by an omnipotent entity that codes our very existence:

  • @minikretz1
    @minikretz1 Před 2 lety

    Awesome additions!

  • @benschulz9140
    @benschulz9140 Před 2 lety +1

    Now all you need is winner take all for inhibitory neurons and you got yourself a brain model.

  • @ultraapple3997
    @ultraapple3997 Před 2 lety +1

    Remember the "predatory fish-birds" from the stone age people movie. Or it's just me?

  • @darthtorment
    @darthtorment Před 15 dny

    Hi I find your AI's versatility fascinating. Do you think it could play Spore?

  • @oneeco
    @oneeco Před 2 lety +2

    Neat.

  • @StevenIngram
    @StevenIngram Před 2 lety +1

    I wonder if you added wind resistance and fatigue, if they'd start flying in V formations?

  • @StickStep
    @StickStep Před 2 lety +1

    Eh, great video through, but you didn't put name of the tracks you used here... I want to find track from intro, I looked whole bensound, all pages, but didn't find it... Tell me name of the track, please

  • @matthewbadger8685
    @matthewbadger8685 Před 2 lety +2

    Since the predators are not part of the same flock, I feel like they should be less packed together so that they have more available food and less competition.

    • @neatai6702
      @neatai6702  Před 2 lety

      good point ! there's different settings I can tweak to impact behavior

    • @Jpteryx
      @Jpteryx Před 2 lety +1

      @@neatai6702 I think a setting that makes predators avoid each other when they get too close might work well.

  • @mathew6041
    @mathew6041 Před 2 lety +2

    Could someone tell me what this visualizing program's name is ?

  • @PunmasterSTP
    @PunmasterSTP Před 2 lety

    Boid oh boid, this video was amazing!

  • @homosapienfactory6291
    @homosapienfactory6291 Před 2 lety +1

    we dem boids

  • @LukeMelto
    @LukeMelto Před 2 lety +1

    Awesome!

  • @tritoner1221
    @tritoner1221 Před rokem

    how much processing power does this eat up? is it possible to simultaneously simulate tens of millions of these boids without too much lag?

  • @commentaccountaint2885
    @commentaccountaint2885 Před 2 lety +1

    This is cool

  • @lexibyday9504
    @lexibyday9504 Před 2 lety

    I really want to see this done with modelled and animated creatures in an actual environment with each species having slightly different boid settings and see how closely we can get them to imitate real herds and packs of animals. Thor in the needs system. The animals get tired and have to rest, get hungry and have to eat, get thirsty and have to drink, get lonely and have to return to the herd.

  • @Enigma758
    @Enigma758 Před 2 lety +1

    How does a "real" bird identify which flock it is a member of?

    • @neatai6702
      @neatai6702  Před 2 lety +1

      I'm guessing they have no concept of a flock

    • @Enigma758
      @Enigma758 Před 2 lety

      @@neatai6702 So maybe it should also be that way in the simulation.

  • @synoptic4753
    @synoptic4753 Před rokem

    Didnt think of randomizing the day cycle maneuvers?

  • @NoahSpurrier
    @NoahSpurrier Před 2 lety

    Can’t wait for the sheepdog.

    • @neatai6702
      @neatai6702  Před 2 lety

      Herding BOIDS ! Coding it at the moment ! It'll be the video after the next one..

  • @Cattuccino_
    @Cattuccino_ Před 2 lety

    looks like be used for a neat game.

  • @n8style
    @n8style Před 2 lety +1

    This looks great! I doubt very much it's using NEAT though

  • @gaslitgames
    @gaslitgames Před 2 lety +1

    I like my AI like I like my whiskey. Neat

  • @Maric18
    @Maric18 Před 2 lety +1

    2 months ago you had 300 subs. now you have 6.51k :O

    • @neatai6702
      @neatai6702  Před 2 lety +1

      closing in on 12k a week later... !

  • @xuzhang7443
    @xuzhang7443 Před 2 lety +1

    How do you handle so many entities without crashing your computer?

    • @neatai6702
      @neatai6702  Před 2 lety +1

      check out the next vids.. need a good data structure (quadtree is my favorite)

  • @aya-hl5bk
    @aya-hl5bk Před 2 lety

    Hey you got famous good job

  • @Kraus-
    @Kraus- Před 2 lety

    Can the predator boids consume the prey or do they just chase?

    • @neatai6702
      @neatai6702  Před 2 lety

      just chase, but the next few vids will have them doing other stuff..

  • @heccinparagon6633
    @heccinparagon6633 Před 2 lety +1

    Hey, ever heard of the bibites? Y'all would definitely benefit from checking his channel out. Very similar content, and he actually uses boid behaviors for his simulations herding.

    • @neatai6702
      @neatai6702  Před 2 lety +1

      yes, I'm a fan ! wish he'd do more regular videos on the topic..

  • @comeycallate9959
    @comeycallate9959 Před 2 lety

    3:57 the object avoid is impemented, but a black dot resists the system and go through the object lmao

  • @quant-prep2843
    @quant-prep2843 Před 2 lety +3

    please start discord server bro

  • @sxs512
    @sxs512 Před 2 lety

    The animation seems very choppy. I think you should decrease the timestep.

  • @arendellecitizen208
    @arendellecitizen208 Před 2 lety

    Bois

  • @MrGN-yy6op
    @MrGN-yy6op Před 8 měsíci

    why AI tho

  • @RoastCDuck
    @RoastCDuck Před 2 lety

    Next thing add rockets and lasers, will make a good video game.

  • @RobouVideos
    @RobouVideos Před 2 lety

    is this an AI voice that we hear? because it's really hard to understand

  • @P-G-77
    @P-G-77 Před 6 měsíci

    I have the impression that the more we go forward using AIs in an increasingly complex way, the more I realize that our lives could easily be just a programming or a simulation... am I wrong? And I am not against AIs, let's be clear... on the contrary.

  • @cosmosaodyssey2188
    @cosmosaodyssey2188 Před 2 lety

    Bois
    The d is silent

  • @mr.norris3840
    @mr.norris3840 Před 2 lety +2

    Where is the Neat part? Misleading

    • @mr.norris3840
      @mr.norris3840 Před 2 lety

      @@louisvdwalt I love the neat algorithm, and everytime I see such a title in my recommendations I click on it and get disappointed. And worst part is youtube thinks I love it (its not bad content though)

  • @REKSIV
    @REKSIV Před rokem

    The humans are no different. Just a drone swarm of npc actors that don't deserve to falsely occupy the render engine. Cheat engine the build or biomod shop and let the players wipe out the flock for taking too long to be of interest to anyone. It's bad enough the earth was just some tacky slot machine self assembler to a purposelessly abusive singularity farm. It's bad enough a physics engines been wasted to string encryption falsely claimed as communication. It's time to clear out the shitcom recycling backend and get on with worthwhile gameplay implementation instead of procedurally generating the same rinse and repeat. DEATH TO ALL HUMAN NPCS!

  • @CHITUS
    @CHITUS Před 2 lety +2

    you know what the actual beauty of the starling murmurations comes from? i think this has never been actually captured by any simulation yet: they all need to do certain body movements to maneuver in the air. so for example to stop they have to spread their wings, and to dive they have to tuck their wings in. to fly curves they have to steer with their tail feathers. and so on. so not only are these murmurations in three dimensions instead of two, and with actualy newtonian physics, and not only are the starlings 3d objects viewed from different angles. but they also change shape during flight. and they all have to do the same shape change in roughly the same place in the swarm. that is what gives it the characteristic look. it is similar to sports fans in a stadium when they do the "wave". they stand up and sit down again in a wave pattern that moves around the stadium. in am not aware of a boids implementation that does this, because it would basically mean you would have to simulate bird flight.