
    bIg0                    T    d dl mZ d dlZd dlZd dlmZ d dlmZ d Z	 G d de      Z
y)    )annotationsN)Base)expectc                d    t        j                  | |      j                  | j                        }|S )N)nppowerastypedtype)xyzs      \/var/www/html/answerous/venv/lib/python3.12/site-packages/onnx/backend/test/case/node/pow.pypowr      s%    
Aagg&AH    c                  B    e Zd Zedd       Zedd       Zedd       Zy)Powc                    t         j                  j                  dddgdg      } t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       t        j                  d
      j                  ddd      j                  t        j                        }t        j                  j                  ddd      j                  t        j                        }t        ||      }t        | ||g|gd	       y )Nr   r   r   r   inputsoutputs                  test_pow_exampler   r   name<   r   r   r   test_pow)onnxhelper	make_noder   arrayr	   float32r   r   arangereshaperandomrandnnoder   r   r   s       r   exportz
Pow.export   s    {{$$:E % 
 HHY&&rzz2HHY&&rzz21ItQFQC6HIIIbM!!!Q*11"**=IIOOAq!$++BJJ71ItQFQCjAr   c                    t         j                  j                  dddgdg      } t        j                  g d      j                  t        j                        }t        j                  d      j                  t        j                        }t        ||      }t        | ||g|gd	       t         j                  j                  dddgdg      } t        j                  g dg d
g      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       y )Nr   r   r   r   r   r   r   test_pow_bcast_scalarr    r   test_pow_bcast_array)	r$   r%   r&   r   r'   r	   r(   r   r   r-   s       r   export_pow_broadcastzPow.export_pow_broadcast%   s   {{$$:E % 
 HHY&&rzz2HHQKrzz*1ItQFQC6MN{{$$:E % 

 HHi+,33BJJ?HHY&&rzz21ItQFQC6LMr   c                    t         j                  j                  dddgdg      } t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd
	       t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       t        j                  g d      j                  t        j                        }t        j                  g d      j                  t        j                        }t        ||      }t        | ||g|gd	       y )Nr   r   r   r   r   r   r   test_pow_types_float32_int64r    test_pow_types_int64_float32test_pow_types_float32_int32test_pow_types_int32_float32test_pow_types_float32_uint64test_pow_types_float32_uint32test_pow_types_int64_int64test_pow_types_int32_int32)r$   r%   r&   r   r'   r	   r(   int64r   r   int32uint64uint32r-   s       r   export_typeszPow.export_types=   s   {{$$:E % 
 HHY&&rzz2HHY&&rxx01ItQFQC6TUHHY&&rxx0HHY&&rzz21ItQFQC6TUHHY&&rzz2HHY&&rxx01ItQFQC6TUHHY&&rxx0HHY&&rzz21ItQFQC6TUHHY&&rzz2HHY&&ryy11ItQFQC6UVHHY&&rzz2HHY&&ryy11ItQFQC6UVHHY&&rxx0HHY&&rxx01ItQFQC6RSHHY&&rxx0HHY&&rxx01ItQFQC6RSr   N)returnNone)__name__
__module____qualname__staticmethodr/   r3   rA    r   r   r   r      sB    B B" N N. -T -Tr   r   )
__future__r   numpyr   r$   onnx.backend.test.case.baser   onnx.backend.test.case.noder   r   r   rH   r   r   <module>rM      s+    #   , .
YT$ YTr   