
    NgH                     J    d dl Zd dlZd dlmZ d dlmZ  G d de          ZdS )    N)Base)expectc                   F   e Zd Zedd            Zedd            Zedd            Zedd            Zedd            Zedd            Z	edd	            Z
edd
            Zedd            Zedd            Zedd            Zedd            Zedd            ZdS )ModreturnNc                  t   t           j                            dddgdgd          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	
           d S )Nr   xyz   inputsoutputsfmodg333333g@      @g333333@g       @g @g333333r   g g333333@r   test_mod_mixed_sign_float64r   r   name)	onnxhelper	make_nodenparrayastypefloat64r   r   noder	   r
   r   s       [/var/www/html/ai-engine/env/lib/python3.11/site-packages/onnx/backend/test/case/node/mod.pyexport_mod_mixed_sign_float64z!Mod.export_mod_mixed_sign_float64   s    {$$UC:uST$UUH55566==bjIIH55566==bjIIGAqMMtQFQC6STTTTTT    c                  t   t           j                            dddgdgd          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	
           d S )Nr   r	   r
   r   r   r   r   r   test_mod_mixed_sign_float32r   )	r   r   r   r   r   r   float32r   r   r   s       r!   export_mod_mixed_sign_float32z!Mod.export_mod_mixed_sign_float32       {$$UC:uST$UUH55566==bjIIH55566==bjIIGq
 
 	tQFQC6STTTTTTr#   c                  t   t           j                            dddgdgd          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	
           d S )Nr   r	   r
   r   r   r   r   r   test_mod_mixed_sign_float16r   )	r   r   r   r   r   r   float16r   r   r   s       r!   export_mod_mixed_sign_float16z!Mod.export_mod_mixed_sign_float16!   r(   r#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r   r            i      r4      r2   test_mod_mixed_sign_int64r   )	r   r   r   r   r   r   int64modr   r   s       r!   export_mod_mixed_sign_int64zMod.export_mod_mixed_sign_int64,       {$$:E % 
 
 H)))**11"(;;H)))**11"(;;F1aLLtQFQC6QRRRRRRr#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r.   r/   r5   test_mod_mixed_sign_int32r   )	r   r   r   r   r   r   int32r<   r   r   s       r!   export_mod_mixed_sign_int32zMod.export_mod_mixed_sign_int329   r>   r#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r.   r/   r5   test_mod_mixed_sign_int16r   )	r   r   r   r   r   r   int16r<   r   r   s       r!   export_mod_mixed_sign_int16zMod.export_mod_mixed_sign_int16F   r>   r#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r.   r/   r5   test_mod_mixed_sign_int8r   )	r   r   r   r   r   r   int8r<   r   r   s       r!   export_mod_mixed_sign_int8zMod.export_mod_mixed_sign_int8S   s    {$$:E % 
 
 H)))**11"'::H)))**11"'::F1aLLtQFQC6PQQQQQQr#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r.   r3   r1   r2   r6   r9   r4   test_mod_uint8r   )	r   r   r   r   r   r   uint8r<   r   r   s       r!   export_mod_uint8zMod.export_mod_uint8`   s    {$$:E % 
 
 HYYY&&rx00HYYY&&rx00F1aLLtQFQC6FGGGGGGr#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r.   rL   rM   test_mod_uint16r   )	r   r   r   r   r   r   uint16r<   r   r   s       r!   export_mod_uint16zMod.export_mod_uint16m       {$$:E % 
 
 HYYY&&ry11HYYY&&ry11F1aLLtQFQC6GHHHHHHr#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r.   rL   rM   test_mod_uint32r   )	r   r   r   r   r   r   uint32r<   r   r   s       r!   export_mod_uint32zMod.export_mod_uint32z   rU   r#   c                  r   t           j                            dddgdg          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	           d S )
Nr   r	   r
   r   r.   rL   rM   test_mod_uint64r   )	r   r   r   r   r   r   uint64r<   r   r   s       r!   export_mod_uint64zMod.export_mod_uint64   rU   r#   c                  t   t           j                            dddgdgd          } t          j        g d                              t          j                  }t          j        g d                              t          j                  }t          j        ||          }t          | ||g|gd	
           d S )Nr   r	   r
   r   r   r   r/   r5   test_mod_int64_fmodr   )	r   r   r   r   r   r   r;   r   r   r   s       r!   export_mod_int64_fmodzMod.export_mod_int64_fmod   s    {$$UC:uST$UUH)))**11"(;;H)))**11"(;;GAqMMtQFQC6KLLLLLLr#   c                     t           j                            dddgdg          } t          j        dd                              g d                              t          j                  }t          j        d	g                              t          j                  }t          j	        ||          }t          | ||g|gd
           d S )Nr   r	   r
   r   r.   r      )r9   r6   r2   r1   test_mod_broadcastr   )r   r   r   r   arangereshaper   rA   r   r<   r   r   s       r!   export_mod_broadcastzMod.export_mod_broadcast   s    {$$:E % 
 
 Ia$$YYY//66rx@@HaSMM  **F1aLL 	tQFQC6JKKKKKKr#   )r   N)__name__
__module____qualname__staticmethodr"   r'   r,   r=   rB   rF   rJ   rP   rT   rY   r]   r`   rf    r#   r!   r   r      s       U U U \U U U U \U U U U \U 
S 
S 
S \
S 
S 
S 
S \
S 
S 
S 
S \
S 
R 
R 
R \
R 
H 
H 
H \
H 
I 
I 
I \
I 
I 
I 
I \
I 
I 
I 
I \
I M M M \M L L L \L L Lr#   r   )numpyr   r   onnx.backend.test.case.baser   onnx.backend.test.case.noder   r   rk   r#   r!   <module>ro      s   
      , , , , , , . . . . . .dL dL dL dL dL$ dL dL dL dL dLr#   