mirror of
https://github.com/3b1b/manim.git
synced 2025-04-13 09:47:07 +00:00
Update README.md
This commit is contained in:
parent
a91c0d3bc4
commit
4ead3627fd
1 changed files with 6 additions and 11 deletions
17
README.md
17
README.md
|
@ -27,22 +27,17 @@ python3 -m manim example_scenes.py SquareToCircle -pl
|
|||
```
|
||||
|
||||
### Using Docker
|
||||
Since it's a bit tricky to get all the dependencies set up just right, there is a Dockerfile provided in this repo as well as [a premade image on Docker Hub](https://hub.docker.com/r/eulertour/manim/tags/).
|
||||
Since it's a bit tricky to get all the dependencies set up just right, there is a Dockerfile and Compose file provided in this repo as well as [a premade image on Docker Hub](https://hub.docker.com/r/eulertour/manim/tags/). The Dockerfile contains instructions on how to build a manim image, while the Compose file contains instructions on how to run the image.
|
||||
|
||||
The image does not contain a copy of the repo. This is intentional, as it allows you to either bind mount a repo that you've cloned locally or clone any fork/branch you want. Since test coverage is painfully lacking, the image may not have dependencies for all of manim.
|
||||
The image does not contain a copy of the repo. This is intentional, as it allows you to either bind mount a repo that you've cloned locally or clone any fork/branch you want. In order to do this with the Compose file, you must set the `MANIM_PATH` environment variable to the absolute path to the manim repo.
|
||||
|
||||
1. [Install Docker](https://www.docker.com/products/overview)
|
||||
2. Get the docker image
|
||||
* Pull it (recommended): `docker pull eulertour/manim:latest`, or
|
||||
* Build it: `docker build -t manim .`
|
||||
3. Start the image
|
||||
* Bind mount a local repo (recommended): `docker run -itv /absolute/path/to/your/local/manim/repo:/root/manim eulertour/manim` or
|
||||
* Clone a remote repo: `docker run -it eulertour/manim`, then `git clone https://github.com/3b1b/manim.git`
|
||||
4. Render an animation
|
||||
2. [Install Docker Compose](https://docs.docker.com/compose/install/)
|
||||
3. Render an animation
|
||||
```sh
|
||||
cd manim
|
||||
python3 -m manim example_scenes.py SquareToCircle -l
|
||||
MANIM_PATH=/absolute/path/to/manim/repo docker-compose run python -m manim example_scenes.py SquareToCircle -l
|
||||
```
|
||||
The first time you execute the above command, Docker will pull the image from Docker Hub and cache it. Any subsequent runs until the image is evicted will use the cached image.
|
||||
Note that the image doesn't have any development tools installed and can't preview animations. Its purpose is building and testing only.
|
||||
|
||||
## Using manim
|
||||
|
|
Loading…
Add table
Reference in a new issue