

from manim import *


class  A						(							_UpperCAmelCase ):







    """simple docstring"""





    def 						snake_case__     (      self :       Any		)->    Optional[int]:





        '''simple docstring'''







        A__          =   Rectangle(height=0.5,width=0.5		)
        A__          =   Rectangle(height=0.25,width=0.25		)
        A__          =   Rectangle(height=0.46,width=0.46		).set_stroke(width=0		)

        A__          =   [mem.copy() for i in range(6		)]
        A__          =   [mem.copy() for i in range(6		)]
        A__          =   VGroup(*lowercase_		).arrange(lowercase_,buff=0		)
        A__          =   VGroup(*lowercase_		).arrange(lowercase_,buff=0		)
        A__          =   VGroup(lowercase_,lowercase_		).arrange(lowercase_,buff=0		)
        A__          =   Text('CPU',font_size=2_4		)
        A__          =   Group(lowercase_,lowercase_		).arrange(lowercase_,buff=0.5,aligned_edge=lowercase_		)
        cpu.move_to([-2.5, -0.5, 0]		)
        self.add(lowercase_		)

        A__          =   [mem.copy() for i in range(4		)]
        A__          =   VGroup(*lowercase_		).arrange(lowercase_,buff=0		)
        A__          =   Text('GPU',font_size=2_4		)
        A__          =   Group(lowercase_,lowercase_		).arrange(lowercase_,buff=0.5,aligned_edge=lowercase_		)
        gpu.move_to([-1, -1, 0]		)
        self.add(lowercase_		)

        A__          =   [mem.copy() for i in range(6		)]
        A__          =   VGroup(*lowercase_		).arrange(lowercase_,buff=0		)

        A__          =   Text('Model',font_size=2_4		)
        A__          =   Group(lowercase_,lowercase_		).arrange(lowercase_,buff=0.5,aligned_edge=lowercase_		)
        model.move_to([3, -1.0, 0]		)
        self.add(lowercase_		)

        A__          =   []
        A__          =   []
        A__          =   []

        for i, rect in enumerate(lowercase_		):
            rect.set_stroke(lowercase_		)

            A__          =   Rectangle(height=0.46 / 4,width=0.46 / 3		).set_stroke(width=0.0		).set_fill(lowercase_,opacity=0.7		)

            if i == 0:
                cpu_target.next_to(cpu_left_col_base[0].get_corner(DOWN + LEFT		),buff=0.02,direction=lowercase_		)
                cpu_target.set_x(cpu_target.get_x() + 0.1		)
            elif i == 3:
                cpu_target.next_to(model_cpu_arr[0],direction=lowercase_,buff=0.0		)
            else:
                cpu_target.next_to(model_cpu_arr[i - 1],direction=lowercase_,buff=0.0		)
            self.add(lowercase_		)
            model_cpu_arr.append(lowercase_		)

        self.add(*lowercase_,*lowercase_,*lowercase_		)

        A__          =   [mem.copy() for i in range(6		)]
        A__          =   VGroup(*lowercase_		).arrange(lowercase_,buff=0		)

        A__          =   Text('Loaded Checkpoint',font_size=2_4		)
        A__          =   Group(lowercase_,lowercase_		).arrange(lowercase_,buff=0.5,aligned_edge=lowercase_		)
        checkpoint.move_to([3, 0.5, 0]		)

        self.add(lowercase_		)

        A__          =   []
        A__          =   []

        for i, rect in enumerate(lowercase_		):
            A__          =   fill.copy().set_fill(lowercase_,opacity=0.7		)
            target.move_to(lowercase_		)
            ckpt_arr.append(lowercase_		)

            A__          =   target.copy()
            if i < 5:
                cpu_target.move_to(cpu_left_col_base[i + 1]		)
            else:
                cpu_target.move_to(cpu_right_col_base[i - 5]		)
            ckpt_cpu_arr.append(lowercase_		)
        self.add(*lowercase_,*lowercase_		)

        A__          =   Square(side_length=2.2		)
        key.move_to([-5, 2, 0]		)

        A__          =   MarkupText(
            F'<b>Key:</b>\n\n<span fgcolor=\'{YELLOW}\'>●</span> Empty Model',font_size=1_8,)

        key_text.move_to([-5, 2.4, 0]		)

        self.add(lowercase_,lowercase_		)

        A__          =   MarkupText(
            F'<span fgcolor=\'{BLUE}\'>●</span> Checkpoint',font_size=1_8,)

        blue_text.next_to(lowercase_,DOWN * 2.4,aligned_edge=key_text.get_left()		)
        self.add(lowercase_		)

        A__          =   MarkupText(
            F'Based on the passed in configuration, weights are stored in\na variety of np.memmaps on disk or to a particular device.',font_size=2_4,)
        step_a.move_to([2, 2, 0]		)

        A__          =   [meta_mem.copy() for i in range(6		)]
        A__          =   [meta_mem.copy() for i in range(6		)]
        A__          =   VGroup(*lowercase_		).arrange(lowercase_,buff=0		)
        A__          =   VGroup(*lowercase_		).arrange(lowercase_,buff=0		)
        A__          =   VGroup(lowercase_,lowercase_		).arrange(lowercase_,buff=0		)
        A__          =   Text('Disk',font_size=2_4		)
        A__          =   Group(lowercase_,lowercase_		).arrange(lowercase_,buff=0.5,aligned_edge=lowercase_		)
        disk.move_to([-4.0, -1.25, 0]		)
        self.play(Write(lowercase_,run_time=3		),Write(lowercase_,run_time=1		),Create(lowercase_,run_time=1		)		)

        A__          =   []
        for i, rect in enumerate(lowercase_		):
            A__          =   rect.copy()
            target.generate_target()
            target.target.move_to(disk_left_col_base[i]		).scale(0.5		)
            animations.append(MoveToTarget(lowercase_,run_time=1.5		)		)
        self.play(*lowercase_		)

        self.play(FadeOut(lowercase_		)		)

        A__          =   MarkupText(F'Then, the checkpoint is removed from memory\nthrough garbage collection.',font_size=2_4		)
        step_a.move_to([2, 2, 0]		)

        self.play(Write(lowercase_,run_time=3		)		)

        self.play(
            FadeOut(lowercase_,lowercase_,*lowercase_,*lowercase_		),)

        self.wait()





UpperCAmelCase_      : Optional[int]  					=       [4, 1, 7, 4, 2, 6, 4, 1, 5, 3, 7, 5]
UpperCAmelCase_      : str  					=       [3, 7, 7, 4, 2, 6, 4, 1, 5, 3, 7, 5]
UpperCAmelCase_      : str  					=       {
    0: 'Sunday',
    1: 'Monday',
    2: 'Tuesday',
    3: 'Wednesday',
    4: 'Thursday',
    5: 'Friday',
    6: 'Saturday',
}







def        SCREAMING_SNAKE_CASE_						(			__A :			int  ,    __A :			int  ,    __A :			int				)	->		str:

       """simple docstring"""

       assert len(str(__A				)				) > 2, "year should be in YYYY format"
       assert 1 <= month <= 12, "month should be between 1 to 12"
       assert 1 <= day <= 31, "day should be between 1 to 31"

       # Doomsday algorithm:
       a_					:		List[str]							=  year // 1_00
       a_					:		Optional[int]							=  (5 * (century % 4) + 2) % 7
       a_					:		List[str]							=  year % 1_00
       a_					:		str							=  centurian % 12
       a_					:		List[str]							=  (
           (centurian // 12) + centurian_m + (centurian_m // 4) + century_anchor
       ) % 7
       a_					:		Any							=  (
           DOOMSDAY_NOT_LEAP[month - 1]
           if (year % 4 != 0) or (centurian == 0 and (year % 4_00) == 0)
           else DOOMSDAY_LEAP[month - 1]
       )
       a_					:		Any							=  (dooms_day + day - day_anchor) % 7
       return WEEK_DAY_NAMES[week_day]


if __name__ == "__main__":
   import doctest

   doctest.testmod()


