
    hs                     B    S SK rS SKrS SKJr  S SKJr   " S S\5      rg)    N)Base)expectc                       \ rS rSr\SS j5       r\SS j5       r\SS j5       r\SS j5       r\SS j5       r	\SS j5       r
\SS	 j5       r\SS
 j5       rSrg)Slice   Nc                      [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      nUSS	2SS24   n[        R                  " SS/[        R                  S
9n[        R                  " S	S/[        R                  S
9n[        R                  " SS/[        R                  S
9n[        R                  " SS/[        R                  S
9n[        XX4XV/U/SS9  g )Nr   xstartsendsaxesstepsyinputsoutputs   
      r      dtype   
test_slicer   r   nameonnxhelper	make_nodenprandomrandnastypefloat32arrayint64r   )noder
   r   r   r   r   r   s          [/var/www/fran/franai/venv/lib/python3.13/site-packages/onnx/backend/test/case/node/slice.pyexport_sliceSlice.export_slice   s    {{$$;E % 
 IIOOBA&--bjj9ac1R4iL1a&1xxBrxx0xxAbhh/!Qrxx0V47!<	
    c                     [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      n[        R                  " S/[        R                  S	9n[        R                  " S
/[        R                  S	9n[        R                  " S/[        R                  S	9n[        R                  " S/[        R                  S	9nUS S 2SS
24   n[        U XX4U/U/SS9  g )Nr   r	   r   r   r   r   r   r   r   r   test_slice_negr   r   r(   r
   r   r   r   r   r   s          r)   export_slice_negSlice.export_slice_neg    s    {{$$;E % 
 IIOOBA&--bjj91#RXX.xxBHH-xx288,!BHH-a2gJt51C!		
r,   c                     [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      n[        R                  " S/[        R                  S	9n[        R                  " S/[        R                  S	9n[        R                  " S
/[        R                  S	9n[        R                  " S
/[        R                  S	9nUS S 2SS24   n[        U XX4U/U/SS9  g )Nr   r	   r   r   r   r   r     r   r   test_slice_start_out_of_boundsr   r   r0   s          r)    export_slice_start_out_of_bounds&Slice.export_slice_start_out_of_bounds6   s    {{$$;E % 
 IIOOBA&--bjj94&1xxbhh/xx288,!BHH-adlOt51C1		
r,   c                     [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      n[        R                  " S/[        R                  S	9n[        R                  " S
/[        R                  S	9n[        R                  " S/[        R                  S	9n[        R                  " S/[        R                  S	9nUS S 2SS
24   n[        U XX4U/U/SS9  g )Nr   r	   r   r   r   r   r   r   r   r4   test_slice_end_out_of_boundsr   r   r0   s          r)   export_slice_end_out_of_bounds$Slice.export_slice_end_out_of_boundsL   s    {{$$;E % 
 IIOOBA&--bjj91#RXX.xxbhh/xx288,!BHH-a4iLt51C/		
r,   c                     [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      n[        R                  " / SQ[        R                  S	9n[        R                  " / S
Q[        R                  S	9nUS S 2S S 2SS24   n[        XX#/U/SS9  g )Nr   )r
   r   r   r   r   r   r   r   r   r   r   r   r   r      r   r?   test_slice_default_axesr   r   )r(   r
   r   r   r   s        r)   export_slice_default_axesSlice.export_slice_default_axesb   s    {{$$*E % 
 IIOOBA&--bjj9)2884xx2884aAaCiLV*QC>W	
r,   c                     [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      n[        R                  " / SQ[        R                  S	9n[        R                  " / S
Q[        R                  S	9n[        R                  " / SQ[        R                  S	9nUS S 2S S 2SS24   n[        U XX4/U/SS9  g )Nr   r
   r   r   r   r   r   r   r   r   r=   r   r>   r   r      r   r?   test_slice_default_stepsr   r   r(   r
   r   r   r   r   s         r)   export_slice_default_steps Slice.export_slice_default_stepss   s    {{$$2E % 
 IIOOBA&--bjj9)2884xx2884xx	2aAaCiLt*C+		
r,   c                  N   [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      n[        R                  " / SQ[        R                  S	9n[        R                  " / S
Q[        R                  S	9n[        R                  " / SQ[        R                  S	9n[        R                  " / SQ5      R                  [        R                  5      nUSSS2SSS2SSS24   n[        U XX4U/U/SS9  g )Nr   r	   r   r   r   r   r   r>   r   )r   r   r   rE   )r.   r   r.   rL   r?   r   rM   test_slice_neg_stepsr   r   r0   s          r)   export_slice_neg_stepsSlice.export_slice_neg_steps   s    {{$$;E % 
 IIOOBA&--bjj9+RXX6xx	2xx	2&--bhh7b2gr!Bw!B&'t51C'		
r,   c                     [         R                  R                  S/ SQS/S9n [        R                  R                  SSS5      R                  [        R                  5      n[        R                  " / SQ[        R                  S	9n[        R                  " / S
Q[        R                  S	9n[        R                  " / SQ[        R                  S	9nUS S 2S S 2SS24   n[        U XX4/U/SS9  g )Nr   rD   r   r   r   r   r   r=   r   r>   )r   rM   r.   r   r?   test_slice_negative_axesr   r   rH   s         r)   export_slice_negative_axes Slice.export_slice_negative_axes   s    {{$$2E % 
 IIOOBA&--bjj9)2884xx2884xx2884aAaCiLt*C+		
r,    )returnN)__name__
__module____qualname____firstlineno__staticmethodr*   r1   r6   r:   rA   rI   rO   rS   __static_attributes__rU   r,   r)   r   r      s    
 
$ 
 
* 
 
* 
 
* 
 
  
 
( 
 
* 
 
r,   r   )numpyr!   r   onnx.backend.test.case.baser   onnx.backend.test.case.noder   r   rU   r,   r)   <module>r`      s!   
   , .e
D e
r,   