Ë
    óÍ:j%  ã                   ó`   — d dl mZmZ d dlmZmZ ddgZe G d„ de«      «       Z ede¬«      Zy)é    )ÚAnyÚTypeVar)ÚProtocolÚruntime_checkableÚStatefulÚ	StatefulTc                   ó@   — e Zd ZdZdeeef   fd„Zdeeef   ddfd„Zy)r   zN
    Stateful protocol for objects that can be checkpointed and restored.
    Úreturnc                  ó   — y)a±  
        Objects should return their state_dict representation as a dictionary.
        The output of this function will be checkpointed, and later restored in
        `load_state_dict()`.

        .. warning::
            Because of the inplace nature of restoring a checkpoint, this function
            is also called during `torch.distributed.checkpoint.load`.


        Returns:
            Dict: The objects state dict
        N© )Úselfs    úz/home/mcse/projects/srt_converter/srt-converter-venv/lib/python3.12/site-packages/torch/distributed/checkpoint/stateful.pyÚ
state_dictzStateful.state_dict   s   € ð 	ó    r   Nc                  ó   — y)z�
        Restore the object's state from the provided state_dict.

        Args:
            state_dict: The state dict to restore from
        Nr   )r   r   s     r   Úload_state_dictzStateful.load_state_dict   s   € ð 	r   )	Ú__name__Ú
__module__Ú__qualname__Ú__doc__ÚdictÚstrr   r   r   r   r   r   r   r      s6   „ ñð˜D  c ™Nó ð"¨$¨s°C¨x©.ð ¸Tô r   )ÚboundN)	Útypingr   r   Útyping_extensionsr   r   Ú__all__r   r   r   r   r   ú<module>r      sA   ðß ß 9ð �{Ð
#€ð ôˆxó ó ðñB �K xÔ0�	r   