+
    &j                     |  a  R t0 t ^ RIt^ RIt^ RIHt ^ RIt^ RIHt . ROt] ^ k R R lt	]
! ]P                  R4      '       Eg`   ]
! ]P                  R4      '       d	   ]! R	4      h]
! ]P                  R
4      '       d	   ]! R4      h]
! ]P                  R4      '       d	   ]! R4      h]
! ]P                  R4      '       d	   ]! R4      h]
! ]P                  R4      '       d	   ]! R4      h]	! R4      ]P                  P                  R&   ]	! R4      ]P                  P                  R&   ]	! R
4      ]P                  P                  R
&   ]	! R4      ]P                  P                  R&   ]	! R4      ]P                  P                  R&   ]	! R4      ]P                  P                  R&   R R ltR R lt ! R R4      tR# )    N)CallableStorageGdsFilec                0    V ^8  d   QhR\         R\        /# )   namereturn)strr   )formats   "f/Users/jameslopez/projects/CWCArchive/cwc-podcast/.venv/lib/python3.14/site-packages/torch/cuda/gds.py__annotate__r      s      C H     c                    a  V 3R  lpV# )c                  "   < \        R S R24      h)z	torch._C.z" is not supported on this platform)RuntimeError)argskwargsr	   s   *,r   fn_dummy_fn.<locals>.fn   s    Ytf,NOPPr    )r	   r   s   f r   	_dummy_fnr      s    Q Ir   _gds_register_buffer_gds_deregister_bufferz?_gds_deregister_buffer exists but _gds_register_buffer does not_gds_register_handlez=_gds_register_handle exists but _gds_register_buffer does not_gds_deregister_handlez?_gds_deregister_handle exists but _gds_register_buffer does not_gds_load_storagez:_gds_load_storage exists but _gds_register_buffer does not_gds_save_storagez:_gds_save_storage exists but _gds_register_buffer does notc                (    V ^8  d   QhR\         RR/# r   sr
   Nr   )r   s   "r   r   r   5   s     % %7 %t %r   c                D    \         P                  P                  V 4       R# )a  Registers a storage on a CUDA device as a cufile buffer.

Example::

    >>> # xdoctest: +SKIP("gds filesystem requirements")
    >>> src = torch.randn(1024, device="cuda")
    >>> s = src.untyped_storage()
    >>> gds_register_buffer(s)

Args:
    s (Storage): Buffer to register.
N)torch_Cr   r!   s   &r   gds_register_bufferr&   5   s     
HH!!!$r   c                (    V ^8  d   QhR\         RR/# r    r   )r   s   "r   r   r   E   s     ' 'W ' 'r   c                D    \         P                  P                  V 4       R# )aS  Deregisters a previously registered storage on a CUDA device as a cufile buffer.

Example::

    >>> # xdoctest: +SKIP("gds filesystem requirements")
    >>> src = torch.randn(1024, device="cuda")
    >>> s = src.untyped_storage()
    >>> gds_register_buffer(s)
    >>> gds_deregister_buffer(s)

Args:
    s (Storage): Buffer to register.
N)r#   r$   r   r%   s   &r   gds_deregister_bufferr)   E   s     
HH##A&r   c                      a  ] tR t^Vt o RtV 3R lR ltV 3R lR ltV 3R lR ltV 3R lR	 ltRV 3R
 lR llt	RV 3R lR llt
RtV tR# )r   a7  Wrapper around cuFile.

cuFile is a file-like interface to the GPUDirect Storage (GDS) API.

See the `cufile docs <https://docs.nvidia.com/gpudirect-storage/api-reference-guide/index.html#cufile-io-api>`_
for more details.

Args:
    filename (str): Name of the file to open.
    flags (int): Flags to pass to ``os.open`` when opening the file. ``os.O_DIRECT`` will
        be added automatically.

Example::

    >>> # xdoctest: +SKIP("gds filesystem requirements")
    >>> src1 = torch.randn(1024, device="cuda")
    >>> src2 = torch.randn(2, 1024, device="cuda")
    >>> file = torch.cuda.gds.GdsFile(f, os.O_CREAT | os.O_RDWR)
    >>> file.save_storage(src1.untyped_storage(), offset=0)
    >>> file.save_storage(src2.untyped_storage(), offset=src1.nbytes)
    >>> dest1 = torch.empty(1024, device="cuda")
    >>> dest2 = torch.empty(2, 1024, device="cuda")
    >>> file.load_storage(dest1.untyped_storage(), offset=0)
    >>> file.load_storage(dest2.untyped_storage(), offset=src1.nbytes)
    >>> torch.equal(src1, dest1)
    True
    >>> torch.equal(src2, dest2)
    True

c                &   < V ^8  d   QhRS[ RS[/# )r   filenameflags)r   int)r   __classdict__s   "r   r   GdsFile.__annotate__v   s       S r   c                    \         P                  R 8X  d   \        R4      hWn        W n        \
        P                  ! W\
        P                  ,          4      V n        RV n	        V P                  4        R# )win32z*GdsFile is not supported on this platform.N)sysplatformr   r,   r-   osopenO_DIRECTfdhandleregister_handle)selfr,   r-   s   &&&r   __init__GdsFile.__init__v   sP    <<7"KLL 
''(BKK$78"&r   c                   < V ^8  d   QhRR/# r   r
   Nr   )r   r/   s   "r   r   r0      s       r   c                    V P                   e   V P                  4        \        P                  ! V P                  4       R # )N)r9   deregister_handler5   closer8   r;   s   &r   __del__GdsFile.__del__   s(    ;;"""$
r   c                   < V ^8  d   QhRR/# r?   r   )r   r/   s   "r   r   r0      s     = = =r   c                    V P                   e   \        R4      h\        P                  P	                  V P
                  4      V n         R# )z`Registers file descriptor to cuFile Driver.

This is a wrapper around ``cuFileHandleRegister``.
Nz4Cannot register a handle that is already registered.)r9   AssertionErrorr#   r$   r   r8   rC   s   &r   r:   GdsFile.register_handle   s4    
 ;;" !WXXhh33DGG<r   c                   < V ^8  d   QhRR/# r?   r   )r   r/   s   "r   r   r0      s      4 r   c                    V P                   f   \        R4      h\        P                  P	                  V P                   4       RV n         R# )zfDeregisters file descriptor from cuFile Driver.

This is a wrapper around ``cuFileHandleDeregister``.
Nz2Cannot deregister a handle that is not registered.)r9   rH   r#   r$   r   rC   s   &r   rA   GdsFile.deregister_handle   s7    
 ;; !UVV''4r   c                *   < V ^8  d   QhRS[ RS[RR/# r   storageoffsetr
   Nr   r.   )r   r/   s   "r   r   r0      '     A AG AS A Ar   c                    V P                   f   \        R4      h\        P                  P	                  V P                   W4       R# )a=  Loads data from the file into the storage.

This is a wrapper around ``cuFileRead``. ``storage.nbytes()`` of data
will be loaded from the file at ``offset`` into the storage.

Args:
    storage (Storage): Storage to load data into.
    offset (int, optional): Offset into the file to start loading from. (Default: 0)
Nz4Cannot load data from a file that is not registered.)r9   rH   r#   r$   r   r;   rO   rP   s   &&&r   load_storageGdsFile.load_storage   s2     ;; !WXX""4;;@r   c                *   < V ^8  d   QhRS[ RS[RR/# rN   rQ   )r   r/   s   "r   r   r0      rR   r   c                    V P                   f   \        R4      h\        P                  P	                  V P                   W4       R# )a%  Saves data from the storage into the file.

This is a wrapper around ``cuFileWrite``. All bytes of the storage
will be written to the file at ``offset``.

Args:
    storage (Storage): Storage to save data from.
    offset (int, optional): Offset into the file to start saving to. (Default: 0)
Nz2Cannot save data to a file that is not registered.)r9   rH   r#   r$   r   rT   s   &&&r   save_storageGdsFile.save_storage   s2     ;; !UVV""4;;@r   )r8   r,   r-   r9   N)r   )__name__
__module____qualname____firstlineno____doc__r<   rD   r:   rA   rU   rY   __static_attributes____classdictcell__)r/   s   @r   r   r   V   sP     >  
= = A AA A Ar   c                V    V ^8  d   Qh/ ^ \         9   d   \        \        ,          ;R&   # )r   __all__)__conditional_annotations__listr   )r   s   "r   r   r      s     		 c  
r   )r&   r)   r   )rd   r5   r3   collections.abcr   r#   torch.typesr   rc   r   hasattrr$   rH   __dict__r&   r)   r   r   )rd   s   @r   <module>rj      s   		 
 $    uxx/00uxx122M
 	
 uxx/00K
 	
 uxx122M
 	
 uxx,--H
 	
 uxx,--H
 	
 1::P0QEHH,-2;<T2UEHH./09:P0QEHH,-2;<T2UEHH./-67J-KEHH)*-67J-KEHH)*% '"[A [Ar   