2

I am currently working with manim, I have structured my project in the form of a package Directory where the project is located when trying to run any file I usually do it with the command

python -m animations.example

This from a directory outside of animations, the question is that when trying run the file with manim

manim -p animations\example.py Escena

It throws an error as to why in the code of example.py I use variables from the other modules of the package:

from manim import *
from components.backgrounds import *


class Escena(MovingCameraScene):
    def construct(self):
        #change background
        self.camera.background = black

        message = Text("Hello world")
        self.play(Write(message))
        self.play(Wiggle(message), run_time=3)
        self.play(Unwrite(message))

I think this is because when using the manim command it doesn't recognize the imported modules and used, then try using a command something like the first:

manim -p animations.example.Escena

But it doesn't work either, I think this is due to a correct use of the modules, but I don't know how to solve this mishap help!

manim -p animations.example.Escena

Then the Scene is rendered and shows the video, but that didn't happen

0 Answers0