
    '}h                     4    d Z ddlZddlZddlZdededefdZy)z"Utility for deprecating functions.    Nsince
removed_ininstructionsc                       fd}|S )aF  Marks functions as deprecated.

    It will result in a warning when the function is called and a note in the
    docstring.

    Args:
        since: The version when the function was first deprecated.
        removed_in: The version when the function will be removed.
        instructions: The action users should take.
    c           	      j    t        j                          	
fd       } j                  xs d}t        j                  d
 d	 d d      }|j                  dd      }t        |      dkD  r!|\  }}t        j                  |      }|d||g}n
|d	   }|d|g}dj                  |      |_        |S )
Nc                      t        j                  dj                   dj                   d d d dt        d        | i |S )N'.z' is deprecated in version z and will be removed in z	. Please    )category
stacklevel)warningswarn
__module____name__FutureWarning)argskwargsfunctionr   r   r   s     V/var/www/html/test/engine/venv/lib/python3.12/site-packages/torch/onnx/_deprecation.pywrapperz.deprecated.<locals>.decorator.<locals>.wrapper   sf    MMH''((*;*;)< =,,17 3(\<.C ' T,V,,     z            .. deprecated:: z;
                Deprecated and will be removed in version z.
                Please z.
            z

   r   )	functoolswraps__doc__textwrapdedentsplitlenjoin)r   r   	docstringdeprecation_notesummary_and_bodysummarybodynew_docstring_partsr   r   r   s   `       r   	decoratorzdeprecated.<locals>.decorator   s    		"	- 
#	- $$*	 $??"G $;;E, G$~ &
 %??615 1$,MGT ??4(D#3VWd"K&q)G#3VW"E''"56r    )r   r   r   r)   s   ``` r   
deprecatedr+      s    *X r   )r   r   r   r   strr+   r*   r   r   <module>r-      s+    (   8c 8s 8# 8r   