+
    –°³j
  ã                   óF   € ^ RI Ht ^ RIHt ^ RIHtHt R R ltR R ltR# )	é    )ÚCallable)ÚAny)ÚContextÚTreeSpecc                ó€   € V ^8„  d   QhR\         \        \        3,          R\        R\         \        \        3,          /# )é   Úuser_kwargsÚspecÚreturn)ÚdictÚstrr   r   )Úformats   "ÚY/home/luca/screen-checking/.venv/lib/python3.14/site-packages/torch/export/_tree_utils.pyÚ__annotate__r      s1   € ÷ ñ ¤¤S¬# X¥ð ´hð Ä4ÌÌSÈÅ>ñ ó    c                óö  € VP                   \        Jd   \        RVP                    24      hVP                  ^8w  d   \        RVP                   24      hVP	                  ^4      pVP                   \
        Jd   \        RVP                    24      h\        V 4      \        VP                  4      8w  d%   \        R\        V 4       RVP                   24      h/ pVP                   F  pW,          W4&   K  	  V# )aD  Reorder user-provided kwargs to match the order in `spec`. `spec` is
expected to be the in_spec of an exported program, i.e. the spec that
results from flattening `(args, kwargs)`.

We need this to provide consistent input ordering, such so that users can
pass in foo(a=a, b=b) OR foo(b=b, a=a) and receive the same result.
z(Expected spec type to be tuple, but got z*Expected spec to have 2 children, but got z.Expected kwargs_spec type to be dict, but got z>Ran into a kwarg keyword mismatch: Got the following keywords z but expected )
ÚtypeÚtupleÚAssertionErrorÚnum_childrenÚchildr   ÚsetÚcontextÚ
ValueErrorÚlist)r	   r
   Úkwargs_specÚreordered_kwargsÚkws   &&   r   Úreorder_kwargsr      s  € ð ‡y�yœÓÜÐGÈÏ	É	À{ÐSÓTÐTØ×Ñ˜AÔÜØ8¸×9JÑ9JÐ8KÐLó
ð 	
ð —*‘*˜Q“-€KØ×ÑœtÓ#ÜØ<¸[×=MÑ=MÐ<NÐOó
ð 	
ô ˆ;Óœ3˜{×2Ñ2Ó3Ô3Üð*Ü*.¨{Ó*;Ð)<¸NÈ;×K^ÑK^ÐJ_ðaó
ð 	
ð
 ÐØ×!Ô!ˆØ*�ÐÓñ "ð Ðr   c          
      ó¦   € V ^8„  d   QhR\         R\         R\        \        R,          \        \        R,          \        .\        3,          R\        /# )r   Úspec1Úspec2Úequivalence_fnNr   )r   r   r   r   Úbool)r   s   "r   r   r   )   sK   € ÷ ñ Üðäðô œd T�k¬7´D¸4µKÄÐIÌ4ÐOÕPðô 
ñ	r   c                óB  € V! V P                   V P                  VP                   VP                  4      '       g   R# V P                  VP                  8w  d   R# \        V P	                  4       VP	                  4       4       F  w  r4\        W4V4      '       d   K   R# 	  R# )a  Customizable equivalence check for two TreeSpecs.

Arguments:
    spec1: The first TreeSpec to compare
    spec2: The second TreeSpec to compare
    equivalence_fn: A function to determine the equivalence of two
        TreeSpecs by examining their types and contexts. It will be called like:

            equivalence_fn(spec1.type, spec1.context, spec2.type, spec2.context)

        This function will be applied recursively to all children.

Returns:
    True if the two TreeSpecs are equivalent, False otherwise.
FT)r   r   r   ÚzipÚchildrenÚis_equivalent)r!   r"   r#   Úchild_spec1Úchild_spec2s   &&&  r   r(   r(   )   sy   € ñ( ˜%Ÿ*™* e§m¡m°U·Z±ZÀÇÁ×OÒOÙð ×Ñ˜U×/Ñ/Ô/Ùä$'¨¯©Ó(8¸%¿.¹.Ó:JÖ$KÑ ˆÜ˜[°~×FÔFÚñ %Lñ r   N)	Úcollections.abcr   Útypingr   Útorch.utils._pytreer   r   r   r(   © r   r   Ú<module>r/      s   ðÝ $Ý ç 1õ÷Dr   