3b1b / videos

Code for the manim-generated scenes used in 3blue1brown videos
5.79k stars 1.55k forks source link

Starting the different files #7

Closed ghost closed 2 years ago

ghost commented 2 years ago

Hi guys. I have a completely basic question. How can I start the different Python scripts. Manim is properly installed and ready to run. However, I don't know how to proceed here. Can you help me? With kind regards @Zeyecx

PS C:\...\videos> python .\_2020\chess.py
Traceback (most recent call last):
  File "C:\Users\Zeyecx\Desktop\tmp\videos\_2020\chess.py", line 1, in <module>
    from manim_imports_ext import *
ModuleNotFoundError: No module named 'manim_imports_ext'

Even in manim itself, I cannot start the project.

PS C:\...\videos> manim .\_2020\chess.py
Traceback (most recent call last):
  File "c:\programdata\anaconda3\lib\runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "c:\programdata\anaconda3\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\ProgramData\Anaconda3\Scripts\manim.exe\__main__.py", line 7, in <module>
  File "c:\programdata\anaconda3\lib\site-packages\manimlib\__init__.py", line 9, in main
    config = manimlib.config.get_configuration(args)
  File "c:\programdata\anaconda3\lib\site-packages\manimlib\config.py", line 155, in get_configuration
    module = get_module(args.file)
  File "c:\programdata\anaconda3\lib\site-packages\manimlib\config.py", line 150, in get_module
    spec.loader.exec_module(module)
  File "<frozen importlib._bootstrap_external>", line 783, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File ".\_2020\chess.py", line 1, in <module>
    from manim_imports_ext import *
ModuleNotFoundError: No module named 'manim_imports_ext'
Wleisure95 commented 2 years ago

Me too

TonyCrane commented 2 years ago

Adding the folder where the manim_imports_ext.py file is located to the PATH or PYTHONPATH environment variable may solve this.

Wleisure95 commented 2 years ago

Adding the folder where the manim_imports_ext.py file is located to the PATH or PYTHONPATH environment variable may solve this.

Thxxxx!

I ll Try

ghost commented 2 years ago

Adding the folder where the manim_imports_ext.py file is located to the PATH or PYTHONPATH environment variable may solve this.

Unfortunately, I could not solve the problem this way. I am also sure that I did it correctly. The problem remains the same.

In addition, I tried putting a project from one year into the same folder as the import. However, this was also unsuccessful. Even though the error was different. Manim itself works for me without any major problems.

@Wleisure95. Were you able to solve the problem with @TonyCrane's tip? Maybe the problem is really just me.

olivierleblanc commented 2 years ago

Hello,

Trying to make the videos from this repository during a couple of hours, I didn't manage to make it work either. The problem seems to be deeper than a simple dependency issue, it seems that some 'scene' classes such as 'ExternallyAnimatedScene' or 'TeacherStudentScene' are missing in these folders.

ghost commented 2 years ago

I played around with the folder structure a bit. Now it finds the import list. However, it does not find a scene in the respective Python file. image

TonyCrane commented 2 years ago

please don't use the community version of manim to render 3b1b's projects

ghost commented 2 years ago

please don't use the community version of manim to render 3b1b's projects

Ok. I didn't know there was a difference until now. I apologise for that. With kind regards @Zeyecx

ghost commented 2 years ago

please don't use the community version of manim to render 3b1b's projects

I have now installed the other version. Unfortunately, it doesn't work with it either.

Wleisure95 commented 2 years ago

Hello,

Trying to make the videos from this repository during a couple of hours, I didn't manage to make it work either. The problem seems to be deeper than a simple dependency issue, it seems that some 'scene' classes such as 'ExternallyAnimatedScene' or 'TeacherStudentScene' are missing in these folders.

Me too

Wleisure95 commented 2 years ago

Adding the folder where the manim_imports_ext.py file is located to the PATH or PYTHONPATH environment variable may solve this.

Unfortunately, I could not solve the problem this way. I am also sure that I did it correctly. The problem remains the same.

In addition, I tried putting a project from one year into the same folder as the import. However, this was also unsuccessful. Even though the error was different. Manim itself works for me without any major problems.

@Wleisure95. Were you able to solve the problem with @TonyCrane's tip? Maybe the problem is really just me.

I can import 'manim_imports_ext' export PATH=path/to/the/file/:$PATH