A community-maintained Python framework for creating mathematical animations.
updated some breaking scenes to python3
Ishan Dutta78b14c8be8f2
diff --git a/active_projects/eop/bayes_footnote.py b/active_projects/eop/bayes_footnote.pyindex 841ad8a2a..d7fbdbe0f 100644--- a/active_projects/eop/bayes_footnote.py+++ b/active_projects/eop/bayes_footnote.py@@ -1,6 +1,6 @@from big_ol_pile_of_manim_imports import *-from eop.bayes import IntroducePokerHand+from active_projects.eop.bayes import IntroducePokerHandSICKLY_GREEN = "#9BBD37"@@ -1362,7 +1362,7 @@ class CompareNumbersInBothExamples(Scene):"\\text{Not }", "\\text{%s}"%s2, ")","=", "1/100")- for s1, s2 in ("+", "Sick"), ("Correct", "Powers")+ for s1, s2 in [("+", "Sick"), ("Correct", "Powers")]])priors.next_to(likelihoods, UP, LARGE_BUFF)for group in priors, likelihoods:diff --git a/active_projects/eop/chapter1/million_flips.py b/active_projects/eop/chapter1/million_flips.pyindex 0a4282c51..5e98f4a06 100644--- a/active_projects/eop/chapter1/million_flips.py+++ b/active_projects/eop/chapter1/million_flips.py@@ -65,7 +65,7 @@ class MillionFlips(Scene):coins.replace, hundred_boxes[0])hundred_boxes[0].add(coins)- for box, prop in zip(hundred_boxes, proportions)[1:]:+ for box, prop in list(zip(hundred_boxes, proportions))[1:]:self.add(box)self.increment(n_flips_count, 100)self.increment(n_heads_count, int(np.round(prop * 100)))@@ -77,7 +77,7 @@ class MillionFlips(Scene):hundred_boxes.replace, ten_k_boxes[0])ten_k_boxes[0].add(hundred_boxes)- for box, prop in zip(ten_k_boxes, ten_k_proportions)[1:]:+ for box, prop in list(zip(ten_k_boxes, ten_k_proportions))[1:]:self.add(box)self.increment(n_flips_count, 10000)self.increment(n_heads_count, int(np.round(prop * 10000)))diff --git a/active_projects/eop/combinations.py b/active_projects/eop/combinations.pyindex d2ebc580a..d7fa056b2 100644--- a/active_projects/eop/combinations.py+++ b/active_projects/eop/combinations.py@@ -1783,7 +1783,7 @@ class IntroducePascalsTriangle(Scene):mob.rect = SurroundingRectangle(mob, color = color)rects.add(mob.rect)- rows_to_fade = VGroup(*rows[1:4] + rows[6:])+ rows_to_fade = VGroup(*rows[1:4], *rows[6:])rows_to_fade.save_state()top_row = rows[4]diff --git a/active_projects/eop/independence.py b/active_projects/eop/independence.pyindex 5003db5bb..2ab785507 100644--- a/active_projects/eop/independence.py+++ b/active_projects/eop/independence.py@@ -1515,7 +1515,7 @@ class ShowAllEightConditionals(Scene):equations.arrange_submobjects(DOWN)rect = SurroundingRectangle(- VGroup(*equations[0][7:]+equations[-1][7:]),+ VGroup(*equations[0][7:], *equations[-1][7:]),buff = SMALL_BUFF)rect.shift(0.5*SMALL_BUFF*RIGHT)@@ -1845,7 +1845,7 @@ class ShowFullDistribution(Scene):self.play(Transform(self.bar_chart, alt_charts[0]))self.wait()self.play(FadeOut(point_5_probs))- for rhs, chart in zip(alt_rhss, alt_charts)[1:]:+ for rhs, chart in list(zip(alt_rhss, alt_charts))[1:]:self.play(Transform(new_prob[-1], rhs))self.play(Transform(self.bar_chart, chart))self.wait(2)diff --git a/mobject/svg/tex_mobject.py b/mobject/svg/tex_mobject.pyindex e376e897f..2fc855ac8 100644--- a/mobject/svg/tex_mobject.py+++ b/mobject/svg/tex_mobject.py@@ -158,6 +158,7 @@ class TexMobject(SingleStringTexMobject):split_list = split_string_list_to_isolate_substring(tex_strings, *substrings_to_isolate)+ split_list = [item for sublist in split_list for item in sublist]split_list = list(map(str.strip, split_list))split_list = [s for s in split_list if s != '']return split_listdiff --git a/old_projects/alt_calc.py b/old_projects/alt_calc.pyindex 4e505573a..c3e93059c 100644--- a/old_projects/alt_calc.py+++ b/old_projects/alt_calc.py@@ -2209,7 +2209,7 @@ class GraphOnePlusOneOverX(GraphScene):x_max=x_max,color=self.func_graph_color,)- for x_min, x_max in (-10, -0.1), (0.1, 10)+ for x_min, x_max in [(-10, -0.1), (0.1, 10)]])func_graph.label = self.get_graph_label(upper_func_graph, "y = 1 + \\frac{1}{x}",diff --git a/old_projects/brachistochrone/misc.py b/old_projects/brachistochrone/misc.pyindex 812f8f96e..ea54e5ee4 100644--- a/old_projects/brachistochrone/misc.py+++ b/old_projects/brachistochrone/misc.py@@ -2,7 +2,7 @@ import numpy as npimport itertools as itfrom big_ol_pile_of_manim_imports import *-from brachistochrone.curves import Cycloid+from old_projects.brachistochrone.curves import Cycloidclass PhysicalIntuition(Scene):def construct(self):diff --git a/old_projects/brachistochrone/multilayered.py b/old_projects/brachistochrone/multilayered.pyindex 273511aac..bd584456c 100644--- a/old_projects/brachistochrone/multilayered.py+++ b/old_projects/brachistochrone/multilayered.py@@ -2,8 +2,8 @@ import numpy as npimport itertools as itfrom big_ol_pile_of_manim_imports import *-from brachistochrone.light import PhotonScene-from brachistochrone.curves import *+from old_projects.brachistochrone.light import PhotonScene+from old_projects.brachistochrone.curves import *class MultilayeredScene(Scene):diff --git a/old_projects/brachistochrone/wordplay.py b/old_projects/brachistochrone/wordplay.pyindex ca49a7fea..cf11bd24c 100644--- a/old_projects/brachistochrone/wordplay.py+++ b/old_projects/brachistochrone/wordplay.py@@ -3,7 +3,7 @@ import itertools as itimport osfrom big_ol_pile_of_manim_imports import *-from brachistochrone.drawing_images import sort_by_color+from old_projects.brachistochrone.drawing_images import sort_by_colorclass Intro(Scene):def construct(self):diff --git a/old_projects/crypto.py b/old_projects/crypto.pyindex 4fd62b932..b8e9afbe2 100644--- a/old_projects/crypto.py+++ b/old_projects/crypto.py@@ -14,7 +14,7 @@ def get_cursive_name(name):return resultdef sha256_bit_string(message):- hexdigest = sha256(message).hexdigest()+ hexdigest = sha256(message.encode('utf-8')).hexdigest()return bin(int(hexdigest, 16))[2:]def bit_string_to_mobject(bit_string):@@ -2316,7 +2316,7 @@ class YouListeningToBroadcasts(LedgerScene):self.remove(self.ledger)corners = [FRAME_X_RADIUS*RIGHT*u1 + FRAME_Y_RADIUS*UP*u2- for u1, u2 in (-1, 1), (1, 1), (-1, -1)+ for u1, u2 in [(-1, 1), (1, 1), (-1, -1)]]you = self.youyou.scale(2)@@ -5011,7 +5011,7 @@ class ShowManyExchanges(Scene):path_arc = np.pi,buff = MED_LARGE_BUFF)- for p1, p2 in (LEFT, RIGHT), (RIGHT, LEFT)+ for p1, p2 in [(LEFT, RIGHT), (RIGHT, LEFT)]]).set_color(WHITE)exchanges = VGroup(*[VGroup(*[diff --git a/old_projects/div_curl.py b/old_projects/div_curl.pyindex 27ec77c59..ffec9a96f 100644--- a/old_projects/div_curl.py+++ b/old_projects/div_curl.py@@ -272,7 +272,7 @@ class StreamLines(VGroup):if get_norm(last_point) > self.cutoff_norm:breakline = VMobject()- step = max(1, len(points) / self.n_anchors_per_line)+ step = max(1, int(len(points) / self.n_anchors_per_line))line.set_points_smoothly(points[::step])self.add(line)diff --git a/old_projects/efvgt.py b/old_projects/efvgt.pyindex 8923c564d..d1591baf0 100644--- a/old_projects/efvgt.py+++ b/old_projects/efvgt.py@@ -2786,7 +2786,7 @@ class DihedralCubeHomomorphism(GroupOfCubeSymmetries, SymmetriesOfSquare):in_place = True,run_time = abs(angle/(np.pi/2)))- for mob, axis in (square, raw_axis), (cube, posed_axis)+ for mob, axis in [(square, raw_axis), (cube, posed_axis)]])self.wait()if i == 2:diff --git a/old_projects/eoc/chapter1.py b/old_projects/eoc/chapter1.pyindex ac1a60b67..f0940d16d 100644--- a/old_projects/eoc/chapter1.py+++ b/old_projects/eoc/chapter1.py@@ -2326,7 +2326,7 @@ class PlayingTowardsDADX(AreaUnderParabola, ReconfigurableScene):equation.get_part_by_tex(tex),run_time = 2)- for mob, tex in (x_squared, f_tex), (dx, "dx"), (dA, "dA")+ for mob, tex in [(x_squared, f_tex), (dx, "dx"), (dA, "dA")]])self.play(Write(equation.get_part_by_tex("approx")))self.wait()@@ -2361,7 +2361,7 @@ class PlayingTowardsDADX(AreaUnderParabola, ReconfigurableScene):Circle(color = color).replace(mob, stretch = True).scale_in_place(1.5)- for mob, color in (self.A_func, RED), (self.deriv_equation, GREEN)+ for mob, color in [(self.A_func, RED), (self.deriv_equation, GREEN)]]q_marks = TexMobject("???")q_marks.next_to(A_circle, UP)diff --git a/old_projects/eoc/chapter10.py b/old_projects/eoc/chapter10.pyindex 683947217..80cf6ddc5 100644--- a/old_projects/eoc/chapter10.py+++ b/old_projects/eoc/chapter10.py@@ -1789,7 +1789,7 @@ class HigherTermsDontMessUpLowerTerms(Scene):path_arc = arc,color = c.get_color())- for c, arc in (c2, 0.9*np.pi), (c0, np.pi)+ for c, arc in [(c2, 0.9*np.pi), (c0, np.pi)]])no_affect_words = TextMobject("Doesn't affect \\\\ previous terms"diff --git a/old_projects/eoc/chapter3.py b/old_projects/eoc/chapter3.pyindex 57e788e79..0acafad3e 100644--- a/old_projects/eoc/chapter3.py+++ b/old_projects/eoc/chapter3.py@@ -2085,11 +2085,11 @@ class SquareRootOfX(Scene):stroke_width = 3).shift(s.get_corner(corner))for corner, vect in [(DOWN+LEFT, RIGHT), (UP+RIGHT, DOWN)]- for s in square, bigger_square+ for s in [square, bigger_square]])little_braces = VGroup(*[Brace(VGroup(*line_pair), vect, buff = 0)- for line_pair, vect in (lines[:2], RIGHT), (lines[2:], DOWN)+ for line_pair, vect in [(lines[:2], RIGHT), (lines[2:], DOWN)]])for brace in little_braces:tex = brace.get_text("$d\\sqrt{x}$", buff = SMALL_BUFF)diff --git a/old_projects/eoc/chapter8.py b/old_projects/eoc/chapter8.pyindex fb2ba5cd1..02a587d62 100644--- a/old_projects/eoc/chapter8.py+++ b/old_projects/eoc/chapter8.py@@ -1919,7 +1919,7 @@ class FindAntiderivative(Antiderivative):path_arc = -np.pi/6,run_time = 2,)- for i, j in (0, 1), (1, 0), (1, 2)+ for i, j in [(0, 1), (1, 0), (1, 2)]])self.wait()self.play(FadeIn(third))diff --git a/old_projects/eoc/footnote.py b/old_projects/eoc/footnote.pyindex f6656c452..9cb572b51 100644--- a/old_projects/eoc/footnote.py+++ b/old_projects/eoc/footnote.py@@ -634,7 +634,7 @@ class HowToReadNotation(GraphScene, ReconfigurableScene):ddf_over_dx_squared.get_part_by_tex(tex),path_arc = -np.pi/2,)- for mob, tex in (self.ddf, "df"), (self.dx_squared, "dx")+ for mob, tex in [(self.ddf, "df"), (self.dx_squared, "dx")]])self.wait(2)diff --git a/old_projects/eola/chapter1.py b/old_projects/eola/chapter1.pyindex 35202fdc3..581ede6b6 100644--- a/old_projects/eola/chapter1.py+++ b/old_projects/eola/chapter1.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.chapter0 import UpcomingSeriesOfVidoes+from old_projects.eola.chapter0 import UpcomingSeriesOfVidoesimport randomdiff --git a/old_projects/eola/chapter10.py b/old_projects/eola/chapter10.pyindex e7cb25bd4..c3abbd818 100644--- a/old_projects/eola/chapter10.py+++ b/old_projects/eola/chapter10.py@@ -1,8 +1,8 @@from big_ol_pile_of_manim_imports import *-from eola.chapter1 import plane_wave_homotopy-from eola.chapter3 import ColumnsToBasisVectors-from eola.chapter5 import get_det_text-from eola.chapter9 import get_small_bubble+from old_projects.eola.chapter1 import plane_wave_homotopy+from old_projects.eola.chapter3 import ColumnsToBasisVectors+from old_projects.eola.chapter5 import get_det_text+from old_projects.eola.chapter9 import get_small_bubbleclass OpeningQuote(Scene):@@ -309,7 +309,7 @@ class AllXAxisVectorsAreEigenvectors(ExampleTranformationScene):vectors = VGroup(*[self.add_vector(u*x*RIGHT, animate = False)for x in reversed(list(range(1, int(FRAME_X_RADIUS)+1)))- for u in -1, 1+ for u in [-1, 1]])vectors.set_color_by_gradient(YELLOW, X_COLOR)self.play(ShowCreation(vectors))@@ -360,7 +360,7 @@ class FullSneakyEigenspace(ExampleTranformationScene):vectors = VGroup(*[self.add_vector(u*x*(LEFT+UP), animate = False)for x in reversed(np.arange(0.5, 5, 0.5))- for u in -1, 1+ for u in [-1, 1]])vectors.set_color_by_gradient(MAROON_B, YELLOW)words = TextMobject("Stretch by 2")@@ -391,14 +391,14 @@ class NameEigenvectorsAndEigenvalues(ExampleTranformationScene):x_vectors = VGroup(*[self.add_vector(u*x*RIGHT, animate = False)for x in range(int(FRAME_X_RADIUS)+1, 0, -1)- for u in -1, 1+ for u in [-1, 1]])x_vectors.set_color_by_gradient(YELLOW, X_COLOR)self.remove(x_vectors)sneak_vectors = VGroup(*[self.add_vector(u*x*(LEFT+UP), animate = False)for x in np.arange(int(FRAME_Y_RADIUS), 0, -0.5)- for u in -1, 1+ for u in [-1, 1]])sneak_vectors.set_color_by_gradient(MAROON_B, YELLOW)self.remove(sneak_vectors)@@ -1442,7 +1442,7 @@ class RevisitExampleTransformation(ExampleTranformationScene):vectors = VGroup(*[self.add_vector(u*x*(LEFT+UP), animate = False)for x in range(4, 0, -1)- for u in -1, 1+ for u in [-1, 1]])vectors.set_color_by_gradient(MAROON_B, YELLOW)vectors.save_state()@@ -1635,7 +1635,7 @@ class ShearExample(RevisitExampleTransformation):vectors = VGroup(*[self.add_vector(u*x*RIGHT, animate = False)for x in range(int(FRAME_X_RADIUS)+1, 0, -1)- for u in -1, 1+ for u in [-1, 1]])vectors.set_color_by_gradient(YELLOW, X_COLOR)words = VGroup(@@ -2110,9 +2110,9 @@ class ChangeToEigenBasis(ExampleTranformationScene):VGroup(*[self.add_vector(u*x*vect, animate = False)for x in range(num, 0, -1)- for u in -1, 1+ for u in [-1, 1]])- for vect, num in (RIGHT, 7), (UP+LEFT, 4)+ for vect, num in [(RIGHT, 7), (UP+LEFT, 4)]]x_vectors.set_color_by_gradient(YELLOW, X_COLOR)v_vectors.set_color_by_gradient(MAROON_B, YELLOW)diff --git a/old_projects/eola/chapter11.py b/old_projects/eola/chapter11.pyindex 42279fa7f..8ccb53a6a 100644--- a/old_projects/eola/chapter11.py+++ b/old_projects/eola/chapter11.py@@ -1,9 +1,9 @@from big_ol_pile_of_manim_imports import *-from eola.chapter1 import plane_wave_homotopy-from eola.chapter3 import ColumnsToBasisVectors-from eola.chapter5 import NameDeterminant, Blob-from eola.chapter9 import get_small_bubble-from eola.chapter10 import ExampleTranformationScene+from old_projects.eola.chapter1 import plane_wave_homotopy+from old_projects.eola.chapter3 import ColumnsToBasisVectors+from old_projects.eola.chapter5 import NameDeterminant, Blob+from old_projects.eola.chapter9 import get_small_bubble+from old_projects.eola.chapter10 import ExampleTranformationSceneclass Student(PiCreature):CONFIG = {@@ -505,7 +505,7 @@ class DeterminantAndEigenvectorDontCare(LinearTransformationScene):vectors = VGroup(*[Vector(u*x*v)for x in range(7, 0, -1)- for u in -1, 1+ for u in [-1, 1]])vectors.set_color_by_gradient(MAROON_A, MAROON_C)result += list(vectors)diff --git a/old_projects/eola/chapter2.py b/old_projects/eola/chapter2.pyindex d38cb905f..a471f791c 100644--- a/old_projects/eola/chapter2.py+++ b/old_projects/eola/chapter2.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.chapter1 import plane_wave_homotopy+from old_projects.eola.chapter1 import plane_wave_homotopyclass OpeningQuote(Scene):def construct(self):@@ -239,7 +239,7 @@ class ShowVaryingLinearCombinations(VectorScene):)label_anims = [MaintainPositionRelativeTo(label, v)- for v, label in (v1, v1_label), (v2, v2_label)+ for v, label in [(v1, v1_label), (v2, v2_label)]]scalar_anims = self.get_scalar_anims(v1, v2, v1_label, v2_label)self.last_scalar_pair = (1, 1)@@ -270,13 +270,13 @@ class ShowVaryingLinearCombinations(VectorScene):scale_factor = 0.75,value_function = get_val_func(v))- for v, label in (v1, v1_label), (v2, v2_label)+ for v, label in [(v1, v1_label), (v2, v2_label)]]def get_rate_func_pair(self):return [squish_rate_func(smooth, a, b)- for a, b in (0, 0.7), (0.3, 1)+ for a, b in [(0, 0.7), (0.3, 1)]]def initial_scaling(self, v1, v2, label_anims, scalar_anims):diff --git a/old_projects/eola/chapter4.py b/old_projects/eola/chapter4.pyindex 453fe4c59..aad7fd53c 100644--- a/old_projects/eola/chapter4.py+++ b/old_projects/eola/chapter4.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.chapter3 import MatrixVectorMultiplicationAbstract+from old_projects.eola.chapter3 import MatrixVectorMultiplicationAbstractclass OpeningQuote(Scene):diff --git a/old_projects/eola/chapter5.py b/old_projects/eola/chapter5.pyindex a4e88d755..b5676e742 100644--- a/old_projects/eola/chapter5.py+++ b/old_projects/eola/chapter5.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.chapter3 import MatrixVectorMultiplicationAbstract+from old_projects.eola.chapter3 import MatrixVectorMultiplicationAbstractclass Blob(Circle):diff --git a/old_projects/eola/chapter6.py b/old_projects/eola/chapter6.pyindex 58cfb3f80..0b0363755 100644--- a/old_projects/eola/chapter6.py+++ b/old_projects/eola/chapter6.py@@ -379,7 +379,7 @@ class SystemOfEquations(Scene):Circle().replace(mob).scale_in_place(1.3)for mob in [VMobject(*equations.split()[i].split()[j:j+2])- for i, j in (1, 3), (2, 6)+ for i, j in [(1, 3), (2, 6)]]])zero_circles.set_color(PINK)diff --git a/old_projects/eola/chapter7.py b/old_projects/eola/chapter7.pyindex 7a742d11b..4b13712cb 100644--- a/old_projects/eola/chapter7.py+++ b/old_projects/eola/chapter7.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.footnote2 import TwoDTo1DTransformWithDots+from old_projects.eola.footnote2 import TwoDTo1DTransformWithDotsV_COLOR = YELLOWdiff --git a/old_projects/eola/chapter8.py b/old_projects/eola/chapter8.pyindex 462e437d6..af7ec3245 100644--- a/old_projects/eola/chapter8.py+++ b/old_projects/eola/chapter8.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.chapter5 import get_det_text, RightHandRule+from old_projects.eola.chapter5 import get_det_text, RightHandRuleU_COLOR = ORANGE@@ -1159,7 +1159,7 @@ class BiggerWhenPerpendicular(LinearTransformationScene):w.target = w.copy().rotate(np.pi/5)transforms = [self.get_matrix_transformation([v1.get_end()[:2], v2.get_end()[:2]])- for v1, v2 in (v, w), (v.target, w.target)+ for v1, v2 in [(v, w), (v.target, w.target)]]start_square, end_square = [square.copy().apply_function(transform)diff --git a/old_projects/eola/chapter8p2.py b/old_projects/eola/chapter8p2.pyindex fc2d9a871..b7584ece4 100644--- a/old_projects/eola/chapter8p2.py+++ b/old_projects/eola/chapter8p2.py@@ -1,6 +1,6 @@from big_ol_pile_of_manim_imports import *-from eola.chapter5 import get_det_text-from eola.chapter8 import *+from old_projects.eola.chapter5 import get_det_text+from old_projects.eola.chapter8 import *class OpeningQuote(Scene):diff --git a/old_projects/eola/chapter9.py b/old_projects/eola/chapter9.pyindex 7b9a04753..21fb1ee62 100644--- a/old_projects/eola/chapter9.py+++ b/old_projects/eola/chapter9.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.chapter1 import plane_wave_homotopy+from old_projects.eola.chapter1 import plane_wave_homotopyV_COLOR = YELLOWdiff --git a/old_projects/eola/thumbnails.py b/old_projects/eola/thumbnails.pyindex 4c7579eca..965125190 100644--- a/old_projects/eola/thumbnails.py+++ b/old_projects/eola/thumbnails.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from eola.chapter9 import Jennifer, You+from old_projects.eola.chapter9 import Jennifer, Youclass Chapter0(LinearTransformationScene):CONFIG = {diff --git a/old_projects/hanoi.py b/old_projects/hanoi.pyindex c7feeaeea..df5e7a75d 100644--- a/old_projects/hanoi.py+++ b/old_projects/hanoi.py@@ -2030,7 +2030,7 @@ class RecursiveSolutionToConstrained(RecursiveSolution):"Move disk %d,"%d,"Move %d-tower"%d,).set_color_by_tex("Move disk %d,"%d, color)- for d, color in (3, GREEN), (2, RED), (1, BLUE_C)+ for d, color in [(3, GREEN), (2, RED), (1, BLUE_C)]]sub_steps, sub_sub_steps = subdivisions[:2]for steps in subdivisions:diff --git a/old_projects/highD.py b/old_projects/highD.pyindex 6da534cd5..50f07295d 100644--- a/old_projects/highD.py+++ b/old_projects/highD.py@@ -1977,7 +1977,7 @@ class TwoDBoxWithSliders(TwoDimensionalCase):slider.number_to_point(0)-slider.number_to_point(slider.center_value))for slider in self.sliders- for mob in slider.real_estate_ticks, slider.dial+ for mob in [slider.real_estate_ticks, slider.dial]])self.center_point = [0, 0]@@ -1996,7 +1996,7 @@ class TwoDBoxWithSliders(TwoDimensionalCase):slider.number_to_point(x)-slider.number_to_point(0))for x, slider in zip(original_center_point, self.sliders)- for mob in slider.real_estate_ticks, slider.dial+ for mob in [slider.real_estate_ticks, slider.dial]])self.center_point = original_center_point@@ -2296,7 +2296,7 @@ class ThreeDBoxExampleWithSliders(SliderScene):re_words.to_corner(UP+LEFT)re_line = DashedLine(*[self.sliders[i].number_to_point(target_x) + MED_SMALL_BUFF*vect- for i, vect in (0, LEFT), (2, RIGHT)+ for i, vect in [(0, LEFT), (2, RIGHT)]])new_arrow = Arrow(re_words.get_corner(DOWN+RIGHT), re_line.get_left(),@@ -2322,7 +2322,7 @@ class ThreeDBoxExampleWithSliders(SliderScene):def compare_to_halfway_point(self):half_line = Line(*[self.sliders[i].number_to_point(0.5)+MED_SMALL_BUFF*vect- for i, vect in (0, LEFT), (2, RIGHT)+ for i, vect in [(0, LEFT), (2, RIGHT)]])half_line.set_stroke(MAROON_B, 6)half_label = TexMobject("0.5")@@ -2507,7 +2507,7 @@ class FourDBoxExampleWithSliders(ThreeDBoxExampleWithSliders):target_vector = 0.5*np.ones(4)re_line = DashedLine(*[self.sliders[i].number_to_point(0.5)+MED_SMALL_BUFF*vect- for i, vect in (0, LEFT), (-1, RIGHT)+ for i, vect in [(0, LEFT), (-1, RIGHT)]])half_label = TexMobject("0.5")half_label.scale(self.sliders[0].number_scale_val)@@ -2655,7 +2655,7 @@ class TwoDInnerSphereTouchingBox(TwoDBoxWithSliders, PiCreatureScene):randy = self.randytangency_points = VGroup(*[Dot(self.plane.coords_to_point(x, y))- for x, y in (1, 0), (0, 1), (-1, 0), (0, -1)+ for x, y in [(1, 0), (0, 1), (-1, 0), (0, -1)]])tangency_points.set_fill(YELLOW, 0.5)@@ -2747,7 +2747,7 @@ class FiveDBoxExampleWithSliders(FourDBoxExampleWithSliders):target_x = 1-np.sqrt(0.2)re_line = DashedLine(*[self.sliders[i].number_to_point(target_x)+MED_SMALL_BUFF*vect- for i, vect in (0, LEFT), (-1, RIGHT)+ for i, vect in [(0, LEFT), (-1, RIGHT)]])re_words = TextMobject("$0.2$", "units of real \\\\ estate each"@@ -2785,7 +2785,7 @@ class FiveDBoxExampleWithSliders(FourDBoxExampleWithSliders):def show_halfway_point(self):half_line = Line(*[self.sliders[i].number_to_point(0.5)+MED_SMALL_BUFF*vect- for i, vect in (0, LEFT), (-1, RIGHT)+ for i, vect in [(0, LEFT), (-1, RIGHT)]])half_line.set_color(MAROON_B)half_label = TexMobject("0.5")@@ -2943,7 +2943,7 @@ class TenDBoxExampleWithSliders(FiveDBoxExampleWithSliders):target_x = 1-np.sqrt(1./self.n_sliders)re_line = DashedLine(*[self.sliders[i].number_to_point(target_x)+MED_SMALL_BUFF*vect- for i, vect in (0, LEFT), (-1, RIGHT)+ for i, vect in [(0, LEFT), (-1, RIGHT)]])re_rects = VGroup()diff --git a/old_projects/hilbert/fractal_porn.py b/old_projects/hilbert/fractal_porn.pyindex 6199ff9eb..dd53832ec 100644--- a/old_projects/hilbert/fractal_porn.py+++ b/old_projects/hilbert/fractal_porn.py@@ -1,5 +1,5 @@from big_ol_pile_of_manim_imports import *-from hilbert.curves import *+from old_projects.hilbert.curves import *class Intro(TransformOverIncreasingOrders):@staticmethoddiff --git a/old_projects/leibniz.py b/old_projects/leibniz.pyindex a5cbe0157..f50e0b991 100644--- a/old_projects/leibniz.py+++ b/old_projects/leibniz.py@@ -3443,7 +3443,7 @@ class IntroduceChi(FactorizationPattern):CONFIG = {"numbers_list" : [list(range(i, 36, d))- for i, d in (1, 4), (3, 4), (2, 2)+ for i, d in [(1, 4), (3, 4), (2, 2)]],"colors" : [GREEN, RED, YELLOW]}diff --git a/old_projects/tattoo.py b/old_projects/tattoo.pyindex 7de497bb0..b1090a818 100644--- a/old_projects/tattoo.py+++ b/old_projects/tattoo.py@@ -747,7 +747,7 @@ class RenameAllInTermsOfSine(Scene):self.wait(2)anims = []- for mob, rhs_mob in zip(mobs, rhs_mobs)[1:3]:+ for mob, rhs_mob in list(zip(mobs, rhs_mobs))[1:3]:anims += [FadeOut(rhs_mob),mob.restore,diff --git a/old_projects/triangle_of_power/end.py b/old_projects/triangle_of_power/end.pyindex bc2fb3d5f..e9b3dccb7 100644--- a/old_projects/triangle_of_power/end.py+++ b/old_projects/triangle_of_power/end.py@@ -1,6 +1,6 @@from big_ol_pile_of_manim_imports import *-from triangle_of_power.triangle import TOP, OPERATION_COLORS+from old_projects.triangle_of_power.triangle import TOP, OPERATION_COLORSclass DontLearnFromSymbols(Scene):def construct(self):diff --git a/old_projects/triples.py b/old_projects/triples.pyindex a5b81c028..6206a351f 100644--- a/old_projects/triples.py+++ b/old_projects/triples.py@@ -1741,7 +1741,7 @@ class VisualizeZSquared(Scene):def show_triangles(self):z_list = [complex(u, v)**2- for u, v in (2, 1), (3, 2), (4, 1)+ for u, v in [(2, 1), (3, 2), (4, 1)]]triangles = self.get_triangles(z_list)triangle = triangles[0]diff --git a/old_projects/wallis.py b/old_projects/wallis.pyindex a87c0612d..768aece70 100644--- a/old_projects/wallis.py+++ b/old_projects/wallis.py@@ -3483,7 +3483,7 @@ class KeeperAndSailor(DistanceProductScene, PiCreatureScene):anims += [MoveToTarget(part)for pi in self.observers- for part in pi, pi.dot, pi.title+ for part in [pi, pi.dot, pi.title]]anims += added_anims@@ -4908,7 +4908,7 @@ class KeeperAndSailorForSineProduct(KeeperAndSailor):FadeOut(product_lines),*[ReplacementTransform(product[i], one_minus_f_over_k[j])- for i, j in (3, 1), (4, 2), (5, 3), (2, 4), (1, 5)+ for i, j in [(3, 1), (4, 2), (5, 3), (2, 4), (1, 5)]])self.wait()diff --git a/old_projects/waves.py b/old_projects/waves.pyindex b3c9ee516..405c7b5fe 100644--- a/old_projects/waves.py+++ b/old_projects/waves.py@@ -1777,7 +1777,7 @@ class ShowTipToTailSum(ShowVectorEquation):np.array(ov.A_vect)))- for ov, A in (h_ov, h_A), (v_ov, v_A)+ for ov, A in [(h_ov, h_A), (v_ov, v_A)]]))self.wait(4)@@ -1917,7 +1917,7 @@ class AlternateBasis(ShowTipToTailSum):"(\\dots)","|\\!\\%sarrow\\rangle"%s2,)- for s1, s2 in ("right", "up"), ("ne", "nw")+ for s1, s2 in [("right", "up"), ("ne", "nw")]]for superposition in superpositions:superposition.set_color_by_tex("rangle", YELLOW)@@ -2519,7 +2519,7 @@ class DescribePhoton(ThreeDScene):color = color,normal_vector = RIGHT,)- for color, direction in (self.x_color, UP), (self.y_color, OUT)+ for color, direction in [(self.x_color, UP), (self.y_color, OUT)]]v_arrow.move_to(h_arrow.get_end(), IN)h_part = VGroup(*self.equation[1][2:4]).copy()@@ -3905,7 +3905,7 @@ class CompareWaveEquations(TeacherStudentsScene):radius = 0.05,color = color)- for x, color in (-0.5, RED), (0.5, GREEN)+ for x, color in [(-0.5, RED), (0.5, GREEN)]]new_alpha.target.next_to(alpha_dot, UP+LEFT, 0.5*SMALL_BUFF)new_alpha.target.set_color(RED)diff --git a/old_projects/wcat.py b/old_projects/wcat.pyindex fda29ef00..638745e22 100644--- a/old_projects/wcat.py+++ b/old_projects/wcat.py@@ -526,7 +526,7 @@ class DefineInscribedSquareProblem(ClosedLoopScene):dot_pairs = [VGroup(self.dots[i], self.dots[j])- for i, j in (0, 2), (1, 3)+ for i, j in [(0, 2), (1, 3)]]pair_colors = MAROON_B, PURPLE_Bdiag_lines = [@@ -549,7 +549,7 @@ class RectangleProperties(Scene):])dot_pairs = [VGroup(vertex_dots[i], vertex_dots[j])- for i, j in (0, 2), (1, 3)+ for i, j in [(0, 2), (1, 3)]]colors = [MAROON_B, PURPLE_B]diag_lines = [@@ -615,7 +615,7 @@ class PairOfPairBecomeRectangle(Scene):dots[j].get_center(),color = dots[i].get_color())- for i, j in (0, 1), (2, 3)+ for i, j in [(0, 1), (2, 3)]]groups = [VGroup(dots[0], dots[1], labels[0], labels[1], lines[0]),