+
    –°³jê  ã                   ó¸   € ^ RI Ht ^ RIt^ RIHt ^ RIHt . ROt ! R R]P                  4      t ! R	 R]P                  4      t	 ! R
 R]P                  4      t
R# )é    ©ÚAnyN)Únn©ÚQConfigÚ	QuantStubÚDeQuantStubÚQuantWrapperc                   óX   a a€ ] tR t^t oRtRV3R lV 3R llltV3R lR ltRtVtV ;t	# )r   a  Quantize stub module, before calibration, this is same as an observer,
it will be swapped as `nnq.Quantize` in `convert`.

Args:
    qconfig: quantization configuration for the tensor,
        if qconfig is not provided, we will get qconfig from parent modules
c                ó.   <€ V ^8„  d   QhRS[ R,          /# ©é   ÚqconfigNr   )ÚformatÚ__classdict__s   "€Ú\/home/luca/screen-checking/.venv/lib/python3.14/site-packages/torch/ao/quantization/stubs.pyÚ__annotate__ÚQuantStub.__annotate__   s   ø€ ÷ #ñ #¡¨$¥ñ #ó    c                óD   <€ \         SV `  4        V'       d	   Wn        R # R # ©N©ÚsuperÚ__init__r   ©Úselfr   Ú	__class__s   &&€r   r   ÚQuantStub.__init__   ó   ø€ Ü‰ÑÔßØ"ŽLñ r   c                óN   <€ V ^8„  d   QhRS[ P                  RS[ P                  /# ©r   ÚxÚreturn©ÚtorchÚTensor)r   r   s   "€r   r   r      ó#   ø€ ÷ ñ ™Ÿ™ð ©%¯,©,ñ r   c                ó   € V# r   © ©r   r"   s   &&r   ÚforwardÚQuantStub.forward   ó   € Øˆr   ©r   r   ©
Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r+   Ú__static_attributes__Ú__classdictcell__Ú__classcell__©r   r   s   @@r   r   r      ó#   ù‡ € ñ÷#õ #÷
÷ ð r   c                   óX   a a€ ] tR t^t oRtRV3R lV 3R llltV3R lR ltRtVtV ;t	# )r	   a  Dequantize stub module, before calibration, this is same as identity,
this will be swapped as `nnq.DeQuantize` in `convert`.

Args:
    qconfig: quantization configuration for the tensor,
        if qconfig is not provided, we will get qconfig from parent modules
c                ó.   <€ V ^8„  d   QhRS[ R,          /# r   r   )r   r   s   "€r   r   ÚDeQuantStub.__annotate__&   s   ø€ ÷ #ñ #¡ d¥
ñ #r   c                óD   <€ \         SV `  4        V'       d	   Wn        R # R # r   r   r   s   &&€r   r   ÚDeQuantStub.__init__&   r   r   c                óN   <€ V ^8„  d   QhRS[ P                  RS[ P                  /# r!   r$   )r   r   s   "€r   r   r<   +   r'   r   c                ó   € V# r   r)   r*   s   &&r   r+   ÚDeQuantStub.forward+   r-   r   r.   r   r/   r8   s   @@r   r	   r	      r9   r   c                   ó`   a a€ ] tR t^/t oRtV3R lV 3R lltV3R lR ltV3R ltRtVt	V ;t
# )r
   aÇ  A wrapper class that wraps the input module, adds QuantStub and
DeQuantStub and surround the call to module with call to quant and dequant
modules.

This is used by the `quantization` utility functions to add the quant and
dequant modules, before `convert` function `QuantStub` will just be observer,
it observes the input tensor, after `convert`, `QuantStub`
will be swapped to `nnq.Quantize` which does actual quantization. Similarly
for `DeQuantStub`.
c                ó4   <€ V ^8„  d   QhRS[ P                  /# )r   Úmodule)r   ÚModule)r   r   s   "€r   r   ÚQuantWrapper.__annotate__?   s   ø€ ÷ $ñ $™rŸy™yñ $r   c                ó  <€ \         SV `  4        \        VR R4      pV P                  R\	        V4      4       V P                  R\        V4      4       V P                  RV4       V P                  VP                  4       R# )r   NÚquantÚdequantrD   )r   r   ÚgetattrÚ
add_moduler   r	   ÚtrainÚtraining)r   rD   r   r   s   && €r   r   ÚQuantWrapper.__init__?   s`   ø€ Ü‰ÑÔÜ˜& )¨TÓ2ˆØ�‰˜¤¨7Ó!3Ô4Ø�‰˜	¤;¨wÓ#7Ô8Ø�‰˜ &Ô)Ø�
‰
�6—?‘?Ö#r   c                óN   <€ V ^8„  d   QhRS[ P                  RS[ P                  /# )r   ÚXr#   r$   )r   r   s   "€r   r   rF   G   s#   ø€ ÷ ñ ™Ÿ™ð ©%¯,©,ñ r   c                óh   € V P                  V4      pV P                  V4      pV P                  V4      # r   )rH   rD   rI   )r   rP   s   &&r   r+   ÚQuantWrapper.forwardG   s*   € Ø�J‰J�q‹MˆØ�K‰K˜‹NˆØ�|‰|˜A‹Ðr   c                óR   <€ V ^8„  d   Qh/ S[ ;R&   S[;R&   S[P                  ;R&   # )r   rH   rI   rD   )r   r	   r   rE   )r   r   s   "€r   r   rF   /   s0   ø‡ ‚ ñ Ññ ñ Ññ ñ �I‰IÑò r   r)   )r0   r1   r2   r3   r4   r   r+   Ú__annotate_func__r5   r6   r7   r8   s   @@r   r
   r
   /   s%   ù‡ € ñ	÷$ó $÷ð ÷1 … r   )r   r	   r
   )Útypingr   r%   r   Útorch.ao.quantizationr   Ú__all__rE   r   r	   r
   r)   r   r   Ú<module>rX      sH   ðÝ ã Ý Ý )ò 7€ô�—	‘	ô ô$�"—)‘)ô ô$�2—9‘9ö r   