3b1b / manim

Animation engine for explanatory math videos
MIT License
70.79k stars 6.23k forks source link

self.get_points() == old_points error #2038

Closed longlongvip closed 1 year ago

longlongvip commented 1 year ago

Describe the error

if not np.all(self.get_points() == old_points):
ValueError: operands could not be broadcast together with shapes (24,3) (0,3)

Code and Error

Code:

from manimlib import *
class P(Scene):
    def construct(self):
        circle = Circle()
        circle.set_fill(BLUE, opacity=0.5)
        circle.set_stroke(BLUE_E, width=4)
        self.add(circle)
if __name__ == "__main__":
    f_video = 0
    if f_video:
        os.system("manimgl {} P -o --file_name {}".format(__file__, "Output"))
    else:
        os.system("manimgl {} ".format(__file__))

Error:

manimlib\mobject\types\vectorized_mobject.py
if not np.all(self.get_points() == old_points):
ValueError: operands could not be broadcast together with shapes (24,3) (0,3)

Environment

OS System: Windows 11 manim version: 1.6.1 python version:3.10

Detais

sundebug commented 1 year ago

numpy <=1.24

dx3906999 commented 1 year ago

Thanks! It does work!