+
    –°³jÈ  ã                   ó®   a € R t0 t ^ RIHt ^ RIHt ^ RIHt ^ RIHu H	u H
t ^ RIHu H	u Ht ^ RIHtHt ^ RIHtHtHtHt . t] ^ k  ! R R4      tR# )	é    )ÚFuture)ÚAnyN)ÚMetadataÚSTATE_DICT_TYPE)ÚLoadPlannerÚSavePlannerÚStorageReaderÚStorageWriterc            
       ó„   a € ] tR t^t o RtRRR^ RRRRRR/V 3R	 lR
 lltV 3R lR ltV 3R lR ltV 3R lR ltRt	V t
R# )Ú_CheckpointeraÍ  This base class specifies a high level API for saving and loading
distributed `state_dict` 's. It provides an abstraction over the low-level APIs
provided by :py:mod:`torch.distributed.checkpoint.storage`, essentially calling
:py:meth: `torch.distributed.state_dict_saver.save` and
:py:meth: `torch.distributed.state_dict_loader.load` with the provided storage
readers and writers.

.. warning::
    This feature is experimental and subject to removal/change.

Úprocess_groupNÚcoordinator_rankÚno_distFÚload_plannerÚsave_plannerc                ó‚   <€ V ^8„  d   QhRS[ RS[RS[P                  R,          RS[RS[RS[R,          RS[R,          /# )	é   Ústorage_writerÚstorage_readerr   Nr   r   r   r   )r
   r	   ÚdistÚProcessGroupÚintÚboolr   r   )ÚformatÚ__classdict__s   "€Úk/home/luca/screen-checking/.venv/lib/python3.14/site-packages/torch/distributed/checkpoint/_checkpointer.pyÚ__annotate__Ú_Checkpointer.__annotate__    sf   ø€ ÷ )ñ )á%ð)ñ &ð)ñ
 ×(Ñ(¨4Õ/ð)ñ ð)ñ ð)ñ " DÕ(ð)ñ " DÕ(ñ)ó    c               óZ   € Wn         W n        W0n        W@n        WPn        W`n        Wpn        R# )a4  Initializes the Checkpointer instance.

Args:
    storage_writer: Instance of StorageWrite used to perform writes.
    storage_reader: StorageReader used to load data from.
    process_group: ProcessGroup to be used for cross-rank synchronization.
    coordinator_rank: Rank to use to coordinate the checkpoint. rank0 is used by default.
    no_dist: If ``True``, distributed checkpoint will not load in SPMD style. (Default: ``False``)
    loader_planner: Instance of LoadPlanner to use when loading.
    save_planner: Instance of SavePlanner to use when saving.
N)r   r   r   r   r   r   r   )Úselfr   r   r   r   r   r   r   s   &&&$$$$$r   Ú__init__Ú_Checkpointer.__init__    s-   € ð, -ÔØ,ÔØ*ÔØ 0ÔØŒØ(ÔØ(Ör   c                ó&   <€ V ^8„  d   QhRS[ RS[/# ©r   Ú
state_dictÚreturn)r   r   )r   r   s   "€r   r   r   >   s   ø€ ÷ 
ñ 
á#ð
ñ 
ñ
r   c           	     óž   € \         P                  ! VV P                  V P                  V P                  V P
                  V P                  R7      # )ziCalls :py:meth: `torch.distributed.state_dict_saver.save`. Utilizing values passed during initialization.)r   r   r   Úplanner)ÚsaverÚsaver   r   r   r   r   ©r!   r&   s   &&r   r+   Ú_Checkpointer.save>   sC   € ô
 �zŠzØØ×ÑØ×,Ñ,Ø!×2Ñ2Ø—L‘LØ×%Ñ%ô
ð 	
r   c                ó&   <€ V ^8„  d   QhRS[ RS[/# r%   )r   r   )r   r   s   "€r   r   r   L   s   ø€ ÷ ñ á#ðñ 
ñr   c                ó¸   € \         P                  ! VV P                  V P                  V P                  R7      p\        V\        4      '       g   \        R4      hV# )zÄ
Calls :py:meth: `torch.distributed.state_dict_saver._async_save`. Utilizing values passed during initialization.

Returns:
    Future: A future holding the resultant Metadata object from `save`.
)r   r   r)   z$response should be a Future instance)r*   Ú
async_saver   r   r   Ú
isinstancer   ÚAssertionError)r!   r&   Úresponses   && r   r0   Ú_Checkpointer.async_saveL   sR   € ô ×#Ò#ØØ×.Ñ.Ø×,Ñ,Ø×%Ñ%ô	
ˆô ˜(¤F×+Ò+Ü Ð!GÓHÐHØˆr   c                ó:   <€ V ^8„  d   QhRS[ S[S[3,          RR/# )r   r&   r'   N)ÚdictÚstrr   )r   r   s   "€r   r   r   `   s#   ø€ ÷ 
ñ 
™t¡C© H�~ð 
°$ñ 
r   c                óv   € \         P                  ! VV P                  V P                  V P                  R7       R# )zjCalls :py:meth: `torch.distributed.state_dict_loader.load`. Utilizing values passed during initialization.)r   r   r)   N)ÚloaderÚloadr   r   r   r,   s   &&r   r:   Ú_Checkpointer.load`   s,   € ä�ŠØØ×.Ñ.Ø×,Ñ,Ø×%Ñ%÷		
r   )r   r   r   r   r   r   r   )Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r"   r+   r0   r:   Ú__static_attributes__Ú__classdictcell__)r   s   @r   r   r      sd   ø‡ € ñ
ð)ð
 37ð)ð !"ð)ð ð)ð ,0ð)ð ,0÷)ò )÷<
ð 
÷ð ÷(
ö 
r   r   c                óV   € V ^8„  d   Qh/ ^ \         9   d   \        \        ,          ;R&   # )r   Ú__all__)Ú__conditional_annotations__Úlistr7   )r   s   "r   r   r      s   € × %Ñ %÷ Ò ŒŒc�Ñ ò &r   )rE   Úconcurrent.futuresr   Útypingr   Útorch.distributedÚdistributedr   Ú.torch.distributed.checkpoint.state_dict_loaderÚ
checkpointÚstate_dict_loaderr9   Ú-torch.distributed.checkpoint.state_dict_saverÚstate_dict_saverr*   Ú%torch.distributed.checkpoint.metadatar   r   Ú$torch.distributed.checkpoint.storager   r   r	   r
   rD   r   r   )rE   s   @r   Ú<module>rR      sA   øðß %Ò %Ý å  ß ?Ó ?ß =Ó =ß K÷ó ð €Ó ÷T
ó T
r   