U
    9%e+                     @   s   d Z ddlZddlZddlmZmZ ddlmZm	Z	 ej
e	jddZdZeddejd	d
dZeddejd	ddZeD ]Zede ee qdS )a'  
Note [ONNX operators that are added/updated from opset 7 to opset 8]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
New operators:
  Expand

Updated operators:
  Min, Max, Sum, Mean: supports multidirectional broadcasting.
  MaxPool: added optional indices output.
  Scan
    N)symbolic_helpersymbolic_opset9)	jit_utilsregistration   )Zopset)
scanexpandZ	expand_asZmeshgridZadaptive_max_pool1dZadaptive_max_pool2dZadaptive_max_pool3dZmax_pool1d_with_indicesZmax_pool2d_with_indicesZmax_pool3d_with_indicesz	aten::max)gc                 C   s*   |d kr|d k	rt d t| |||S )NzMultidirectional broadcasting is not supported in opset 7. This might cause the onnx model to be incorrect, if inputs to max operators have different shapes)warningswarnopset9maxr	   selfZdim_or_yZkeepdim r   Y/var/www/html/Darija-Ai-API/env/lib/python3.8/site-packages/torch/onnx/symbolic_opset7.pyr   '   s
    r   z	aten::minc                 C   s*   |d kr|d k	rt d t| |||S )NzMultidirectional broadcasting is not supported in opset 7. This might cause the onnx model to be incorrect, if inputs to min operators have different shapes)r
   r   r   minr   r   r   r   r   3   s
    r   zaten::)NN)NN)__doc__	functoolsr
   Z
torch.onnxr   r   r   Ztorch.onnx._internalr   r   partialZonnx_symbolicZ_onnx_symbolicZblock_listed_operatorsZGraphContextr   r   Zblock_listed_opZ_block_list_in_opsetr   r   r   r   <module>   s   