英文:
Manim not installing on Google Colab
问题
I did pip install manim
and got an error:
Getting requirements to build wheel did not run successfully.
exit code: 1
See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
Getting requirements to build wheel did not run successfully.
exit code: 1
See above for output.
Then I tried !pip install manimce
and got an exception:
Exception: You have installed Manim from `manimce` PyPI package which is deprecated and no longer updated. Please uninstall `manimce` and install Manim from `manim` PyPI package.
Plz help...
英文:
I did pip install manim
and got an error:
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.
Then I tried !pip install manimce
and got an exception:
Exception: You have installed Manim from `manimce` PyPI package which is deprecated and no longer updated. Please uninstall `manimce` and install Manim from `manim` PyPI package.
Plz help...
答案1
得分: 1
pip install manimce
绝对是错误的,并且指的是 Manim 的过时版本。
关于 pip install manim
过程中的错误,它应该告诉您问题出在哪里,即哪个 Python 包无法安装。
我没有在 Colab 上的经验,但 ManimCE Discord 服务器上的其他用户可能有... 我在哪里可以找到更多学习 Manim 的资源?
要在这里给出最终答案: 在 ManimCE 的在线文档中,为了获得包括 LaTeX 在内的完整安装,您需要运行以下命令:
!sudo apt update
!sudo apt install libcairo2-dev ffmpeg \
texlive texlive-latex-extra texlive-fonts-extra \
texlive-latex-recommended texlive-science \
tipa libpango1.0-dev
!pip install manim
!pip install IPython --upgrade
英文:
pip install manimce
is definitely wrong and refers to an outdated version of Manim.
Regarding your error during pip install manim
it should tell you where the problem lies, i.e. which Python package could not be installed.
I have no experience with Colab, but other users on the ManimCE Discord server do... Where can I find more resources for learning Manim?
Ok to give the definitive answer here: it is in the ManimCE online documentation, in order to get a full install including LaTeX you need to run the following commands:
!sudo apt update
!sudo apt install libcairo2-dev ffmpeg \
texlive texlive-latex-extra texlive-fonts-extra \
texlive-latex-recommended texlive-science \
tipa libpango1.0-dev
!pip install manim
!pip install IPython --upgrade
答案2
得分: 0
Solution
这可能是因为您没有安装运行 manim 所需的要求。
编辑:之前的回答我的错。请尝试这个替代方法:
正确的解决方法
!sudo apt update
!sudo apt install libcairo2-dev ffmpeg texlive texlive-latex-extra texlive-fonts-extra texlive-latex-recommended texlive-science tipa libpango1.0-dev
!pip install manim
!pip install IPython --upgrade
完成后,会在单元格下方出现一个重新启动运行时的提示。
重新启动运行时,跳过上面的单元格,然后执行 from manim import *
来开始使用 manim
。
旧答案
请忽略并不要遵循。
这个类似过去问题的回答可能会有所帮助。
根据 Google Colab 的格式描述的解决方法:
!apt-get install sox ffmpeg libcairo2 libcairo2-dev
!apt-get install texlive-full
!pip install manim
英文:
Solution
This may be happening because you didn't install the requirements to run manim.
Edit: My bad for the previous answer. Try this instead:
Correct Solution
!sudo apt update
!sudo apt install libcairo2-dev ffmpeg texlive texlive-latex-extra texlive-fonts-extra texlive-latex-recommended texlive-science tipa libpango1.0-dev
!pip install manim
!pip install IPython --upgrade
After finishing this, a prompt for restarting runtime will appear below the cell.
Restart the runtime, skip the cell above, and start using manim
by executing from manim import *
Old Answer
Ignore and do not follow.
This answer of a similar past question might help.
Solution described (and modified according to Google Colab's format):
!apt-get install sox ffmpeg libcairo2 libcairo2-dev
!apt-get install texlive-full
!pip install manim
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论