Coder Social home page Coder Social logo

No module named 'manim_imports_ext' about videos HOT 14 OPEN

3b1b avatar 3b1b commented on July 16, 2024
No module named 'manim_imports_ext'

from videos.

Comments (14)

TonyCrane avatar TonyCrane commented on July 16, 2024 2
D:\Project\3blue1brown>manim fourier.py
Manim Community v0.11.0

[18:18:55] INFO     OpenGL_accelerate module loaded                      acceleratesupport.py:13
           INFO     Using accelerated ArrayDatatype                         arraydatatype.py:280

(process:17712): GLib-GIO-WARNING **: 18:18:55.854: Unexpectedly, UWP app `Microsoft.Print3D_3.3.791.0_x64__8wekyb3d8bbwe' (AUMId `Microsoft.Print3D_8wekyb3d8bbwe!App') supports 5 extensions but has no verbs

(process:17712): GLib-GIO-WARNING **: 18:18:55.868: Unexpectedly, UWP app `SiliconBendersLLC.Sketchable_5.0.13.0_x64__r2kxzpx527qgj' (AUMId `SiliconBendersLLC.Sketchable_r2kxzpx527qgj!App') supports 11 extensions but has no verbs

(process:17712): GLib-GIO-WARNING **: 18:18:55.875: Unexpectedly, UWP app `5957Turnipsoft.freda_4.32.2.0_x64__ypmq2qh89vmny' (AUMId `5957Turnipsoft.freda_ypmq2qh89vmny!App') supports 4 extensions but has no verbs

(process:17712): GLib-GIO-WARNING **: 18:18:55.882: Unexpectedly, UWP app `Microsoft.WindowsSoundRecorder_10.1912.10073.0_x64__8wekyb3d8bbwe' (AUMId `Microsoft.WindowsSoundRecorder_8wekyb3d8bbwe!App') supports 1 extensions but has no verbs
[10/24/21 18:18:56] ERROR                                                       module_ops.py:75
                                There are no scenes inside that module

[18:18:56] ERROR                                                                module_ops.py:75
                       There are no scenes inside that module

           DEBUG    Starting new HTTPS connection (1): pypi.org:443        connectionpool.py:939
           DEBUG    https://pypi.org:443 "GET /pypi/manim/json HTTP/1.1"   connectionpool.py:433
                    200 8766
[10/24/21 18:18:56] ERROR                     module_ops.py:75 
There are no scenes inside that module

[18:18:56] ERROR                                     module_ops.py:75
There are no scenes inside that module

maybe I need scenes

Don't use the community version to render 3b1b's video code.

from videos.

LuisZapataYamo avatar LuisZapataYamo commented on July 16, 2024 2

Thank you for sharing this great work!

Traceback (most recent call last):
  File "D:\test.py", line 4, in <module>
    from manim_imports_ext import *
ModuleNotFoundError: No module named 'manim_imports_ext'
[Finished in 0.6s with exit code 1]
[shell_cmd: python -u "D:\test.py"]

$ manimgl -v
[12:10:37] INFO     No OpenGL_accelerate module loaded: acceleratesupport.py:17
                    No module named 'OpenGL_accelerate'
ManimGL v1.2.0

$ manim --version
Manim Community v0.11.0

how to solve these?

Part 1 (Error)

In the module error is for not recognize the root folder.
The solution is add the module sys and also add sys.path.append('.') in your file if it is in:
--root/
---fourier.py
But if your file is in:
--root/
---fourier/
----fourier.py
Then add sys.path.append('..')

Part 2 (Scene)

The principal is the use of the scenes at execute the command manimgl. For example manimgl fourier.py [nameScene].

from videos.

andrewHolsaeter avatar andrewHolsaeter commented on July 16, 2024 1

Neither of us suggested adding anything to PATH. We were suggesting adding to PYTHONPATH which is a list of directories python will use to check for locally installed packages/modules, i.e. main_imports_ext.py.

The problem is that each video code calls from manim_imports_ext import * as the first line of code to execute. If python doesn't find main_imports_ext installed globally, it will look for the module/file in the same directory as the executing script. And obviously it doesn't find it due to the nested folder structure of this repo.

Maybe I'm completely missing something here (very much possible), like something in relation to manim, but there is no way a fresh clone of this and the manim repo will be able to run these video scripts based on the current README isntructions.

Perhaps you (and the devs) intstalled mainim_imports_ext.py globally and forgot about this behavior?

from videos.

jsegoviamartin avatar jsegoviamartin commented on July 16, 2024 1

Did anybody solve this issue?

from videos.

arbaleast avatar arbaleast commented on July 16, 2024

Thanks, I'm already work out these problem.

from videos.

arbaleast avatar arbaleast commented on July 16, 2024

but I'm rookies, I don't know how to use fourier.py
For example, should I call this function ?

def get_fourier_graph(
    axes, time_func, t_min, t_max,
    n_samples = NUM_SAMPLES_FOR_FFT,
    complex_to_real_func = lambda z : z.real,
    color = RED,
    )

and how to set parameters.Thanks in advance.

from videos.

arifyunando avatar arifyunando commented on July 16, 2024

Thanks, I'm already work out these problem.

can you tell me how to resolve this, I have the same problem

from videos.

arbaleast avatar arbaleast commented on July 16, 2024

can you tell me how to resolve this, I have the same problem

you need manim_imports_ext.py and custom, put them together
like this
image

from videos.

arbaleast avatar arbaleast commented on July 16, 2024

But I don't know how to use fourier.py
image

from videos.

arbaleast avatar arbaleast commented on July 16, 2024
D:\Project\3blue1brown>manim fourier.py
Manim Community v0.11.0

[18:18:55] INFO     OpenGL_accelerate module loaded                      acceleratesupport.py:13
           INFO     Using accelerated ArrayDatatype                         arraydatatype.py:280

(process:17712): GLib-GIO-WARNING **: 18:18:55.854: Unexpectedly, UWP app `Microsoft.Print3D_3.3.791.0_x64__8wekyb3d8bbwe' (AUMId `Microsoft.Print3D_8wekyb3d8bbwe!App') supports 5 extensions but has no verbs

(process:17712): GLib-GIO-WARNING **: 18:18:55.868: Unexpectedly, UWP app `SiliconBendersLLC.Sketchable_5.0.13.0_x64__r2kxzpx527qgj' (AUMId `SiliconBendersLLC.Sketchable_r2kxzpx527qgj!App') supports 11 extensions but has no verbs

(process:17712): GLib-GIO-WARNING **: 18:18:55.875: Unexpectedly, UWP app `5957Turnipsoft.freda_4.32.2.0_x64__ypmq2qh89vmny' (AUMId `5957Turnipsoft.freda_ypmq2qh89vmny!App') supports 4 extensions but has no verbs

(process:17712): GLib-GIO-WARNING **: 18:18:55.882: Unexpectedly, UWP app `Microsoft.WindowsSoundRecorder_10.1912.10073.0_x64__8wekyb3d8bbwe' (AUMId `Microsoft.WindowsSoundRecorder_8wekyb3d8bbwe!App') supports 1 extensions but has no verbs
[10/24/21 18:18:56] ERROR                                                       module_ops.py:75
                                There are no scenes inside that module

[18:18:56] ERROR                                                                module_ops.py:75
                       There are no scenes inside that module

           DEBUG    Starting new HTTPS connection (1): pypi.org:443        connectionpool.py:939
           DEBUG    https://pypi.org:443 "GET /pypi/manim/json HTTP/1.1"   connectionpool.py:433
                    200 8766

[10/24/21 18:18:56] ERROR                     module_ops.py:75 
There are no scenes inside that module

[18:18:56] ERROR                                     module_ops.py:75
There are no scenes inside that module

maybe I need scenes

from videos.

pyiso80 avatar pyiso80 commented on July 16, 2024

I've been trying to run 3b1b videos using manimgl. The manim_imports_ext not found can be fixed with 3 methods as far as I could figure out:

  1. adding these 3 lines in the newton_fractal.py file for instance

import sys
sys.path.append(".")
sys.path.append("..")

and running manimgl newton_fractal.py SceneName in Terminal.

2)running the following in Terminal before executing manimgl. Of course you will have to change the path to point to your project folder where 3b1b's src files are placed
export PYTHONPATH=${PYTHONPATH}:/Users/john/Manim/videos

3)I use VSCode and my tasks.json file looks like the following. This is my most preferred way since I use VSCode and running the scene files with tasks is easier.

{
"version": "2.0.0",
"tasks": [
{
"label": "Render",
"type": "shell",
"command": "export PYTHONPATH=${PYTHONPATH}:${workspaceFolder};manimgl ${file} ${input:Scene} ${input:opt}",
"problemMatcher": [],
"group": {
"kind": "build",
"isDefault": true
}
}
],
"inputs": [
{
"id": "Scene",
"type": "command",
"command": "memento.promptString",
"args": {
"id": "Scene",
"description": "Enter Scene:",
"default": "",
"type": "promptString"
}
},
{
"id": "opt",
"type": "command",
"command": "memento.promptString",
"args": {
"id": "opt",
"description": "Render options",
"default": "-s",
}
}

],

}

from videos.

andrewHolsaeter avatar andrewHolsaeter commented on July 16, 2024

Expanding on option 2 to make it more permanent for windows 10 users:

  1. Search for "Edit system environmental variables" in the windows search bar and click that
  2. Click the "Environment Variables" option
  3. In the User variables section, either click "New" if PYTHONPATH variable doesn't exists already, or "Edit" if it is there
  4. Add the path of where manim_imports_ext.py is located
  5. Click OK/apply to everything and restart your shell

tempsnip

from videos.

cornflakesdev avatar cornflakesdev commented on July 16, 2024

Don't add anything to PATH.

Include custom_config.yml: and it should be fixed.

Your folder hierarchy should look like this:
image

from videos.

Mathematicien123 avatar Mathematicien123 commented on July 16, 2024

I have a problem
d ffmpeg or avconv - defaulting to ffmpeg, but may not work
warn("Couldn't find ffmpeg or avconv - defaulting to ffmpeg, but may not work", RuntimeWarning)
Traceback (most recent call last):
File "C:\Users\USER\Desktop\python course\sos.py", line 1, in
from manim_imports_ext import *
File "C:\Users\USER\Desktop\python course\manim_imports_ext.py", line 2, in
from manimlib.mobject.svg.old_tex_mobject import *
ModuleNotFoundError: No module named 'manimlib.mobject.svg.old_tex_mobject'

from videos.

Related Issues (20)

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.