§
    ù²Åj7  ã                   óü  — d dl Z d dlZd dlmZ d dlZddlmZ d dlmZm	Z	m
Z
mZmZmZmZ 	 ddlmZ n# e$ r Y nw xY wes¦e j                             e j                             e¦  «        ¦  «        e j                             e j                              e j        ¦   «         ¦  «        d¦  «        k    r2dZ ej        e                      e j        ¦   «         ¦  «        ¦  «         d	ad
ad„ Zd„ Zd„ Zd„ Z d„ Z!d„ Z"dS )é    N)ÚModuleé   )Ú_HAS_OPS)Ú_meta_registrationsÚdatasetsÚioÚmodelsÚopsÚ
transformsÚutils)Ú__version__ÚtorchvisionzÁYou are importing torchvision within its own root folder ({}). This is not expected to work and may give errors. Please exit the torchvision project source and relaunch your python interpreter.ÚPILÚpyavc                 ó8   — | dvrt          d| › d�¦  «        ‚| adS )a*  
    Specifies the package used to load images.

    Args:
        backend (string): Name of the image backend. one of {'PIL', 'accimage'}.
            The :mod:`accimage` package uses the Intel IPP library. It is
            generally faster than PIL, but does not support as many operations.
    )r   ÚaccimagezInvalid backend 'z#'. Options are 'PIL' and 'accimage'N)Ú
ValueErrorÚ_image_backend)Úbackends    úEC:\Projects\Historical\venv\Lib\site-packages\torchvision/__init__.pyÚset_image_backendr   "   s3   € ð Ð)Ð)Ð)ÝÐY¨WÐYÐYÐYÑZÔZÐZØ€N€N€Nó    c                  ó   — t           S )z:
    Gets the name of the package used to load images
    )r   © r   r   Úget_image_backendr   1   s
   € õ Ðr   c                 óÂ   — | dvrt          d| z  ¦  «        ‚| dk    rt          j        sd}t          |¦  «        ‚| dk    rt          j        sd}t          |¦  «        ‚| adS )aÓ  
    Specifies the package used to decode videos.

    Args:
        backend (string): Name of the video backend. one of {'pyav', 'video_reader'}.
            The :mod:`pyav` package uses the 3rd party PyAv library. It is a Pythonic
            binding for the FFmpeg libraries.
            The :mod:`video_reader` package includes a native C++ implementation on
            top of FFMPEG libraries, and a python API of TorchScript custom operator.
            It generally decodes faster than :mod:`pyav`, but is perhaps less robust.

    .. note::
        Building with FFMPEG is disabled by default in the latest `main`. If you want to use the 'video_reader'
        backend, please compile torchvision from source.
    )r   Úvideo_readerÚcudazIInvalid video backend '%s'. Options are 'pyav', 'video_reader' and 'cuda'r   zavideo_reader video backend is not available. Please compile torchvision from source and try againr   z$cuda video backend is not available.N)r   r   Ú_HAS_CPU_VIDEO_DECODERÚRuntimeErrorÚ_HAS_GPU_VIDEO_DECODERÚ_video_backend)r   Úmessages     r   Úset_video_backendr$   8   sz   € ð" Ð6Ð6Ð6ÝÐdÐgnÑnÑoÔoÐoØ�.Ò Ð ­Ô)BÐ àuˆÝ˜7Ñ#Ô#Ð#Ø	�FÒ	Ð	¥2Ô#<Ð	à8ˆÝ˜7Ñ#Ô#Ð#à ˆˆˆr   c                  ó   — t           S )z¢
    Returns the currently active video backend used to decode videos.

    Returns:
        str: Name of the video backend. one of {'pyav', 'video_reader'}.
    )r"   r   r   r   Úget_video_backendr&   W   s
   € õ Ðr   c                  ó>   — t           j                             ¦   «         S ©N)ÚtorchÚ_CÚ_get_tracing_stater   r   r   Ú_is_tracingr,   b   s   € ÝŒ8×&Ò&Ñ(Ô(Ð(r   c                  ó   — d S r(   r   r   r   r   Údisable_beta_transforms_warningr.   f   s	   € ð 	€Dr   )#ÚosÚwarningsÚmodulefinderr   r)   Ú	extensionr   r   r   r   r   r	   r
   r   r   Úversionr   ÚImportErrorÚpathÚdirnameÚrealpathÚ__file__ÚjoinÚgetcwdr#   ÚwarnÚformatr   r"   r   r   r$   r&   r,   r.   r   r   r   ú<module>r=      s¼  ðØ 	€	€	€	Ø €€€Ø Ð Ð Ð Ð Ð à €€€ð  Ð Ð Ð Ð Ð Ø YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ YÐ Yð	Ø$Ð$Ð$Ð$Ð$Ð$Ð$øØð 	ð 	ð 	Ø€Dð	øøøð
 ð /�B”G—O’O B¤G×$4Ò$4°XÑ$>Ô$>Ñ?Ô?À2Ä7Ç<Â<Ø„G×Ò�Y�R”Y‘[”[Ñ!Ô! =ñDô Dò ð ð	Kð ð
 €H„M�'—.’.  ¤¡¤Ñ-Ô-Ñ.Ô.Ð.à€à€ðð ð ðð ð ð!ð !ð !ð>ð ð ð)ð )ð )ð	ð 	ð 	ð 	ð 	s   ¬3 ³;º;