Manim Tutorial Series E03: Animation Deep Dive | Mathematical Animations WITH EASE

Поделиться
HTML-код
  • Опубликовано: 2 дек 2024

Комментарии •

  • @behackl
    @behackl  2 года назад +21

    Hey people! The holidays made it a bit difficult for me to find time for producing this; but I do hope you'll still enjoy this video and find it useful. Don't forget to check out the links to the video resources in the video description! 🔗
    Leave a comment with a suggestion if there are any particular topics you are interested in for future videos! Next up will - probably - be a bit about updater functions or so. Alternatively, you can also reach me on Manim's (or my own semi-secret 👀) Discord server. Thank you for watching and sharing my content! 👏🎉
    Happy holidays and a healthy new year to all of you!

    • @osmanaydn4648
      @osmanaydn4648 2 года назад +1

      Thank you for your effort. I learned a lot from you. It is very helpful and time-saving to learn MANIM quicker. Thank you again.

  • @hakankisa5002
    @hakankisa5002 Год назад +13

    I was wrong Manim v.0.18.0 does not support colours anymore! New ManimColor is needed. "from manim import ManimColor" and after I changed my code :
    # polys = VGroup(*[RegularPolygon(5, radius=1, fill_opacity=0.5, color=ManimColor(hue=j/5, saturation=1, luminance=0.5)) for j in range(5)]).arrange(RIGHT)
    polys = VGroup(*[RegularPolygon(5, radius=1, fill_opacity=0.5, color=ManimColor.from_hsv((j/5, 1., 1.))) for j in range(5)]).arrange(RIGHT)
    Your new video ruclips.net/video/nF-oxtKA_oY/видео.html helps me!

  • @gabrielamici5540
    @gabrielamici5540 Год назад +7

    this is a life changer, I've been meaning to get into Manimations for over a year now but always felt intimidated by the structure of scenes being derived from classes and i just thought learning Manim would be prohibitadely hard. You've shown me how wrong I was! Thanks soo much!!

  • @andrewmole3355
    @andrewmole3355 2 года назад +11

    This series is *very* helpful, by the way. Thank you so much for taking the time to do it.

  • @fadiha2746
    @fadiha2746 Год назад +4

    (first, sorry for my poor English if there are too many mistakes. ) thanks so Much!! Your video are a real pleasure to look at : clear, not too deep into the framework but not to superficial so you give the pieces of information useful to really understand what's going on under the hood. I don't know if the last animation has been prepared before making the video, iit seems not and if it isn't, it's crazy how you can write those bunch of stuff and get it working just the first time!! And I really enjoy the idea of this animation.
    Thanks for sharing all your knowledge with talent and humility. Cheers from France

    • @behackl
      @behackl  Год назад

      thank you very much for the kind words! :-)

  • @mathwolf4276
    @mathwolf4276 2 года назад +1

    please do not stop uploading manim tutorial videos they are interesting you have all my support and thank you I wait for the new manim video greetings from BOLIVIA

    • @behackl
      @behackl  2 года назад

      Thanks for the kind words! Episode 5 should be released within the next 1-2 days. :-)

  • @fernandofariajunior
    @fernandofariajunior 4 месяца назад

    This series is so helpful in learning the library, thank you!

  • @MrImmi34
    @MrImmi34 2 года назад +1

    A gr8 tutorial indeed. In depth and concise at the same time. Do more.

    • @behackl
      @behackl  2 года назад

      Thank you! More is in progress! :-)

  • @Ricochetmex
    @Ricochetmex 2 года назад +1

    I just started today with this series and it is very helpful, thanks a lot!

  • @amarug
    @amarug Месяц назад

    Really really good tutorials, perfectly structured and explained. Vielen vielen Dank!!

  • @ankitadas4245
    @ankitadas4245 Год назад

    I had been struggling to start with manim for a long time, finally feels like I have got a good head start. Thank a lot for these tutorials !

  • @ДавыдАхмадуллин

    Thanks a lot! You just showed me, that Manim isn't scary. Your explanations are easy to understand and useful.

  • @aramarakelyan5712
    @aramarakelyan5712 2 года назад +1

    This video and the two previous ones are a very good guides to getting started with manim. Thank you very much!!! I hope that this will continue 💜

  • @mathflipped
    @mathflipped 2 года назад +5

    If I can make a suggestion... It would be great if the text for coding examples were larger. For example, you could increase the font size in the code editor or (better yet) temporarily change the scaling of the screen. The latter solution would also result in bigger animation windows.

    • @behackl
      @behackl  2 года назад +1

      Ah, yes - I'm traveling over the holidays and produced this with relocated equipment on a different computer; I thought that I had already made it larger than in my previous videos. When I found that it was *exactly* the same size, it was unfortunately already too late to change. I'll keep trying! 😅

    • @mathflipped
      @mathflipped 2 года назад

      @@behackl Sounds good :)

  • @BeABetterDev
    @BeABetterDev Год назад

    Thank you so much for your excellent videos.

  • @MATHalino1
    @MATHalino1 2 года назад

    Thank you for your great contribution. I made some progress in Manim because of your video especially the placements of objects in Part 2. I have very limited knowledge of coding because it is not my training. I heard Python only because of Manim. I get myself through sample codes and try to wrap my head around them. I am struggling with loops, they are alien to me. Your codes really amaze me and your deep understanding of the workings of Manim. Kindly continue this series, it is a huge help.

    • @behackl
      @behackl  2 года назад +1

      Thank you for the kind words! I am working on the next episode. :-)

  • @DavidRajM
    @DavidRajM 2 года назад

    Thats a very nice deep dive! Thank you so much for that.

  • @michaelpritz
    @michaelpritz 2 года назад +2

    Thank you for this great video, very informative! I am currently taking a course on heuristic optimization and I plan to do some videos covering topics from it (Local search, Genetic Algorithms, Continuous optimization, ...). Your videos help a lot!

    • @djfn4s3r45
      @djfn4s3r45 2 года назад

      Hello,
      I'm really interested in what you're planning to do in the future.
      Do you have a Discord profile, so we can get in touch?

  • @tomastuprofeonline9869
    @tomastuprofeonline9869 2 года назад

    Great job men. Keep up the good work!!

  • @miltonedwincobocortez8792
    @miltonedwincobocortez8792 2 года назад +2

    Hey! This is the best Manim Tutorial so far! I am enjoying and learning a lot, is Great!

  • @eshaannagavenkata8836
    @eshaannagavenkata8836 2 года назад +1

    hey ya, it is really helpful for me and great work

  • @mathflipped
    @mathflipped 2 года назад +1

    Great video, Ben! I learned about generate_target and save_state methods and their purpose. I did not notice any meaningful explanation of these in the documentation. The save_state method was used in some MovingCameraScene examples, but little explanation was provided. BTW, it could be great if you could eventually cover the moving camera scene because the documentation is really scant on this one. Thank you in advance!

    • @behackl
      @behackl  2 года назад

      Thank you for the suggestion! There might be some breaking changes concerning special scenes soon, so I'll wait a little to avoid producing a video that covers deprecated stuff. :-)

    • @mathflipped
      @mathflipped 2 года назад

      @@behackl Good to know from the first-hands source :)

  • @fierval
    @fierval 2 года назад

    This is amazing! :)

  • @lucagirelli5223
    @lucagirelli5223 2 года назад

    great stuff! :)

  • @sebastiaanpeters2971
    @sebastiaanpeters2971 2 года назад +3

    Thanks, these videos really help me out a ton!
    Would you mind going a bit in-depth on how things like Scenes and mobjects mangement work? Like the difference between fore/background ect

    • @behackl
      @behackl  2 года назад

      Great to hear that you find these helpful! I'd like to, but it will probably take a while until I do it: we are currently thinking of refactoring a fair amount of code, and I wouldn't want to produce a video that is outdated within a few months.

  • @pyisoe7316
    @pyisoe7316 2 года назад +1

    Thanks a lot!

  • @elucidarium3013
    @elucidarium3013 Год назад

    Excelent videos. This guy is the best

  • @BehzadmozaffariTazehkand
    @BehzadmozaffariTazehkand Год назад

    Hi Dear,
    I draw a circuit in manim using tikz, I want to select any element in the circuit. how we do it?

  • @nawsailabang3361
    @nawsailabang3361 2 года назад

    Amazing!! Thankss!!

  • @Matematicas_David
    @Matematicas_David Год назад

    Great video!
    I have a question, can a square rotate while is under the moveTo animation?
    I tried but I couldn't

    • @behackl
      @behackl  Год назад +1

      Depends on how you approach it: generally speaking, having two different animations on one given mobject in the same play-call won't work, as Manim isn't able to combine different animations itself. (Think of asking Manim to play square.animate.shift(LEFT) and square.animate.shift(UP) at the same time.)
      Two approaches that should work though: either adding an updater function to your square that lets it rotate, and then animating the movement, or writing your own UpdateFromAlphaFunc animation that combines the two movements. The second one is probably a bit cleaner, but both approaches are similarly flexible.

    • @Matematicas_David
      @Matematicas_David Год назад

      @@behackl I'll try the second option. I want use the Indicate() animation while the animation is under movemente and your answer help me a lot. Thank you for your attention.

  • @MathematicFanatic
    @MathematicFanatic Год назад

    Thank you so much!

  • @RAnnyyev
    @RAnnyyev 8 месяцев назад

    The CustomAnimationExample does not work for me. I copied the code directly from the Jupyter notebook, so the error is not on my part. I guess there have been some changes to the library, and the code is not up to date anymore.

    • @behackl
      @behackl  8 месяцев назад +1

      I just tested it on my end, with the latest release of Manim (v0.18.0) the CustomAnaimationExample does work as expected.
      The colour-module imported at the beginning of the notebook, however, does not -- and I've just updated it to work with Manim's reworked color system too: github.com/behackl/manim-with-ease/blob/main/E03%20-%20animations.ipynb
      YT comments are not ideal for discussing problems with code, come join the Manim discord at manim.community/discord, or see docs.manim.community/en/stable/faq/help.html. HTH!

  • @poiesh
    @poiesh Год назад

    Hi, I just started out with Manim and found your channel. Will there be more tutorials in the future that will deep even deeper into Manim?

    • @behackl
      @behackl  Год назад +2

      Hey! I'm currently working more on improving the library itself -- but as soon as there are substantial improvements, yes: I'd definitely like to produce more Manim tutorials too. :-)

  • @somdebsar7378
    @somdebsar7378 Год назад

    ValueError: Failed to parse a color from red
    if you encounter this problem while executing this line of code:
    *[RegularPolygon(5,radius=1,fill_opacity=0.5,color=Color(hue=j/5,saturation=1,luminance=0.5)) for j in range(5)]........
    just replace this with:
    *[RegularPolygon(5,radius=1,fill_opacity=0.5,color=Color(hue=j/5,saturation=1,luminance=0.5).hex_l) for j in range(5)]
    the hex_l will convert the current Color to the hexadecimal format and it ensures the reading of the color without parsing any error

  • @GordonHugenay
    @GordonHugenay 2 года назад

    That's weird, I tried that last example, and it didn't work, but when I deleted the line "self.wait()" (i.e. line 131 at 45:08) it worked.

    • @behackl
      @behackl  2 года назад

      ... weird indeed! I just tried it again to make sure, the snippet also renders properly in the interactive worksheet linked in the description. Maybe something unrelated to the code went wrong?

    • @esneidervelezpena9185
      @esneidervelezpena9185 Год назад

      Hello @@behackl ! Pleasure to greet. I had the same problem, with self.wait() it didn't render the Disperse animation when i removed the line it run wihtout problem. is it a bug? btw It's an amazing tutorial, you're the best!

    • @danielhutchinson6158
      @danielhutchinson6158 3 месяца назад

      Same for me in 2024.

  • @dkehlenbeck
    @dkehlenbeck 2 года назад

    Thanks for these videos, I've enjoyed watching them so far. What text editing software are you using that brings up the Manim help documentation for what you're typing, adding the closing parenthsis or bracket when you add a ( or [ , and so on? When I glanced at the community page, the tutorial suggets simply using Notepad, Text Edit, etc., but are there any instructions for getting a programming environment closer to yours? Thanks so much for any suggestions!

    • @behackl
      @behackl  2 года назад

      Hey! You can certainly use any editor you like, but personally I definitely recommend using some sort of code editor. I use VS Code (code.visualstudio.com, or the corresponding community-maintained version vscodium.com) and am quite happy with it. :-)

    • @dkehlenbeck
      @dkehlenbeck 2 года назад

      @@behackl Great, thanks so much!

  • @andrewmole3355
    @andrewmole3355 2 года назад

    What would be the best approach for animating a wave in an array of points? I have a function that can be set up in the form of an alpha function, but I am getting some strange results (dots are flying off when I set the run_time to more than around 2). Is it a problem that I am trying to get an array of dots to do too many physical loops?

    • @behackl
      @behackl  2 года назад

      Hard to say without seeing code or rendered output. I'd recommend asking in the Manim Discord server (manim.community/discord ), or in a GitHub discussion (github.com/ManimCommunity/manim/discussions ). :-)

    • @andrewmole3355
      @andrewmole3355 2 года назад

      @@behackl Thanks - I actually provided a link, but RUclips seems to have stripped it. I will try the Discord Server.

  • @mounibmekhilef8536
    @mounibmekhilef8536 2 года назад

    Excellent video Benjamin however there is a huge gap as compared to episode 2. requires more time to digest. Hope that at some point you'll have time to develop something about animating math texts. Read somewhere that we should consider arrays.... thx again fo the huge work.

    • @behackl
      @behackl  2 года назад

      Thank you! Yes, this episode definitely covers more intricate stuff than the previous two, but I still hope that it is helpful. Regarding math text animations: that's a good idea for an episode; I'll think a bit about it. 👍

  • @muhammadusman5521
    @muhammadusman5521 2 года назад

    Sir I want to create a plane in 3d.... Like If Y = 0 we have the xz plane...... I want to create a plane x + y + z = 1 in manim.... How should I do it... Can you plzzzz share the code for this thing....... If a parameterize the equation I get 2 variables and the ParametricFunction() in manim accepts only 1 argument..... I also tried the implicit function but the same problem... Can you show me how to do it plzzzz

    • @behackl
      @behackl  2 года назад

      If you look here: docs.manim.community/en/stable/reference/manim.mobject.three_dimensions.html in our documentation, you will find all mobjects that are specifically 3D. ParametricFunction and ImplicitFunction are for 2D plotting, you are looking for Surface. There are examples for how to use it in our documentation! :-)

  • @ChrisOffner
    @ChrisOffner 2 года назад

    Thank you for another great video! One nitpick though: I think it would've been better to illustrate the rate_func variations either with a linear *move* instead of a rotation, or at least do it with a rotation on mobjects/shapes that don't happen to have rotational symmetry.

    • @behackl
      @behackl  2 года назад +1

      I agree! Should have gone with an animation similar to those in our documentation, docs.manim.community/en/stable/reference/manim.utils.rate_functions.html - but was too stubborn to change the script and talk about .animate first. Oh well. :-)

  • @aravindsrinivasan2295
    @aravindsrinivasan2295 2 года назад

    Thanks a lot for this tutorial really solved a lot of mysteries about how manim functions and its really amazing to have tutorials from the maintainers of manimce.
    Also is there a straightforward way to rotate a Mobject by PI while simultaneously moving it or scaling it etc. Since Rotating by PI requires a different method altogether and cannot be chained along with the animate method. Thank you in advance, I also would love to see more tutorials from your side!

    • @behackl
      @behackl  2 года назад +1

      Thanks for the kind words!
      I thought the easiest way to do this would be updater functions, but after some testing it turns out that's not actually the case. Here is a possible solution though: if s is a square, you can scale and rotate it at the same time by playing s.animate(path_arc=PI).scale(2).rotate(PI), where you replace PI with the desired angle. This will also work with shifting (although not necessarily with the expected effect). I'll do some more research and probably give more info about it in the next episode (which I hope I'll find time to produce soon™️).

    • @aravindsrinivasan2295
      @aravindsrinivasan2295 2 года назад

      @@behackl Thank you for taking your time and responding! Eagerly waiting for your next episode!

  • @scollyer.tuition
    @scollyer.tuition 2 года назад

    This is very useful. Thanks.
    However, I note that you didn't talk about updater functions at all, and there seems to be a lot of overlap between what you can do with updater functions, and various techniques that you demonstrated here.
    Are you planning to talk about updater functions in some later video?

    • @behackl
      @behackl  2 года назад +1

      Hello! Thank you for your feedback! The idea for this episode was to mainly talk about ways of animating using play calls; I had to draw a line somewhere. (I'd like to try to get my videos down into the ~15min range to make production a bit easier for me, but so far I have failed spectacularly.)
      However, I'll certainly talk about updaters: the idea I currently have for the next episode is to talk about updater functions and their relation to Animation classes, including everything one needs to know about Manim's render loop, or something in that direction.

    • @scollyer.tuition
      @scollyer.tuition 2 года назад

      @@behackl An episode on updaters would be great. However, I think there's still a lot to say on the techniques discussed here. e.g.
      1) can we apply the "correct" Rotate() operator to multiple mobjects simultaneously?
      2) how do we do a "correct" Rotate() and, say, shift() simultaneously?(I don't think you covered this..)
      3) What is the best technique for animating a VGroup, comprising multiple sub-mobjects? (This seems to be tricky)
      4) etc, etc
      Also, it seems to be the case that Rotate(), say, doesn't just rotate - it seems to alter the locations of the top/left/right/bottom sides, as far as I can tell (does it use .become() or something like that?) This makes it hard to work with composite objects, and I get the feeling that I'm misunderstanding how I am supposed to be using these methods. It's all very complicated 😞
      Maybe I ought to go and read the source code.
      (And I sympathise with the problem of keeping videos short - I tend to talk far too much - my excuse is that I have so many wonderful things to say though 🙂)

    • @scollyer.tuition
      @scollyer.tuition 2 года назад

      @@behackl And on another note, I would be very interested in seeing a video on how to use OOP techniques correctly with manim - for example, I would prefer to create objects that know how to transform/move/change themselves, with all of the details hidden in class methods.
      However, I find it difficult to see how this can be made to work cleanly with the self.add(), self.play() calls that are typically made in the Scene construct() method. It seems necessary to put a lot of logic in that method, rather than hiding it in class methods - maybe it will become clearer when I've worked with manim (and python) for longer, though.
      Anyway, you deserve great praise for these videos - they are really helping to clear up (some of) my confusion.

    • @behackl
      @behackl  2 года назад

      There is a lot to reply to here! :-)
      Not sure I understand (1) correctly. (2): I'd rotate the mobject with an updater, and then shift with a play all animation. Or write a custom animation. (3) is too generic to answer. It strongly depends on what exactly you would like to do. But I tend to agree: it does require a fair amount of work to put together a custom mobject with nicely animated methods.
      I'm not quite sure right now about the actual implementation of Rotate, so can't quite comment about that right now. Two more approaches: there is a Rotating class that might work better, not sure - or you could try mobject.animate(path_arc=angle).rotate(angle).
      And regarding the OOP question: take a look at the implementation of ManimBanner, it has some methods that build animations that can be passed to play calls. I like that approach. I'll probably talk about custom mobjects, animation methods, and animation overrides eventually, but it might be that we introduce some breaking changes in the Mobject interface soon, so I'll wait a bit until I really do that. :-)
      And finally: thank you for the kind words, again!

  • @AK56fire
    @AK56fire 2 года назад

    Very, and I do mean very, helpful video. Please give more examples of deriving from Animation class, and then animating.

    • @behackl
      @behackl  2 года назад +1

      Thanks for the kind words! I'll probably not do another video on the Animation class next, but if you would like to see more examples for implementations I recommend to take a look at the different animations in the library at github.com/ManimCommunity/manim/tree/main/manim/animation -- in the end, these are also "just" custom Animation classes. :-)

  • @matthewjames7513
    @matthewjames7513 2 года назад

    Thanks so much for this :) I really appreciate your help via youtube and via the discord channel. I'm still new to Python but I don't get why at 34:39 you used 'Animation' instead of 'Scene'. I don't really understand the arguments in here in general I suppose :( Some general explanation would be great, thanks!

    • @behackl
      @behackl  2 года назад

      Thanks for the kind words! The notation you are referring to at 34:39 is Python's way of declaring which classes inherit from which -- and in the example, we implement a custom animation class (which thus has to inherit from Manim's Animation class). It is then also used as an animation: a bit later, we use self.play(Disperse(...)) in the construct method of the actual Scene class. You can think of inheritance this way: if "Disperse" inherits from "Animation", then it knows (and has!) all the attributes and methods defined for the Animation class as well.
      You can read more about the concept here: docs.python.org/3/tutorial/classes.html -- or any other tutorial on object oriented programming in Python. :-)

  • @eshaannagavenkata8836
    @eshaannagavenkata8836 2 года назад +1

    it would be nice if you zoomed in the code, its is to see while coding in split screen

    • @behackl
      @behackl  2 года назад +1

      Will try to improve code font size in the next episode! In the meantime, you can also copy the code I am writing from here: github.com/behackl/manim-with-ease/blob/main/E03%20-%20animations.ipynb

    • @eshaannagavenkata8836
      @eshaannagavenkata8836 2 года назад

      @@behackl thank you very much

  • @heonymath-os9tg
    @heonymath-os9tg 11 месяцев назад

    I'm always watching it well.
    I'm sorry, but can you add subtitles?

  • @puppergump4117
    @puppergump4117 2 года назад

    I guess understanding how the animations work is good, but then again I don't think us noobs would be using custom animations until we get a handle on the ones in the library.

    • @behackl
      @behackl  2 года назад

      Are there any particular ones you would like to see discussed in more detail? In general, I don't want to duplicate *too* much information that is already present in the documentation which is why I'm trying to go for something a bit different with my videos. :-)

    • @puppergump4117
      @puppergump4117 2 года назад

      @@behackl I'll have to finish watching the series first. If you haven't gone over best practices for making these I'd like to see that.

  • @BanMidouSan
    @BanMidouSan 2 года назад

    3*useful😁

  • @gujodde2489
    @gujodde2489 2 года назад

    Thank you for your tutorials! they are really helpful since manim is not as well documented as other languages like python. I'm currently relying heavily on your tutorials and they are really helping me to progress! I also have a request, is it possible for you to make a tutorial about the animation in this video ruclips.net/video/qMoP0LAhbkc/видео.html I'm really curious about how it is down. It will be awesome if you can cover it in your next tutorials when you intend to make more. This animation is really nice! Anyways, thank you for your effort.

    • @behackl
      @behackl  2 года назад

      Great to hear that you find my videos helpful! As for your request, I'd like to focus on more general aspects of the library for a bit longer, so I'm not sure how well that would fit to the series right now -- but the creator of the animation is a member of Manim's Discord server (manim.community/discord ) as well, I'm sure they are happy to answer questions about their animation. :-)