+
    õäûj­)  ã                   óZ  € R t ^ RIHtHt ^ RIHtHtHtHt ^ RI	t	. ROt
]	P                  ! R	4      t]! R
]R7      t]]]]3,          t ! R R]4      t ! R R]]4      tR R ltR R lt ! R R]]R7      t ! R R]]R7      t ! R R]]R7      t ! R R]]R7      t ! R R]]R7      tR# )a›  Name the interpolation, padding, border, dtype and data-kind options of the augmentations, as enums or strings.

Each enum's ``get`` classmethod takes a member, its name in any case or its integer value and returns the member, so
an argument typed ``TKEnum`` (``str | int | Enum``) accepts all three. A name that names no member raises an error that
is both a ``KeyError`` and a ``ValueError``, an integer that is no member's value a ``ValueError``, and another type a
``TypeError``. ``"bilinear" in Resample`` tests a name case-insensitively, and ``1 in Resample`` a value.

Which class to use:

- The interpolation of a resampling augmentation (``resample``): :class:`Resample`.
- How a warping augmentation fills pixels that map outside the input (``padding_mode``): :class:`SamplePadding`.
- The border mode of a blur augmentation (``border_type``): :class:`BorderType`.
- The kind of each input of an augmentation container (``data_keys``): :class:`DataKey`.
- A tensor dtype as an integer code: :class:`DType`.
- The ``str | int | Enum`` type of the arguments that ``get`` reads: ``TKEnum``.
- :math:`\pi` as a 0-d tensor of the default dtype and device at import: ``pi``.
)ÚEnumÚEnumMeta)ÚIteratorÚTypeÚTypeVarÚUnionNÚ
BorderTypeÚDTypeÚDataKeyÚResampleÚSamplePaddingg-DTû!	@Ú_T)Úboundc                   óf   a a€ ] tR t^2t oRtV3R lV 3R lltV3R lR ltV3R lR ltRtVt	V ;t
# )	Ú_KORNIA_EnumMetazECustom metaclass for enums to support string and integer comparisons.c                ó0   <€ V ^8„  d   QhRS[ S[,          /# ©é   Úreturn)r   r   )ÚformatÚ__classdict__s   "€ÚLC:\Ai_Coding\apps\studio\ComfyUI\.venv\Lib\site-packages\kornia\constants.pyÚ__annotate__Ú_KORNIA_EnumMeta.__annotate__5   s   ø€ ÷ "ñ "™(¡4�.ñ "ó    c                ó    <€ \         SV `  4       # ©N)ÚsuperÚ__iter__)ÚselfÚ	__class__s   &€r   r   Ú_KORNIA_EnumMeta.__iter__5   s   ø€ Ü‰wÑÓ!Ð!r   c                ó6   <€ V ^8„  d   QhRS[ S[,          RS[/# )r   Úotherr   )ÚTKEnumr   Úbool)r   r   s   "€r   r   r   8   s   ø€ ÷ 1ñ 1¡&©¥,ð 1±4ñ 1r   c                ó¸  a€ \        S\        4      '       d;   \        ;QJ d    V3R  lV  4       F  '       g   K   R# 	  R# ! V3R  lV  4       4      # \        S\        4      '       d;   \        ;QJ d    V3R lV  4       F  '       g   K   R# 	  R# ! V3R lV  4       4      # \        ;QJ d    V3R lV  4       F  '       g   K   R# 	  R# ! V3R lV  4       4      # )c              3   óx   <"  € T F/  qP                   P                  4       SP                  4       8H  x € K1  	  R # 5ir   )ÚnameÚupper©Ú.0Úvalr#   s   & €r   Ú	<genexpr>Ú0_KORNIA_EnumMeta.__contains__.<locals>.<genexpr>:   s%   øé € ÐIÁD¸S—x‘x—~‘~Ó'¨5¯;©;«=Ö8ÃDùs   ƒ7:TFc              3   ó@   <"  € T F  qP                   S8H  x € K  	  R # 5ir   ©Úvaluer*   s   & €r   r-   r.   =   s   øé € Ð:±T¨c—y‘y EÖ)³Tùs   ƒc              3   ó,   <"  € T F	  qS8H  x € K  	  R # 5ir   © r*   s   & €r   r-   r.   ?   s   øé € Ð0©4 C˜%–<«4ùs   ƒ)Ú
isinstanceÚstrÚanyÚint)r   r#   s   &fr   Ú__contains__Ú_KORNIA_EnumMeta.__contains__8   s˜   ø€ Ü�eœS×!Ò!ß“3ÔIÁDÓI—3”3ÐI’3ÐI�3ÔIÁDÓIÓIÐIä�eœS×!Ò!ß“3Ô:±TÓ:—3”3Ð:’3Ð:�3Ô:±TÓ:Ó:Ð:ç‹sÔ0©4Ó0�sŒsÐ0ŠsÐ0ˆsÔ0©4Ó0Ó0Ð0r   c                ó    <€ V ^8„  d   QhRS[ /# r   ©r5   )r   r   s   "€r   r   r   A   s   ø€ ÷ Iñ I™#ñ Ir   c                ó:   a € R P                  V 3R lS  4       4      # )z | c              3   óZ   <"  € T F   pSP                    R VP                   2x € K"  	  R# 5i)Ú.N)Ú__name__r(   )r+   r,   r   s   & €r   r-   Ú,_KORNIA_EnumMeta.__repr__.<locals>.<genexpr>B   s$   øé € ÐHÁ4¸C˜TŸ]™]˜O¨1¨S¯X©X¨JÕ7Ã4ùs   ƒ(+)Újoin©r   s   fr   Ú__repr__Ú_KORNIA_EnumMeta.__repr__A   s   ø€ Ø�z‰zÔHÁ4ÓHÓHÐHr   r3   )r?   Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r8   rC   Ú__static_attributes__Ú__classdictcell__Ú__classcell__)r    r   s   @@r   r   r   2   s.   ù‡ € ÙO÷"ó "÷1ð 1÷I÷ Ið Ir   r   c                   ó6   a € ] tR t^Et o RtV 3R lR ltRtV tR# )Ú_UnknownNameErrora  Raised by the ``.get`` of a kornia enum for a name that names no member.

It is a :exc:`ValueError`, like the error for an integer that is no member's value, and a :exc:`KeyError`, like a
failed ``Enum[name]`` lookup, so either ``except`` clause catches it.
c                ó    <€ V ^8„  d   QhRS[ /# r   r;   )r   r   s   "€r   r   Ú_UnknownNameError.__annotate__L   s   ø€ ÷ 'ñ '™ñ 'r   c                ó,   € \         P                  V 4      # r   )Ú	ExceptionÚ__str__rB   s   &r   rR   Ú_UnknownNameError.__str__L   s   € ä× Ñ  Ó&Ð&r   r3   N)r?   rE   rF   rG   rH   rR   rI   rJ   ©r   s   @r   rM   rM   E   s   ø‡ € ñ÷'ö 'r   rM   c                ó^   € V ^8„  d   QhR\         \        ,          R\        R\        R\        /# )r   Úclsr(   r1   r   )r   r   r5   Úobject)r   s   "r   r   r   Q   s,   € ÷ 	ñ 	”dœ2•hð 	¤cð 	´&ð 	¼Rñ 	r   c           	      óÒ   €  WP                  4       ,          #   \         dD    R P                  R T P                   4       4      p\	        T: RT P
                   RT R24      Rhi ; i)z, c              3   óT   "  € T F  p\        VP                  4       4      x € K   	  R # 5ir   )ÚreprÚlower)r+   Úmember_names   & r   r-   Ú_get_by_name.<locals>.<genexpr>W   s!   é € ÐWÁ¸œ$˜{×0Ñ0Ó2×3Ð3Ãùs   ‚&(z is not a valid z. Expected one of z (case-insensitive).N)r)   ÚKeyErrorrA   Ú__members__rM   r?   )rV   r(   r1   Úvalids   &&& r   Ú_get_by_namera   Q   sj   € ðØ—:‘:“<Õ Ð øÜô Ø—	‘	ÑWÀsÇÂÓWÓWˆÜØ‰iÐ'¨¯© ~Ð5GÈÀwÐNbÐcó
àð	ðús
   ‚ ˜AA&c                óh   € V ^8„  d   QhR\         \        ,          R\        \        ,          R\        /# )r   rV   r1   r   )r   r   r$   )r   s   "r   r   r   ]   s)   € ÷ ñ Œd”2�hð œv¤b�zð ¬bñ r   c                 óÔ  € \        V\        4      '       d   \        WV4      # \        V\        4      '       dA   \	        R V P
                   RV P
                   RV: R\        V4      P
                   R2	4      h\        V\        4      '       d	   V ! V4      # \        W4      '       d   V# \	        R V P
                   RV P
                   RV: R\        V4      P
                   R2	4      h)Ú`z!.get` expects a `str`, `int` or `z` value, not a `bool`. Got ú
 of type `ú`.z` value. Got )r4   r5   ra   r%   Ú	TypeErrorr?   Útyper7   ©rV   r1   s   &&r   Ú_getrj   ]   sÞ   € Ü�%œ×ÒÜ˜C¨Ó.Ð.ä�%œ×ÒÜØ�—‘ˆ~Ð>¸s¿|¹|¸nð MØ‘)˜:¤d¨5£k×&:Ñ&:Ð%;¸2ð?ó
ð 	
ô
 �%œ×ÒÙ�5‹zÐä�%×ÒØˆä
Ø
ˆC�L‰Lˆ>Ð:¸3¿<¹<¸.ð IØ‰i�z¤$ u£+×"6Ñ"6Ð!7°rð	;óð r   c                   óL   a € ] tR t^st o Rt^ t^t^t]V 3R lR l4       t	Rt
V tR# )r   aÁ  Name the interpolation mode of a resampling augmentation: nearest, bilinear or bicubic.

The geometric augmentations read their ``resample`` argument with ``Resample.get``, so
:class:`~kornia.augmentation.RandomAffine` takes ``resample="nearest"`` as well as ``Resample.NEAREST``.

See Also:
    - :class:`SamplePadding`: the ``padding_mode`` of the same warping augmentations.
    - :class:`BorderType`: the border mode of the blur augmentations.

c                ó2   <€ V ^8„  d   QhRS[ R,          RR/# )r   r1   r   r   ©r$   )r   r   s   "€r   r   ÚResample.__annotate__„   s    ø€ ÷  ñ  ™˜zÕ*ð  ¨zñ  r   c                ó   € \        W4      # )z@Return the Resample member matching a name, a value or a member.©rj   ri   s   &&r   ÚgetÚResample.getƒ   ó   € ô �CÓÐr   r3   N)r?   rE   rF   rG   rH   ÚNEARESTÚBILINEARÚBICUBICÚclassmethodrq   rI   rJ   rT   s   @r   r   r   s   s-   ø‡ € ñ	ð €GØ€HØ€Gà÷ ó ö r   )Ú	metaclassc                   óP   a € ] tR t^‰t o Rt^ t^t^t^t]	V 3R lR l4       t
RtV tR# )r   a;  Name the border mode of a blur augmentation: constant, reflect, replicate or circular padding.

The blur augmentations, such as :class:`~kornia.augmentation.RandomGaussianBlur`,
:class:`~kornia.augmentation.RandomBoxBlur` and :class:`~kornia.augmentation.RandomMotionBlur`, read their
``border_type`` argument with ``BorderType.get`` and pass the lower-case name to their filter.

See Also:
    - :class:`SamplePadding`: how a warping augmentation fills pixels that map outside the input.
    - :class:`Resample`: the interpolation mode of the resampling augmentations.

c                ó2   <€ V ^8„  d   QhRS[ R,          RR/# )r   r1   r   r   rm   )r   r   s   "€r   r   ÚBorderType.__annotate__œ   s    ø€ ÷  ñ  ™˜|Õ,ð  °ñ  r   c                ó   € \        W4      # )zBReturn the BorderType member matching a name, a value or a member.rp   ri   s   &&r   rq   ÚBorderType.get›   rs   r   r3   N)r?   rE   rF   rG   rH   ÚCONSTANTÚREFLECTÚ	REPLICATEÚCIRCULARrw   rq   rI   rJ   rT   s   @r   r   r   ‰   s2   ø‡ € ñ
ð €HØ€GØ€IØ€Hà÷ ó ö r   c                   óP   a € ] tR t^¡t o Rt^ t^t^t^t]	V 3R lR l4       t
RtV tR# )r   aÇ  Name how a warping augmentation fills pixels outside the input: zeros, border, reflection or a fill value.

:class:`~kornia.augmentation.RandomAffine`, :class:`~kornia.augmentation.RandomThinPlateSpline` and the shear and
translation augmentations read their ``padding_mode`` argument with ``SamplePadding.get``. ``ZEROS``, ``BORDER`` and
``REFLECTION`` are the padding modes of :func:`torch.nn.functional.grid_sample`; ``FILL`` fills with the
``fill_value`` of an augmentation that takes one, such as :class:`~kornia.augmentation.RandomAffine`.

See Also:
    - :class:`Resample`: the interpolation mode of the same warping augmentations.
    - :class:`BorderType`: the border mode of the blur augmentations.

c                ó2   <€ V ^8„  d   QhRS[ R,          RR/# )r   r1   r   r   rm   )r   r   s   "€r   r   ÚSamplePadding.__annotate__µ   s    ø€ ÷  ñ  ™˜Õ/ð  °Oñ  r   c                ó   € \        W4      # )zEReturn the SamplePadding member matching a name, a value or a member.rp   ri   s   &&r   rq   ÚSamplePadding.get´   rs   r   r3   N)r?   rE   rF   rG   rH   ÚZEROSÚBORDERÚ
REFLECTIONÚFILLrw   rq   rI   rJ   rT   s   @r   r   r   ¡   s2   ø‡ € ñð €EØ€FØ€JØ€Dà÷ ó ö r   c                   óp   a € ] tR t^ºt o Rt^ t^t^t^t^t	]
V 3R lR l4       t]
V 3R lR l4       tRtV tR# )r	   aÎ  Name a tensor dtype by an integer code, so that it can be stored in a tensor of augmentation parameters.

``DType.get`` also takes a ``torch.dtype`` or a one-element tensor holding a value, and ``DType.to_torch(value)``
returns the matching ``torch.dtype``; a torch dtype without a member, such as ``torch.uint8``, raises. The mix
augmentations, such as :class:`~kornia.augmentation.RandomMixUpV2`, record the input dtype in their ``dtype``
parameter this way.

c                ól   <€ V ^8„  d   QhRS[ S[S[S[P                  S[P
                  R3,          RR/# ©r   r1   r	   r   )r   r5   r7   ÚtorchÚdtypeÚTensor)r   r   s   "€r   r   ÚDType.__annotate__Ë   s4   ø€ ÷ 
ñ 
™™c¡3©¯©±U·\±\À7ÐJÕKð 
ÐPWñ 
r   c                óò  € \        V\        P                  4      '       d   \        V \	        V4      R,          V4      # \        V\
        4      '       d'   \        RV: R\        V4      P                   R24      h\        V\        P                  4      '       dg   VP                  4       p\        V\
        4      '       g    \        V4      P                  4       '       g   \        RV: R24      hV ! \        V4      4      # \        V\        4      '       d   \        WV4      # \        V\        4      '       d	   V ! V4      # \        W4      '       d   V# \        RV: R\        V4      P                   R24      h)zVReturn the DType member matching a name, a value, a torch dtype, a tensor or a member.:é   NNzf`DType.get` expects a `str`, `int`, `torch.dtype`, `torch.Tensor` or `DType` value, not a `bool`. Got re   rf   z@`DType.get` expects a tensor with an integral scalar value. Got r>   zX`DType.get` expects a `str`, `int`, `torch.dtype`, `torch.Tensor` or `DType` value. Got )r4   rŽ   r�   ra   r5   r%   rg   rh   r?   r�   ÚitemÚfloatÚ
is_integerr7   )rV   r1   r”   s   && r   rq   Ú	DType.getÊ   s<  € ô �eœUŸ[™[×)Ò)Ü ¤S¨£Z°¥^°UÓ;Ð;ä�eœT×"Ò"ÜðØ‘i˜z¬$¨u«+×*>Ñ*>Ð)?¸rðCóð ô
 �eœUŸ\™\×*Ò*Ø—:‘:“<ˆDÜ˜$¤×%Ò%¬U°4«[×-CÑ-C×-EÒ-EÜÐ"bÐchÑbkÐklÐ mÓnÐnÙ”s˜4“y“>Ð!ä�eœS×!Ò!Ü ¨EÓ2Ð2ä�eœS×!Ò!Ù�u“:Ðä�e×!Ò!ØˆLäðØ‘)˜:¤d¨5£k×&:Ñ&:Ð%;¸2ð?ó
ð 	
r   c                óH   <€ V ^8„  d   QhRS[ R,          RS[P                  /# r�   )r$   rŽ   r�   )r   r   s   "€r   r   r‘   ë   s#   ø€ ÷ ñ ™V G�_ð ±·±ñ r   c                ó¤  € V P                  VR7      pV\        P                  8X  d   \        P                  # V\        P
                  8X  d   \        P                  # V\        P                  8X  d   \        P                  # V\        P                  8X  d   \        P                  # V\        P                  8X  d   \        P                  # \        h)z>Return the torch dtype matching a DType name, value or member.r0   )rq   r	   ÚINT64rŽ   ÚlongÚFLOAT16Úfloat16ÚFLOAT32Úfloat32ÚFLOAT64Úfloat64ÚBFLOAT16Úbfloat16Ú
ValueError)rV   r1   Údatas   && r   Úto_torchÚDType.to_torchê   sˆ   € ð �w‰w˜UˆwÓ#ˆà”5—;‘;ÔÜ—:‘:Ðà”5—=‘=Ô Ü—=‘=Ð à”5—=‘=Ô Ü—=‘=Ð à”5—=‘=Ô Ü—=‘=Ð à”5—>‘>Ô!Ü—>‘>Ð!äÐr   r3   N)r?   rE   rF   rG   rH   rš   rœ   rž   r    r¢   rw   rq   r¦   rI   rJ   rT   s   @r   r	   r	   º   sK   ø‡ € ñð €EØ€GØ€GØ€GØ€Hà÷
ó ð
ð> ÷ó ör   c                   ód   a € ] tR tRt o Rt^ t^ t^t^t^t	^t
^t^t^t]V 3R lR l4       tRtV tR# )r
   i  a&  Name the kind of each input of an augmentation container: image, mask, boxes, keypoints or labels.

``AugmentationSequential(..., data_keys=[DataKey.INPUT, "mask"])`` takes one member, or its name in any case, per
input. ``INPUT`` is an alias of ``IMAGE`` and ``CLASS`` of ``LABEL``. ``BBOX`` holds ``(B, N, 4, 2)`` box corners,
``BBOX_XYXY`` and ``BBOX_XYWH`` ``(B, N, 4)`` boxes, and ``KEYPOINTS`` ``(B, N, 2)`` points.

See Also:
    - :class:`~kornia.augmentation.container.AugmentationSequential`: the container whose ``data_keys`` these name.

c                ó2   <€ V ^8„  d   QhRS[ R,          RR/# )r   r1   r
   r   rm   )r   r   s   "€r   r   ÚDataKey.__annotate__  s    ø€ ÷  ñ  ™˜yÕ)ð  ¨iñ  r   c                ó   € \        W4      # )z?Return the DataKey member matching a name, a value or a member.rp   ri   s   &&r   rq   ÚDataKey.get  rs   r   r3   N)r?   rE   rF   rG   rH   ÚIMAGEÚINPUTÚMASKÚBBOXÚ	BBOX_XYXYÚ	BBOX_XYWHÚ	KEYPOINTSÚLABELÚCLASSrw   rq   rI   rJ   rT   s   @r   r
   r
     sK   ø‡ € ñ	ð €EØ€EØ€DØ€DØ€IØ€IØ€IØ€EØ€Eà÷ ó ö r   )r   r	   r
   r   r   r$   Úpi)rH   Úenumr   r   Útypingr   r   r   r   rŽ   Ú__all__Útensorr¶   r   r5   r7   r$   r   r^   r¤   rM   ra   rj   r   r   r   r	   r
   r3   r   r   Ú<module>r»      s¾   ðñ$÷$  ß 1Ó 1ã â
Y€à
‡\‚\Ð(Ó)€ñ ˆT˜Ô€Ø	ˆs�C˜ˆ|Õ	€ôI�xô Iô&	'˜ *ô 	'õ	õô, ˆtÐ/õ  ô, �Ð!1õ  ô0 �DÐ$4õ  ô2DˆDÐ,õ DôP ˆdÐ.÷  r   