+
    åûjQ  ã                  óB   € ^ RI Ht ^ RIt^ RIHt ^RIHt RR R lltR# )é    )ÚannotationsN)Únms2d)Ú	Keypointsc          
     ó,   € V ^8„  d   QhRRRRRRRRR	R
/# )é   Úheatmapztorch.TensorÚnz
int | NoneÚwindow_sizeÚintÚscore_thresholdÚfloatÚreturnzlist[Keypoints]© )Úformats   "ÚXC:\Ai_Coding\apps\studio\ComfyUI\.venv\Lib\site-packages\kornia\feature\disk\detector.pyÚ__annotate__r      s4   € ÷ 5ñ 5Øð5Ø(ð5Ø>Að5ØX]ð5àñ5ó    c           
     óü  € V P                  ^4      p \        V P                  ^4      W"3RR7      P                  ^4      pW@V8„  ,          pV P                  R
,          p. p\	        V P                  ^ ,          4       EFü  p\
        P                  ! WX,          P                  4       4      P                  R
4      p	W,          P                  4       V	,          p
VEeM   V	P                  4       V8”  Ed7   V^ 8”  Ed   \
        P                  ! V
) V4      w  r¼V) pW­8„  pW­8H  pWï\
        P                  ! V^ 4      WP                  4       ,
          8*  ,          ,          p\
        P                  ! V\
        P                  ! V^ 4      ^,
          V4      p\
        P                  ! V^,           \
        P                  V	P                  R7      pVP!                  ^ V\
        P"                  ! V	P                  4       V	P                  R7      4       VRV pM	V	R,          pV	V,          p	V
V,          p
\
        P$                  ! W–,          \
        P&                  ! W–RR7      3R
R	7      pVP)                  \+        VV
4      4       EKÿ  	  V# )aÚ  Detect keypoints as the strict local maxima of a heatmap, in raster order.

Args:
    heatmap: detection logits of shape ``(B, 1, H, W)``.
    n: the maximum number of keypoints per image, counted among the maxima above ``score_threshold``. An image
        with ``n`` such maxima or fewer keeps all of them; with more, its ``n`` strongest, where maxima tied at the
        ``n``-th score are taken in raster order (row by row, then column by column) until ``n`` are kept.
        ``None`` keeps every maximum.
    window_size: the size of the non-maxima suppression window.
    score_threshold: a maximum is kept only if its score is strictly above it.

Returns:
    A list of length :math:`B` with the keypoints of each image.

T)Ú	mask_onlyN)ÚdtypeÚdevice)r   :Nr   NÚfloor)Úrounding_mode)Údiméÿÿÿÿ)Úsqueezer   Ú	unsqueezeÚshapeÚrangeÚtorchÚnonzeroÚflattenÚnumelÚkthvalueÚcumsumÚsumÚwhereÚzerosÚlongr   Úscatter_ÚarangeÚstackÚdivÚappendr   )r   r	   r
   r   Únms_maskÚnmsedÚwidthÚ	keypointsÚbÚflatÚdetection_logpÚminus_thresholdÚ_indicesÚ	thresholdÚaboveÚtiedÚmaskÚslotÚorderÚkeptÚxys   &&&&                 r   Úheatmap_to_keypointsr@      sé  € ð$ �o‰o˜aÓ €GÜ�W×&Ñ& qÓ)¨KÐ+EÐQUÔV×^Ñ^Ð_`Óa€HØ /Ñ1Õ2€Eà�M‰M˜"Õ€EØ€IÜ�7—=‘= Õ#×$ˆô �}Š}˜U�X×-Ñ-Ó/Ó0×8Ñ8¸Ó<ˆØ �×+Ñ+Ó-¨dÕ3ˆà‹=˜TŸZ™Z›\¨AÕ-ð �1�uÜ,1¯NªN¸N¸?ÈAÓ,NÑ)�Ø,Ð,�	Ø&Ñ2�Ø%Ñ2�Ø¬¯ª°T¸1Ó(=ÀÇYÁYÃ[ÅÑ(PÕ QÕR�ô —{’{ 4¬¯ª°d¸AÓ)>ÀÕ)BÀAÓF�ÜŸš A¨¥E´·±ÀDÇKÁKÔP�Ø—‘˜q $¬¯ª°T·Z±Z³\È$Ï+É+Ô(VÔWØ˜R˜a�y‘à˜B•x�Ø˜•:ˆDØ+¨DÕ1ˆNä�[Š[˜$�,¬¯	ª	°$ÈWÔ(UÐVÐ\^Ô_ˆØ×Ñœ 2 ~Ó6×7ñ7 %ð: Ðr   )Né   g        )Ú
__future__r   r    Úkornia.geometry.subpixr   Ústructsr   r@   r   r   r   Ú<module>rE      s   ðõ$ #ã å (å ÷5ñ 5r   