ó
    Eñi<‹  ã                   óD  • % S SK r S SKrS SKrS SKrS SKrS SKrS SKJrJrJ	r	J
r
  S SKJrJrJrJrJr  S SKJrJr  S SKrS SKJrJrJr  S SKJrJrJr  S SKJr  SS	KJr  S
SK J!r!  \(       a  S
SK"J#r#  / SQr$\RJ                  " \&5      r'\\(\)\*\+\,\RZ                  \R\                  \R^                  \R`                  \Rb                  \R<                  Rd                  \Rf                  \Rh                  \Rj                  4   r6\Rn                  " \65      r8\\S\4   \(4   r9\\:S'   \\\;S   \
S   \	\(S4   \<\=S\64      r>\" S\>S9r?\" S5      r@\" S5      rA\BR‡                  / SQ5      rD\RŠ                  RŒ                  \RŽ                  R�                  \RŽ                  R’                  /rJ\K\S\4      \:S'   \R˜                  \Rš                  \Rœ                  Rš                  Rž                  \Rœ                  R                   R¢                  \Rœ                  R¤                  R¢                  \Rœ                  R¦                  R¢                  \Rœ                  R¨                  R¢                  \Rª                  R¬                  \Rª                  R¬                  R¢                  \Rª                  R®                  \Rª                  R®                  R¢                  \Rª                  R°                  \Rª                  R°                  R²                  \R´                  R¶                  R¢                  \R¸                  1\Jkr]\^\S\4      \:S'   \_" \R´                  S5      (       a/  \]RÁ                  \R´                  RÂ                  R¢                  5        \!" SS9S\\@\A4   S\\@\A4   4S j5       rbS \S\4   S\(4S! jrcS"\dS\(4S# jreS$\S\4   S\(4S% jrf\*" S&5      4S'\dS(\*S\(4S) jjrg\!" S*S9 " S+ S\5      5       rh\!" S*S9S,\?S\\h/\>4   S\?4S- j5       ri\!" S*S9S,\?S\\>/\>4   S\?4S. j5       rjg)/é    N)ÚCallableÚIterableÚMappingÚSequence)ÚAnyÚOptionalÚTYPE_CHECKINGÚ	TypeAliasÚUnion)Ú	ParamSpecÚTypeVar)Ú_fx_map_aggregateÚ_fx_map_argÚ	_NodeBase)ÚArgsKwargsPairÚnormalize_functionÚnormalize_module)Údtype_abbrsé   )Úopsé   )Úcompatibility)ÚGraph)ÚNodeÚmap_argÚmap_aggregateÚhas_side_effect.ÚTarget©ÚArgument.r    r   Ú	ArgumentT)ÚboundÚ_PÚ_R)ÚplaceholderÚcall_methodÚcall_moduleÚcall_functionÚget_attrÚoutputÚrootÚ1_side_effectful_need_to_be_preserved_pre_dispatchÚ_side_effectful_functionsÚresize_storage_bytes_F©Úis_backward_compatibleÚfnÚreturnc                 ó0   • [         R                  U 5        U $ )a¨  
Registers a function to not be dead code eliminated by
fx.graph.eliminate_dead_code

NOTE: For new operators, please do not add to this set!
Instead, consider using the effects system via
torch.library._register_effectful_op() for operators.

This _side_effectful_functions set is only for:
- Legacy functions that aren't operators (e.g., profiler ops, asserts)
- Things that cannot be marked via the normal effects system
)r-   Úadd)r1   s    ÚJ/home/mande/repo/quber/.venv/lib/python3.13/site-packages/torch/fx/node.pyr   r   z   s   € ô ×!Ñ! "Ô%Ø€Ió    Úorig_methodc                 óà   • U R                   nU R                  nUb  U$ [        [        R                  R                  4 H   n[        X1S 5      U L d  M  UR                   s  $    [        SU  35      e)Nzcannot find module for )Ú__name__Ú
__module__ÚtorchÚnnÚ
functionalÚgetattrÚRuntimeError)r7   ÚnameÚmoduleÚguesss       r5   Ú_find_module_of_methodrC   �   sj   € Ø×Ñ€DØ×#Ñ#€FØÑØˆÜœŸ™×,Ñ,Ó-ˆÜ�5 Ó%¨Ô4Ø—>‘>Ò!ñ .ô Ð0°°Ð>Ó
?Ð?r6   Úobjc                 óP  • [        U [        5      (       aV  [        U [        R                  5      (       d7  U R                  S:X  a  U R
                  $ U R                   SU R
                   3$ U SL a  g[        U [        R                  5      (       a  U R                  $ [        U 5      $ )a&  Return the repr() of an object, special-casing types (internal helper).
If obj is a type, we return a shorter version than the default
type.__repr__, based on the module and qualified name, which is
typically enough to uniquely identify a type.  For everything
else, we fall back on repr(obj).
ÚbuiltinsÚ..z...)	Ú
isinstanceÚtypeÚtypesÚGenericAliasr:   Ú__qualname__ÚFunctionTyper9   Úrepr)rD   s    r5   Ú
_type_reprrO   š   s‰   € ô �#”t×Ñ¤Z°´U×5GÑ5G×%HÑ%HØ�>‰>˜ZÓ'Ø×#Ñ#Ð#Ø—.‘.Ð!  3×#3Ñ#3Ð"4Ð5Ð5Ø
ˆc‚zØÜ�#”u×)Ñ)×*Ñ*Ø�|‰|ÐÜ�‹9Ðr6   Úfuncc                 ó  • [        [        U R                  S 5      U L a  U R                  $ [        U [        R
                  [        R                  45      (       a(  U [        [        R                  U R                  S 5      L dE  U R                  [        R                  R                  :X  a,  U R                  SU R                   3:X  a  SU R                   3$ U R                  nUS:X  a7   [        R                  " U 5      R                  S5      S   R                  5       n[%        U 5      nUR'                  SS5      nUS	:X  a  US
:X  a  SU-   nUS:X  a  US;   a  UR)                  S5      nU SU 3$ ! [          a  n[#        S5      UeS nAff = f)NzTensor.ztorch.Tensor.z<lambda>Ú=r   zUnable to represent lambdaz
torch._opsz	torch.opsr;   Úsegment_reduceÚ_ztorch.nn.functional)Ú_ScalingTypeÚ_SwizzleTyperG   )r>   rF   r9   rH   rJ   ÚMethodDescriptorTypeÚWrapperDescriptorTyper;   ÚTensorr:   Ú_tensorrL   ÚinspectÚ	getsourceÚsplitÚstripÚ	Exceptionr?   rC   ÚreplaceÚremoveprefix)rP   r@   ÚerA   s       r5   Ú_get_qualified_namerc   ®   sh  € äŒx˜Ÿ™¨Ó-°Ò5Ø�}‰}Ðô 	�4œ%×4Ñ4´e×6QÑ6QÐR×SÑSØ”GœEŸL™L¨$¯-©-¸Ó>Ò>à�‰œ5Ÿ=™=×1Ñ1Ó1Ø×Ñ 7¨4¯=©=¨/Ð!:Ó:à˜tŸ}™}˜oÐ.Ð.Ø�=‰=€DØˆzÓð	DÜ×$Ò$ TÓ*×0Ñ0°Ó5°aÑ8×>Ñ>Ó@ˆDô $ DÓ)€FØ�^‰^Ø�kó€Fð �Ó˜TÐ%5Ó5Ø�T‰zˆØÐ&Ó&¨4Ð3SÓ+SØ× Ñ  Ó%ˆØˆX�Q�t�fÐÐøô ó 	DÜÐ;Ó<À!ÐCûð	Dús   Ã)6E1 Å1
FÅ;FÆFÚinfÚargÚmax_list_lenc                 óÞ  ^• [        U S5      (       a  U R                  5       $ [        U [        5      (       aO  SR	                  U4S j[        U 5       5       5      n[        U 5      TS-   :  a  SOS[        U 5       S3nSU U S3$ [        U [        5      (       ad  SR	                  U4S	 j[        U 5       5       5      n[        U 5      TS-   :  a  SOS[        U 5       S3n[        U 5      S:X  a  S
OSnSU U U S3$ [        U [        5      (       a,  SR	                  S U R                  5        5       5      nSU S3$ [        U [        5      (       a  S[        U 5      -   $ [        U 5      $ )NÚ_custom_fx_repr_fnú, c              3   óN   >#   • U  H  u  pUT:  d  M  [        U5      v •  M     g 7f©N©Ú_format_arg©Ú.0ÚidxÚarf   s      €r5   Ú	<genexpr>Ú_format_arg.<locals>.<genexpr>Ò   ó%   øé € ð 
Ú)7™v˜s¸3ÀÑ;M‹NŒK˜�NˆNªùó   ƒ%“%r   Ú z, ...[total_len=Ú]Ú[c              3   óN   >#   • U  H  u  pUT:  d  M  [        U5      v •  M     g 7frk   rl   rn   s      €r5   rr   rs   Ú   rt   ru   Ú,Ú(Ú)c              3   óF   #   • U  H  u  pU S [        U5       3v •  M     g7f)ú: Nrl   )ro   ÚkÚvs      r5   rr   rs   ã   s"   é € ÐOÂ;¹4¸1   2¤k°!£nÐ%5Õ6Â;ùs   ‚!Ú{Ú}Ú%)Úhasattrrh   rH   ÚlistÚjoinÚ	enumerateÚlenÚtupleÚdictÚitemsr   Ústr)re   rf   r‹   Ú	maybe_lenÚmaybe_commaÚ	items_strs    `    r5   rm   rm   Î   se  ø€ ÜˆsÐ(×)Ñ)Ø×%Ñ%Ó'Ð'Ü	�Cœ×	Ñ	Ø—	‘	ô 
Ü)2°3¬ó
ó 
ˆô �c“(˜\¨AÑ-Ó-‰BÐ5EÄcÈ#ÃhÀZÈqÐ3Qð 	ð �5�'˜)˜ AÐ&Ð&Ü	�Cœ×	Ñ	Ø—	‘	ô 
Ü)2°3¬ó
ó 
ˆô �c“(˜\¨AÑ-Ó-‰BÐ5EÄcÈ#ÃhÀZÈqÐ3Qð 	ô ! ›X¨›]‘c°ˆØ�5�'˜+˜ y k°Ð3Ð3Ü	�Cœ×	Ñ	Ø—I‘IÑOÀ3Ç9Á9Ä;ÓOÓOˆ	Ø�I�;˜bÐ!Ð!ä�#”t×ÑØ”S˜“X‰~Ðä�3‹xˆr6   Tc                   ó2  ^ • \ rS rSr% Sr\S   \S'   \\S4   \S'   S\S'   \\S	'   \\S
'   S\S'   \S   \S'   \S   \S'   \	\
   \S'   \
\S'   \	\S /\4      \S'   \\\
4   \S'   \" SS9 SNSSS	\S
\SSS\S   S\\S4   S\	\
   SS4U 4S jjj5       rS\\\
4   4S jrS\\\
4   SS4S jr\SOS j5       r\SOS  j5       r\" SS9SPS! j5       r\" SS9SPS" j5       r\S\\S#4   4S$ j5       r\R.                  S%\\S#4   SS4S& j5       r\S\\\4   4S' j5       r\R.                  S(\\\4   SS4S) j5       r\S\S    4S* j5       r\" SS9S+\S,\SS4S- j5       r\" SS9S+\S,\SS4S. j5       r\" SS9S/\S,\SS4S0 j5       r\S\	\   4S1 j5       r\R.                  S2\	\   SS4S3 j5       rS\4S4 jr \!S\"S\4S5 j5       r#\" SS9  SQS6S7.S8\	\\      S9\	\\      S:\$S\	\   4S; jjj5       r%\" SS9 SNS6S<.S=S S>\	\S /\$4      S?\$S\S    4S@ jjj5       r&\" S6S9SRSA\$S\$4SB jj5       r'\" S6S9   SSSC\(RR                  RT                  SD\	\\
      SE\	\\\
4      SF\$S\	\+   4
SG jj5       r,\" SS9STSH j5       r-SI\SS4SJ jr.S	\SK\
SS4SL jr/SMr0U =r1$ )Ur   éì   a  
``Node`` is the data structure that represents individual operations within
a ``Graph``. For the most part, Nodes represent callsites to various entities,
such as operators, methods, and Modules (some exceptions include nodes that
specify function inputs and outputs). Each ``Node`` has a function specified
by its ``op`` property. The ``Node`` semantics for each value of ``op`` are as follows:

- ``placeholder`` represents a function input. The ``name`` attribute specifies the name this value will take on.
  ``target`` is similarly the name of the argument. ``args`` holds either: 1) nothing, or 2) a single argument
  denoting the default parameter of the function input. ``kwargs`` is don't-care. Placeholders correspond to
  the function parameters (e.g. ``x``) in the graph printout.
- ``get_attr`` retrieves a parameter from the module hierarchy. ``name`` is similarly the name the result of the
  fetch is assigned to. ``target`` is the fully-qualified name of the parameter's position in the module hierarchy.
  ``args`` and ``kwargs`` are don't-care
- ``call_function`` applies a free function to some values. ``name`` is similarly the name of the value to assign
  to. ``target`` is the function to be applied. ``args`` and ``kwargs`` represent the arguments to the function,
  following the Python calling convention
- ``call_module`` applies a module in the module hierarchy's ``forward()`` method to given arguments. ``name`` is
  as previous. ``target`` is the fully-qualified name of the module in the module hierarchy to call.
  ``args`` and ``kwargs`` represent the arguments to invoke the module on, *excluding the self argument*.
- ``call_method`` calls a method on a value. ``name`` is as similar. ``target`` is the string name of the method
  to apply to the ``self`` argument. ``args`` and ``kwargs`` represent the arguments to invoke the module on,
  *including the self argument*
- ``output`` contains the output of the traced function in its ``args[0]`` attribute. This corresponds to the "return" statement
  in the Graph printout.
r   Ú_argsr    Ú_kwargsr   Úgraphr@   Úopr   Útarget)r   NÚ_input_nodesÚusersrI   Ú	_sort_keyÚ_repr_fnÚmetaTr/   NÚargsÚkwargsÚreturn_typer2   c                 ó„  >• US:X  a=  [        U5      (       d,  [        SU SU SU S[        R                  " U5       S3	5      eOZU[        ;  a  [        SU S35      e[        U[        5      (       d,  [        SU SU SU S[        R                  " U5       S	3	5      e[        TU ]%  XX4U5        U R                  XV5        g
)aí  
Instantiate an instance of ``Node``. Note: most often, you want to use the
Graph APIs, i.e. ``Graph.call_module``, ``Graph.call_method``, etc. rather
than instantiating a ``Node`` directly.

Args:
    graph (Graph): The ``Graph`` to which this ``Node`` should belong.

    name (str): The name to which the output of this ``Node`` should be assigned

    op (str): The opcode for this ``Node``. Can be one of 'placeholder',
        'call_method', 'call_module', 'call_function', 'get_attr',
        'output'

    target ('Target'): The target this op should call. See the broader
        ``Node`` docstring for more details.

    args (Tuple['Argument']): The args to be passed to ``target``

    kwargs (Dict[str, 'Argument']): The kwargs to be passed to ``target``

    return_type (Optional[Any]): The python type expression representing the
        type of the output of this node. This field can be used for
        annotation of values in the generated code or for other types
        of analyses.
r(   zNode [graph = z
, name = 'z
'] target z
 has type z but a Callable is expectedzop 'z' is not in _legal_opsz but a str is expectedN)ÚcallableÚ
ValueErrorr;   ÚtypenameÚ
_legal_opsÚAssertionErrorrH   rŒ   ÚsuperÚ__init__Ú_update_args_kwargs)	Úselfr”   r@   r•   r–   rœ   r�   rž   Ú	__class__s	           €r5   r¦   ÚNode.__init__.  sé   ø€ ðJ �Ó Ü˜F×#Ñ#Ü Ø$ U G¨:°d°V¸:ÀfÀXÈZÔX]×XfÒXfÐgmÓXnÐWoð p1ð 1óð ð $ð œÓ#Ü$ t¨B¨4Ð/EÐ%FÓGÐGÜ˜f¤c×*Ñ*Ü Ø$ U G¨:°d°V¸:ÀfÀXÈZÔX]×XfÒXfÐgmÓXnÐWoð p,ð ,óð ô 	‰Ñ˜ b°+Ô>Ø× Ñ  Õ.r6   c                 ón  • 0 U R                   EU R                  U R                  U R                  U R                  U R
                  U R                  U R                  U R                  U R                  U R                  U R                  U R                  U R                  U R                  U R                  S.E$ )N)r”   r@   r•   r–   rI   r™   r’   r“   Ú_erasedÚ_prevÚ_nextr—   r˜   rš   r›   )Ú__dict__r”   r@   r•   r–   rI   r™   r’   r“   r¬   r­   r®   r—   r˜   rš   r›   ©r¨   s    r5   Ú__getstate__ÚNode.__getstate__d  sˆ   € ð
Ø�m‰mð
à—Z‘ZØ—I‘IØ—'‘'Ø—k‘kØ—I‘IØŸ™Ø—Z‘ZØ—|‘|Ø—|‘|Ø—Z‘ZØ—Z‘ZØ ×-Ñ-Ø—Z‘ZØŸ™Ø—I‘Iò!
ð 	
r6   Ústatec                 óN   • UR                  5        H  u  p#[        XU5        M     g rk   )r‹   Úsetattr)r¨   r³   r   r€   s       r5   Ú__setstate__ÚNode.__setstate__x  s   € Ø—K‘K–M‰DˆAÜ�D˜QÖò "r6   c                 ó   • U R                   $ )zv
Returns the next ``Node`` in the linked list of Nodes.

Returns:

    The next ``Node`` in the linked list of Nodes.
)r®   r°   s    r5   ÚnextÚ	Node.next|  ó   € ð �z‰zÐr6   c                 ó   • U R                   $ )z~
Returns the previous ``Node`` in the linked list of Nodes.

Returns:

    The previous ``Node`` in the linked list of Nodes.
)r­   r°   s    r5   ÚprevÚ	Node.prev‡  r»   r6   c                 ó&   • U R                  U5        g)a  
Insert x before this node in the list of nodes in the graph. Example::

    Before: p -> self
            bx -> x -> ax
    After:  p -> x -> self
            bx -> ax

Args:
    x (Node): The node to put before this node. Must be a member of the same graph.
N)Ú_prepend©r¨   Úxs     r5   ÚprependÚNode.prepend’  s   € ð 	�‰�aÕr6   c                 ó:   • U R                   R                  U5        g)zÂ
Insert ``x`` after this node in the list of nodes in the graph.
Equivalent to ``self.next.prepend(x)``

Args:
    x (Node): The node to put after this node. Must be a member of the same graph.
N)r®   rÀ   rÁ   s     r5   ÚappendÚNode.append¢  s   € ð 	�
‰
×Ñ˜AÕr6   .c                 ó   • U R                   $ )a  
The tuple of arguments to this ``Node``. The interpretation of arguments
depends on the node's opcode. See the :class:`Node` docstring for more
information.

Assignment to this property is allowed. All accounting of uses and users
is updated automatically on assignment.
)r’   r°   s    r5   rœ   Ú	Node.args®  s   € ð �z‰zÐr6   rq   c                 ó:   • U R                  XR                  5        g)z�
Set the tuple of arguments to this Node. The interpretation of arguments
depends on the node's opcode. See the ``fx.Graph`` docstring for more
information.
N)r§   r“   )r¨   rq   s     r5   rœ   rÉ   º  s   € ð 	× Ñ  §L¡LÕ1r6   c                 ó   • U R                   $ )a  
The dict of keyword arguments to this ``Node``. The interpretation of arguments
depends on the node's opcode. See the :class:`Node` docstring for more
information.

Assignment to this property is allowed. All accounting of uses and users
is updated automatically on assignment.
)r“   r°   s    r5   r�   ÚNode.kwargsÅ  s   € ð �|‰|Ðr6   r   c                 ó<   • U R                  U R                  U5        g)z™
Set the dict of kwargs to this Node. The interpretation of arguments
depends on the node's opcode. See the ``fx.Graph`` docstring for more
information.
N)r§   r’   )r¨   r   s     r5   r�   rÌ   Ñ  s   € ð 	× Ñ  §¡¨QÕ/r6   c                 óH   • [        U R                  R                  5       5      $ )a  
Return all Nodes that are inputs to this Node. This is equivalent to
iterating over ``args`` and ``kwargs`` and only collecting the values that
are Nodes.

Returns:

    List of ``Nodes`` that appear in the ``args`` and ``kwargs`` of this
    ``Node``, in that order.
)r…   r—   Úkeysr°   s    r5   Úall_input_nodesÚNode.all_input_nodesÜ  s   € ô �D×%Ñ%×*Ñ*Ó,Ó-Ð-r6   rp   re   c                 óV   • [        U R                  5      nX#U'   [        U5      U l        g)a  
Update an existing positional argument to contain the new value
``arg``. After calling, ``self.args[idx] == arg``.

Args:

    idx (int): The index into ``self.args`` of the element to update
    arg (Argument): The new argument value to write into ``args``
N)r…   rœ   r‰   )r¨   rp   re   rœ   s       r5   Ú
update_argÚNode.update_argê  s#   € ô �D—I‘I‹ˆØˆS‰	Ü˜$“Kˆ�	r6   c                 óˆ  • SUs=::  a  [        U R                  5      ::  d  O  [        SU 35      eU R                  SU nU R                  US nX24-   U-   U l        0 n[	        X%R
                  5        U HJ  nX`R                  ;  d  M  U R                  R                  U5        UR                  R                  U 5        ML     g)zá
Insert an positional argument to the argument list with given index.

Args:

    idx (int): The index of the element in ``self.args`` to be inserted before.
    arg (Argument): The new argument value to insert into ``args``
r   z<insert_args index must be between 0 and len(self.args), got N)rˆ   rœ   r¤   r’   r   Ú
setdefaultr—   r˜   )r¨   rp   re   Ú	args_leftÚ
args_rightÚ_new_input_nodesÚnew_uses          r5   Ú
insert_argÚNode.insert_argù  s±   € ð �SÕ*œC §	¡	›NÕ*Ü ØNÈsÈeÐTóð ð —I‘I˜d˜s�Oˆ	Ø—Y‘Y˜s˜t�_ˆ
à Ñ'¨*Ñ4ˆŒ
à-/ÐÜ�C×4Ñ4Ô5ã'ˆGØ×/Ñ/Õ/Ø×!Ñ!×,Ñ,¨WÔ5Ø—‘×(Ñ(¨Ö.ò (r6   Úkeyc                 ó0   • 0 U R                   EX0EU l         g)a  
Update an existing keyword argument to contain the new value
``arg``. After calling, ``self.kwargs[key] == arg``.

Args:

    key (str): The key in ``self.kwargs`` of the element to update
    arg (Argument): The new argument value to write into ``kwargs``
N)r�   )r¨   rÝ   re   s      r5   Úupdate_kwargÚNode.update_kwarg  s   € ð 0˜Ÿ™Ð/ cÑ/ˆ�r6   c                 ó:   • U R                   R                  SS5      $ )aÀ  
Return the Python stack trace that was recorded during tracing, if any.
When traced with fx.Tracer, this property is usually populated by
`Tracer.create_proxy`. To record stack traces during tracing for debug purposes,
set `record_stack_traces = True` on the `Tracer` instance.
When traced with dynamo, this property will be populated by default by
`OutputGraph.create_proxy`.

stack_trace would have the innermost frame at the end of the string.
Ústack_traceN)r›   Úgetr°   s    r5   râ   ÚNode.stack_trace!  s   € ð �y‰y�}‰}˜]¨DÓ1Ð1r6   Útracec                 ó    • XR                   S'   g )Nrâ   )r›   )r¨   rå   s     r5   râ   rä   /  s   € à#(�	‰	�-Ò r6   c                 ó^   • U R                   (       a  U R                  U 5      $ U R                  $ rk   )rš   r@   r°   s    r5   Ú__repr__ÚNode.__repr__3  s"   € Ø�=�=Ø—=‘= Ó&Ð&Ø�y‰yÐr6   c                 óò   • [        U [        5      (       a  U $ [        U S5      (       aE  [        U SS5      nUc  [	        U 5      $ U R
                  S:X  a  SU 3$ U R
                  S:X  a  SU 3$ [	        U 5      $ )zÏ
Make target printouts more user-friendly.
1) builtins will be printed as `builtins.xyz`
2) operators will be printed as `operator.xyz`
3) other callables will be printed with qualified name, e.g. torch.add
r:   r9   NrF   z	builtins.Ú	_operatorz	operator.)rH   rŒ   r„   r>   rc   r:   )r–   r@   s     r5   Ú_pretty_print_targetÚNode._pretty_print_target8  s„   € ô �fœc×"Ñ"ØˆMÜ�6˜<×(Ñ(Ü˜6 :¨tÓ4ˆDØ‰|ô +¨6Ó2Ð2Ø× Ñ  JÓ.Ø" 4 &Ð)Ð)Ø×"Ñ" kÓ1Ø" 4 &Ð)Ð)Ü" 6Ó*Ð*r6   F)Úinclude_tensor_metadataÚplaceholder_namesÚmaybe_return_typenamerî   c                ó¨  • U R                   S:X  Ga6  [        U R                  [        5      (       d!  [	        S[        U R                  5       35      eU R                  nX@R
                  (       a  US[        U R
                  5       3-   OS-  nU(       a  UR                  U5        gU R
                  (       a  [        U R
                  5       S3OSnU R                  (       a  S[        U R                  S   5      -   S	-   OSnS
U R                   SU S[        U R                  5       SU R                    SU R                   SU 3$ U R                   S:X  ay  U R
                  b  [        U R
                  5       S3OSnS
U R                   SU S[        U R                  5       SU R                    SU R                  U R                  5       S3$ U R                   S:X  aE  U R
                  (       a"  U(       a  S[        U R
                  5       3US'   SU R                  S    3$ S[        S[        4S jnU R                  R                  SU R                  R                  SU R                  R                  SS5      5      5      nSn	U(       aŸ  [        U[         R"                  5      (       a€  UR$                  [         R&                  [         R(                  4;  aR  U" UR+                  5       5       n
UR,                   nS[.        UR0                      U" UR2                  5       U
 U S3n	O'U R
                  b  [        U R
                  5       S3OSn	S
U R                   SU	 S[        U R                  5       SU R                    SU R                  U R                  5       S[5        U R                  5       S[5        U R6                  5       S	3$ )a�  
Return a descriptive string representation of ``self``.

This method can be used with no arguments as a debugging
utility.

This function is also used internally in the ``__str__`` method
of ``Graph``. Together, the strings in ``placeholder_names``
and ``maybe_return_typename`` make up the signature of the
autogenerated ``forward`` function in this Graph's surrounding
GraphModule. ``placeholder_names`` and ``maybe_return_typename``
should not be used otherwise.

Args:
    placeholder_names: A list that will store formatted strings
        representing the placeholders in the generated
        ``forward`` function. Internal use only.
    maybe_return_typename: A single-element list that will store
        a formatted string representing the output of the
        generated ``forward`` function. Internal use only.
    include_tensor_metadata: Whether to include tensor metadata

Returns:
    str: If 1) we're using ``format_node`` as an internal helper
        in the ``__str__`` method of ``Graph``, and 2) ``self``
        is a placeholder Node, return ``None``. Otherwise,
        return a  descriptive string representation of the
        current Node.
r%   z/Expected target to be str for placeholder, got r~   rv   NÚ z	(default=r   r|   rƒ   z : z[num_users=z] = z[target=rw   r)   r*   z -> zreturn Úshaper2   c           	      ój   • SSR                  U  Vs/ s H  n[        U5      PM     sn5       S3$ s  snf )Nrx   ri   rw   )r†   rŒ   )ró   rÂ   s     r5   Ústringify_shapeÚ)Node.format_node.<locals>.stringify_shape‘  s1   € Ø˜4Ÿ9™9±eÓ%<²e°¤c¨!¦f±eÑ%<Ó=Ð>¸aÐ@Ð@ùÒ%<s   ‘0
ÚvalÚtensor_metaÚexample_valuezTensor "Ú"z	](args = z, kwargs = )r•   rH   r–   rŒ   r¤   rI   rO   rÆ   rœ   r@   rˆ   r˜   rì   r   r›   rã   r;   rY   ÚlayoutÚ
sparse_cscÚ
sparse_csrÚstrideÚdevicer   Údtyperó   rm   r�   )r¨   rï   rð   rî   Úarg_strÚmaybe_typenameÚdefault_valrõ   Úmeta_valÚtype_annotationÚstride_annotationÚdevice_annotations               r5   Úformat_nodeÚNode.format_nodeQ  sr  € ðJ �7‰7�mÔ#Ü˜dŸk™k¬3×/Ñ/Ü$ØEÄdÈ4Ï;É;ÓFWÐEXÐYóð ð —k‘kˆGØÇÇ�w 2¤j°·±Ó&;Ð%<Ð!=Ò=ÐPRÑRˆGÞ Ø!×(Ñ(¨Ô1ØØ<@¿I¿I¤
¨4¯9©9Ó 5Ð6°aÑ8È2ˆNØCGÇ9Ç9˜+¬¨D¯I©I°a©LÓ(9Ñ9¸CÒ?ÐRTˆKØ�t—y‘y�k  ^Ð$4°KÄÀDÇJÁJÃÐ?PÐPTÐUY×U\ÑU\ÐT]Ð]eÐfj×fqÑfqÐerÐrsÐtð  tAð  Bð  BØ�W‰W˜
Ó"à/3¯y©yÑ/D”:˜dŸi™iÓ(Ð)¨Ñ+È"ð ð �D—I‘I�;˜c .Ð!1°¼SÀÇÁ»_Ð<MÈTØ—7‘7�)˜8 D×$=Ñ$=¸d¿k¹kÓ$JÐ#KÈ1ðNðð �W‰W˜Ó Ø�y�yÖ2Ø-1´*¸T¿Y¹YÓ2GÐ1HÐ+IÐ% aÑ(Ø˜TŸY™Y q™\˜NÐ+Ð+ðA¤xð A´Cô Að —y‘y—}‘}ØØ—	‘	—‘˜m¨T¯Y©Y¯]©]¸?ÈDÓ-QÓRóˆHð !ˆOæ'Ü˜x¬¯©×6Ñ6Ø—O‘Oä×$Ñ$Ü×$Ñ$ðóñ (7°x·±Ó7HÓ'IÐ&JÐ!Ø'/§¡Ð&7Ð!àœ{¨8¯>©>Ñ:Ð;¹OÈHÏNÉNÓ<[Ð;\Ø(Ð)Ð*;Ð)<¸Að?ñ  ð 48·9±9Ñ3H”z $§)¡)Ó,Ð-¨QÑ/Èbð  ð �D—I‘I�;˜c /Ð!2°+¼cÀ$Ç*Á*»oÐ=NÈdØ—7‘7�)˜8 D×$=Ñ$=¸d¿k¹kÓ$JÐ#Kð LÜ% d§i¡iÓ0Ð1°¼[ÈÏÉÓ=UÐ<VÐVWðYðr6   )Úpropagate_metaÚreplace_withÚdelete_user_cbr
  c                óÜ  • U(       aU  [        UR                  5      S:w  a  [        S5      eU R                  R                  5        H  u  pEXQR                  U'   M     / U R                  Qn[        U R                  R                  SS5      n/ nU HX  n	Ub  U" U	5      (       d  M  UR                  U	5        U(       a  U H  n
U
" XR                  U	S9  M     U	R                  X5        MZ     U$ )a_  
Replace all uses of ``self`` in the Graph with the Node ``replace_with``.

Args:

    replace_with (Node): The node to replace all uses of ``self`` with.
    delete_user_cb (Callable): Callback that is called to determine
      whether a given user of the self node should be removed.
    propagate_meta (bool): Whether or not to copy all properties
      on the .meta field of the original node onto the replacement node.
      For safety, this is only valid to do if the replacement node
      doesn't already have an existing .meta field.

Returns:

    The list of Nodes on which this change was made.
r   zmCalled node.replace_all_uses_with(replace_with, propagate_meta=True), but replace_with already has .meta keysÚ_replace_hooksN©ÚoldÚnewÚuser)rˆ   r›   r¤   r‹   r˜   r>   r”   Úowning_modulerÆ   r@   Ú_replace_input_with)r¨   r  r  r
  r   r€   Ú
to_processÚreplace_hooksÚresultÚuse_nodeÚreplace_hooks              r5   Úreplace_all_uses_withÚNode.replace_all_uses_with²  sÛ   € ö2 Ü�<×$Ñ$Ó%¨Ó*Ü$ð>óð ð Ÿ	™	Ÿ™Ö)‘�Ø'(×!Ñ! !Ó$ñ *à"�t—z‘z�]ˆ
Ü §
¡
× 8Ñ 8Ð:JÈDÓQˆØˆÛ"ˆHØÑ)±.À×2JÑ2JÙØ�M‰M˜(Ô#ÞÛ$1�LÙ  T×/@Ñ/@ÀxÔPñ %2ð ×(Ñ(¨Ö<ñ #ð ˆr6   Úimpure_randomc                 ó²  • U R                   S;   a  gU R                   S:X  ay  U R                  R                  c  [        S5      eU R                  R                  R	                  U R
                  5      nUc  [        SU R
                   35      e[        USS5      $ U R                   S:X  a-  S	S
KJn  U" U R
                  U R                  U R                  US9$ g)zû
Returns whether this op is impure, i.e. if its op is a placeholder or
output, or if a call_function or call_module which is impure.

Args:
    impure_random (bool): Whether to treat rand op as impure.

Returns:

    bool: If the op is impure or not.
>   r*   r%   Tr'   z1self.graph.owning_module not set for purity checkz'Did not find expected submodule target Ú
_is_impureFr(   r   )Ú	is_impure)rœ   r�   r  )r•   r”   r  r¤   Úget_submoduler–   r>   Útorch._library.utilsr  rœ   r�   )r¨   r  Ú
target_modr  s       r5   r  ÚNode.is_impureá  sÏ   € ð �7‰7Ð/Ó/Øð �7‰7�mÓ#Ø�z‰z×'Ñ'Ñ/Ü$ØGóð ð Ÿ™×1Ñ1×?Ñ?ÀÇÁÓLˆJØÑ!Ü$Ø=¸d¿k¹k¸]ÐKóð ô ˜: |°UÓ;Ð;ð �7‰7�oÓ%Ý6áØ—‘Ø—Y‘YØ—{‘{Ø+ñ	ð ð r6   r+   Ú	arg_typesÚkwarg_typesÚnormalize_to_only_use_kwargsc           	      óè  • U R                   S:X  ag  [        U R                  5      (       d!  [        S[	        U R                  5       35      e[        U R                  U R                  U R                  UUUS9$ U R                   S:X  ak  [        U R                  [        5      (       d!  [        S[	        U R                  5       35      e[        UU R                  U R                  U R                  US9$ g)a1  
Returns normalized arguments to Python targets. This means that
`args/kwargs` will be matched up to the module/functional's
signature and return exclusively kwargs in positional order
if `normalize_to_only_use_kwargs` is true.
Also populates default values. Does not support positional-only
parameters or varargs parameters.

Supports module calls.

May require `arg_types` and `kwarg_types` in order to disambiguate overloads.

Args:
    root (torch.nn.Module): Module upon which to resolve module targets.
    arg_types (Optional[Tuple[Any]]): Tuple of arg types for the args
    kwarg_types (Optional[Dict[str, Any]]): Dict of arg types for the kwargs
    normalize_to_only_use_kwargs (bool): Whether to normalize to only use kwargs.

Returns:

    Returns NamedTuple ArgsKwargsPair, or `None` if not successful.
r(   zExpected callable target, got )r&  r'   z)Expected str target for call_module, got N)r•   r    r–   r¤   rI   r   rœ   r�   rH   rŒ   r   )r¨   r+   r$  r%  r&  s        r5   Únormalized_argumentsÚNode.normalized_arguments  sÜ   € ð< �7‰7�oÓ%Ü˜DŸK™K×(Ñ(Ü$Ø4´T¸$¿+¹+Ó5FÐ4GÐHóð ô &Ø—‘Ø—	‘	Ø—‘ØØØ-Iñð ð �W‰W˜Ó%Ü˜dŸk™k¬3×/Ñ/Ü$Ø?ÄÀTÇ[Á[Ó@QÐ?RÐSóð ô $ØØ—‘Ø—	‘	Ø—‘Ø-Iñð ð r6   c                 ó¾   • U R                   R                  n[        USS5      (       a$  UR                   H  nU" XR                  U S9  M     U R                  X5        g)zê
Loop through input nodes of ``self``, and replace all instances of
``old_input`` with ``new_input``.

Args:

    old_input (Node): The old input node to be replaced.
    new_input (Node): The new input node to replace ``old_input``.
r  Nr  )r”   r  r>   r  r@   r  )r¨   Ú	old_inputÚ	new_inputÚmr  s        r5   Úreplace_input_withÚNode.replace_input_withJ  sQ   € ð �J‰J×$Ñ$ˆÜ�1Ð&¨×-Ñ-Ø !× 0Ô 0�Ù ·±ÀTÔJñ !1ð 	× Ñ  Õ6r6   Ú	candidatec                 óÆ   • XR                   :X  a  g U R                  R                  R                  US 5      nX l         U R                  R                  R	                  X5        g rk   )r@   r”   Ú_graph_namespaceÚcreate_nameÚ_rename_object)r¨   r0  r@   s      r5   Ú_renameÚNode._rename]  sH   € ØŸ	™	Ó!ØØ�z‰z×*Ñ*×6Ñ6°yÀ$ÓGˆØŒ	Ø�
‰
×#Ñ#×2Ñ2°4Õ>r6   Úvaluec                 ó”  • US:X  a’  [        U S5      (       a�  U R                  R                  n[        USS 5      (       aY  [	        U[
        5      (       d  [        S[        U5       35      eU R                   H  nUR                   H
  nU" XUS9  M     M     Sn[        X5      (       a[  [        U R                  S5      (       a@  X R                  R                  ;   a'  SnU R                  R                  R                  U 5        [        R                  XU5        U(       a&  U R                  R                  R                  U 5        g g )Nr@   r  zExpected value to be str, got r  FÚ_find_nodes_lookup_tableT)r„   r”   r  r>   rH   rŒ   r¤   rI   r˜   r  r9  ÚremoveÚobjectÚ__setattr__Úinsert)r¨   r@   r7  r-  r  r  Úupdates          r5   r<  ÚNode.__setattr__d  s  € Ø�6‹>œg d¨F×3Ñ3Ø—
‘
×(Ñ(ˆAÜ�qÐ*¨D×1Ñ1Ü! %¬×-Ñ-Ü(Ð+IÌ$ÈuË+ÈÐ)WÓXÐXØ ŸJœJ�DØ()×(8Ô(8˜Ù$¨¸tÔDó )9ñ 'ð ˆä�D×ÑÜ˜Ÿ
™
Ð$>×?Ñ?ØŸ
™
×;Ñ;Ó;àˆFØ�J‰J×/Ñ/×6Ñ6°tÔ<Ü×Ñ˜4 uÔ-ÞØ�J‰J×/Ñ/×6Ñ6°tÕ<ð r6   )r’   rœ   r�   r@   rk   )r2   r   )rÂ   r   r2   N)NN)T)NNF)r+  r   r,  r   r2   N)2r9   r:   rL   Ú__firstlineno__Ú__doc__r‰   Ú__annotations__rŠ   rŒ   r   r   r   r   r¦   r±   r¶   Úpropertyr¹   r½   rÃ   rÆ   r    rœ   Úsetterr�   r…   rÐ   ÚintrÓ   rÛ   rß   râ   rè   Ústaticmethodr;  rì   Úboolr  r  r  r;   r<   ÚModuler   r(  r.  r5  r<  Ú__static_attributes__Ú__classcell__)r©   s   @r5   r   r   ì   s  ø‡ ñð6 �Ñ!Ó!Ø�#�z�/Ñ"Ó"ØƒNà
ƒIàƒGð Óð �|Ñ$Ó$ð
 �ÑÓð �3‰-ÓØƒNà�x  ¨# Ñ.Ñ/Ó/ð ˆs�Cˆx‰.Óá¨$Ñ/ð &*ñ3/àð3/ð ð3/ð ð	3/ð
 ð3/ð �OÑ$ð3/ð �S˜*�_Ñ%ð3/ð ˜c‘]ð3/ð 
÷3/ó 0ð3/ðj
˜d 3¨ 8™nô 
ð(  $ s¨C x¡.ð  °Tô  ð óó ðð óó ðñ ¨$Ñ/óó 0ðñ ¨$Ñ/ó	ó 0ð	ð ð	�e˜H c˜MÑ*ó 	ó ð	ð 
‡[�[ð2�e˜H c˜MÑ*ð 2¨tó 2ó ð2ð ð	˜˜S (˜]Ñ+ó 	ó ð	ð ‡]�]ð0˜˜S (˜]Ñ+ð 0°ó 0ó ð0ð ð.  f¡ó .ó ð.ñ ¨$Ñ/ð ˜cð  ¨ð  °Tó  ó 0ð ñ ¨$Ñ/ð/˜cð /¨ð /°Tó /ó 0ð/ñ4 ¨$Ñ/ð
0 ð 
0¨(ð 
0°tó 
0ó 0ð
0ð ð2˜X c™]ó 2ó ð2ð ×Ñð) ¨#¡ð )°4ó )ó ð)ð˜#ô ð
 ð+ Vð +°ó +ó ð+ñ0 ¨$Ñ/ð 26Ø59ð^ð
 ).ò^à# D¨¡IÑ.ð^ð  (¨¨S©	Ñ2ð^ð
 "&ð^ð 
�#‰õ^ó 0ð^ñ@ ¨$Ñ/ð >Bð,ð
  %ò,àð,ð ! ¨6¨(°D¨.Ñ!9Ñ:ð,ð
 ð,ð 
ˆf‰õ,ó 0ð,ñ\ ¨%Ñ0ñ, tð ,°tô ,ó 1ð,ñ\ ¨%Ñ0ð +/Ø04Ø-2ñ7à�h‰h�o‰oð7ð ˜E #™JÑ'ð7ð ˜d 3¨ 8™nÑ-ð	7ð
 '+ð7ð 
�.Ñ	!ô7ó 1ð7ñr ¨$Ñ/ó7ó 0ð7ð$? ð ?¨ô ?ð= ð =¨Cð =°D÷ =ò =r6   rq   c                 óN   • [        U5      (       d  [        S5      e[        X5      $ )z©
Apply fn recursively to each Node appearing in arg.

arg may be a list, tuple, slice, or dict with string keys: the return value will
have the same type and structure.
z.torch.fx.map_arg(a, fn): fn must be a callable)r    r¤   r   ©rq   r1   s     r5   r   r   z  s$   € ô �B�<‰<ÜÐMÓNÐNÜ�qÓÐr6   c                 ó   • [        X5      $ )z«
Apply fn recursively to each object appearing in arg.

arg may be a list, tuple, slice, or dict with string keys: the return value will
have the same type and structure.
)r   rL  s     r5   r   r   ‡  s   € ô ˜QÓ#Ð#r6   )krF   r[   ÚloggingÚoperatorrJ   ÚtypingÚcollections.abcr   r   r   r   r   r   r	   r
   r   Útyping_extensionsr   r   r;   Útorch._Cr   r   r   Útorch.fx.operator_schemasr   r   r   Útorch.utils._dtype_abbrsr   Ú_opsr   Ú_compatibilityr   r”   r   Ú__all__Ú	getLoggerr9   ÚlogrŒ   rE  ÚfloatrG  Úcomplexr   rY   rÿ   Úmemory_formatrû   Ú
OpOverloadÚSymIntÚSymBoolÚSymFloatÚBaseArgumentTypesÚget_argsÚ
base_typesr   rB  r‰   ÚsliceÚranger    r!   r#   r$   rŠ   Úfromkeysr£   Ú_CÚ_set_grad_enabledÚampÚ_enter_autocastÚ_exit_autocastr,   r…   Ú_assertÚ_assert_asyncÚatenÚmsgÚ_assert_scalarÚdefaultÚ_assert_tensor_metadataÚsym_constrain_rangeÚsym_constrain_range_for_sizeÚprofilerÚ_record_function_enterÚ_record_function_enter_newÚ_record_function_exitÚ_RecordFunctionÚinductorÚaccumulate_grad_Úsetitemr-   Úsetr„   r4   r.   r   rC   r;  rO   rc   rm   r   r   r   © r6   r5   Ú<module>r€     s7  ðä Û Û Û Û Û ß AÓ Aß AÕ Aß 0ã ß >Ñ >÷ñ õ
 1å Ý )ö Ýâ
A€à×Ò˜Ó!€àØØØ	ØØØ	‡K�KØ	‡L�LØ	‡L�LØ	×ÑØ	‡L�LØ	‡J�J×ÑØ	‡L�LØ	‡M�MØ	‡N�NðñÐ ð  �_Š_Ð.Ó/€
à˜( 3¨ 8Ñ,¨cÐ1Ñ2€ˆ	Ó 2àØ	ØˆoÑØ�ÑØ��Z�Ñ ØØØØð	ññ
€ñ �K xÑ0€	Ùˆtƒ_€ÙˆTƒ]€à�]‰]òó
€
ð  
‡H�H×ÑØ	‡I�I×ÑØ	‡I�I×ÑðOÐ 1°4¸ÀÀcÀÑ8JÑ3Kó ð" 
‡M�MØ	×ÑØ‡I�I×Ñ×ÑØ‡I�I×Ñ×$Ñ$Ø‡I�I×%Ñ%×-Ñ-Ø‡I�I×!Ñ!×)Ñ)Ø‡I�I×*Ñ*×2Ñ2Ø‡M�M×(Ñ(Ø‡M�M×(Ñ(×0Ñ0Ø‡M�M×,Ñ,Ø‡M�M×,Ñ,×4Ñ4Ø‡M�M×'Ñ'Ø‡M�M×'Ñ'×7Ñ7Ø‡M�M×"Ñ"×*Ñ*Ø×Ñð6ð  7ð!6Ð ˜3˜x¨¨S¨Ñ1Ñ2ó ñ& ˆ4�=‰=Ð1×2Ñ2Ø×!Ñ! $§-¡-×"EÑ"E×"MÑ"MÔNñ  eÑ,ð˜  R Ñ(ð ¨X°b¸"°fÑ-=ó ó -ðð$@¨°°c°Ñ(:ð @¸sô @ð�Fð ˜sô ð(˜h s¨C xÑ0ð °Sô ñ@ 49¸³<ñ �Vð ¨5ð ÀCõ ñ<  dÑ+ôJ
=ˆ9ó J
=ó ,ðJ
=ñZ  dÑ+ð	ˆyð 	˜h¨ v¨xÐ'7Ñ8ð 	¸Yó 	ó ,ð	ñ  dÑ+ð$�Yð $ H¨h¨Z¸Ð-AÑ$Bð $Àyó $ó ,ñ$r6   