Code Monkey home page Code Monkey logo

manim's Introduction

logo

CI Documentation Status MIT License Manim Subreddit Manim Discord

Manim is an animation engine for explanatory math videos. It's used to create precise animations programmatically, as seen in the videos at 3Blue1Brown.

NOTE: This repository is maintained by the Manim Community, and is not associated with Grant Sanderson or 3Blue1Brown in any way (though we are definitely indebted to him for providing his work to the world). If you want to study how Grant makes his videos, head over to his repository (3b1b/manim). This is a more frequently updated repository than that one, and is recommended if you want to use Manim for your own projects.

Table of Contents:

Installation

Manim has a few dependencies that need to be installed before it. Please visit the documentation and follow the instructions according to your operating system.

Usage

Here is an example manim script:

from manim import *

class SquareToCircle(Scene):
    def construct(self):
        circle = Circle()
        square = Square()
        square.flip(RIGHT)
        square.rotate(-3 * TAU / 8)
        circle.set_fill(PINK, opacity=0.5)

        self.play(ShowCreation(square))
        self.play(Transform(square, circle))
        self.play(FadeOut(square))

Save this code in a file called example.py. Now open your terminal in the folder where you saved the file and execute

manim example.py SquareToCircle -pl

You should see your video player pop up and play a simple scene where a square is transformed into a circle. You can find some more simple examples in the GitHub repository. Visit the official gallery for more advanced examples.

Command line arguments

The general usage of manim is as follows:

manim-illustration

The -p flag in the command above is for previewing, meaning the video file will automatically open when it is done rendering. The -l flag is for a faster rendering at a lower quality.

Some other useful flags include:

  • -s to skip to the end and just show the final frame.
  • -n <number> to skip ahead to the n'th animation of a scene.
  • -f show the file in the file browser.

For a thorough list of command line arguments, visit the documentation.

Documentation

Documentation is in progress at ReadTheDocs.

Help with Manim

If you need help installing or using Manim, please take a look at the Reddit Community or the Discord Community. For bug reports and feature requests, please open an issue.

Contributing

Is always welcome. In particular, there is a dire need for tests and documentation. For guidelines please see the documentation. This project uses Poetry for management. You need to have poetry installed and available in your environment. You can find more information about it in its Documentation

License

The software is double-licensed under the MIT license, with copyright by 3blue1brown LLC (see LICENSE), and copyright by Manim Community Developers (see LICENSE.community).

manim's People

Contributors

3b1b avatar aathish04 avatar akashkarnatak avatar azarzadavila avatar behackl avatar bhbr avatar cobordism avatar danwaxman avatar eulertour avatar frozar avatar huguesdevimeux avatar jvdoorn avatar kilacoda-old avatar kolibril13 avatar leotrs avatar mertyildiran avatar mirefek avatar mysaajava avatar naveen521kk avatar nilaybhatia avatar npetrangelo avatar pgbiel avatar philippimhof avatar safinsingh avatar solara570 avatar sridhar3b1b avatar toxicglados avatar unexploredtest avatar xfbs avatar xy-23 avatar

Watchers

 avatar  avatar

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.