Skip to main content



PyPI Latest Release MIT License Code style: black Downloads

A Manim plugin designed to animate common data structures and algorithms


Manim DSA, short for Manim Data Structures & Algorithms, is a Manim plugin designed to animate common data structures and algorithms. Whether you are an educator looking to enhance your lectures, a student seeking to better understand these concepts, or a content creator making educational videos, Manim DSA provides a robust toolkit to bring abstract concepts to life.

Table of Contents:

Installation

To install Manim DSA, you can use pip:

pip install manim-dsa

If you don't have Manim installed, please refer to the official Manim documentation for installation instructions.

Importing

Simply use the following line of code to import the package:

from manim_dsa import *

Usage

The following is an example Scene where an array, a stack and a graph are created.

from manim import *
from manim_dsa import *

class Example(Scene):
    def construct(self):
        graph = {
            'A': [('C', 11), ('D', 7)],
            'B': [('A', 5),  ('C', 3)],
            'C': [('A', 11), ('B', 3)],
            'D': [('A', 7),  ('C', 4)],
        }
        nodes_and_positions = {
            'A': LEFT * 1.5,
            'B': UP * 2,
            'C': RIGHT * 1.5,
            'D': DOWN * 2,
        }

        mArray = (
            MArray([1, 2, 3], style=MArrayStyle.BLUE)
            .add_indexes()
            .scale(0.9)
            .add_label(Text("Array", font="Cascadia Code"))
            .to_edge(LEFT, 1)
        )

        mStack = (
            MStack([3, 7, 98, 1], style=MStackStyle.GREEN)
            .scale(0.8)
            .add_label(Text("Stack", font="Cascadia Code"))
            .move_to(ORIGIN)
        )

        mGraph = (
            MGraph(graph, nodes_and_positions, MGraphStyle.PURPLE)
            .add_label(Text("Graph", font="Cascadia Code"))
            .to_edge(RIGHT, 1)
        )

        self.play(Create(mArray))
        self.play(Create(mStack))
        self.play(Create(mGraph))
        self.wait()

The result is as follows:

https://github.com/user-attachments/assets/05307dc9-65d9-4262-ae32-3fb53068c8e4

Documentation

Documentation is in progress at ReadtheDocs.

Help with Manim DSA

If you need help installing or using Manim DSA, or you need to submit a bug report or feature request, please open an issue.

Contributing

Contributions are welcome! Whether it’s reporting a bug, suggesting new features, or submitting pull requests, any help is greatly appreciated.

How to Cite Manim DSA

To demonstrate the value of Manim DSA, we ask that you cite Manim DSA in your work. Currently, the best way to cite Manim DSA is to go to the repository page (if you aren't already) and click the "cite this repository" button on the right sidebar. This will generate a citation in your preferred format, and will also integrate well with citation managers. For guidance on how to properly cite Manim, please refer to the Manim GitHub page.

License

Manim DSA is licensed under the MIT License. You are free to use, modify, and distribute this software as long as you include the original license.

Acknowledgements

  • Manim Community: For creating and maintaining the amazing Manim library.
  • drageelr: For the inspiration behind the array implementation.
  • Verdiana Pasqualini: For the inspiration behind the graph implementation.

Metadata

Release files for manim-dsa 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for manim-dsa 0.4.0
File Size Uploaded Provenance Actions
manim_dsa-0.4.0.tar.gz 477.2 kB With provenance Details for manim_dsa-0.4.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for manim-dsa 0.4.0
File Interpreter ABI Platform Actions
manim_dsa-0.4.0-py3-none-any.whl Python 3 none any Details for manim_dsa-0.4.0-py3-none-any.whl

Total release size: 812.5 kB

Release files / manim_dsa-0.4.0.tar.gz

Download URL manim_dsa-0.4.0.tar.gz
Size 477.2 kB
Tags Source
SHA-256 checksum
How to use checksums
6f1c953086c3e7d167a8071e8bb664170f19a74f981d9dc16da9e39777def040
BLAKE2b-256 checksum
How to use checksums
71af8706fc24f47810f8e3c6f4a40ca0700a3b36690a6a0d16bb6087ba22e714
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 12, 2025.

Transparency log

Release files / manim_dsa-0.4.0-py3-none-any.whl

Download URL manim_dsa-0.4.0-py3-none-any.whl
Size 335.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d867ea3fd1c63789538e11d9dc79943995389e564a8e387edaf63299bd106c18
BLAKE2b-256 checksum
How to use checksums
8a3dc888c525ac41faa2bfed1827e5a074800ac4c55cde8d3f1d4f7ebab97e6f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 12, 2025.

Transparency log

Security for manim-dsa 0.4.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for manim_dsa-0.4.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 12, 2025.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page