+
    iN                       ^ RI t ^ RIt^ RIt^ RIt^ RIt^ RIt^ RIHt ^ RIH	t	H
t
 ^ RIHtHtHtHtHtHtHtHtHt RR@RRARRBRRAR	^]P*                  ! ^4      R
,          3RRCRRDRRE/t]P.                  ! ]P0                  4      P2                  RF8  d   RRRRRRRRR	RRRRRRR/tMRRRRRRRRR	RRRRRRR/t]P6                  ! R]R7      R  4       t]P6                  R! 4       tR" t ! R# R$4      t ! R% R&4      t  ! R' R(4      t! ! R) R*4      t" ! R+ R,4      t# ! R- R.4      t$ ! R/ R04      t%]PL                  PO                  ]R1R27       ! R3 R44      4       t( ! R5 R64      t)R7 t*R8 t+R9 t,R: t-R; t.R< t/R= t0R> t1R? t2R# )G    N)random)MT19937PCG64)	IS_WASMassert_assert_array_almost_equalassert_array_equalassert_equalassert_no_warningsassert_raisesassert_warnssuppress_warningsbinomial	geometrichypergeometric	logseriesmultinomialg      @negative_binomialpoissonzipf@2fbead005fc63942decb5326d36a1f32fe2c9d32c904ee61e46866b88447c263@23ead5dcde35d4cfd4ef2c105e4c3d43304b45dc1b1444b7823b9ee4fa144ebb@0d764db64f5c3bad48c8c33551c13b4d07a1e7b470f77629bef6c985cac76fcf@7b59bf2f1691626c5815cdcd9a49e1dd68697251d4521575219e4d2a1b8b2c67@d754fa5b92943a38ec07630de92362dd2e02c43577fc147417dc5b9db94ccdd3@8eb216f7cb2a63cf55605422845caaff002fddc64a7dc8b2d45acd477a49e824@70c891d76104013ebd6f6bcf30d403a9074b886ff62e4e6b8eb605bf1a4673b7@01f074f97517cd5d21747148ac6ca4074dde7fcb7acbaec0a936606fecacd93f@8626dd9d052cb608e93d8868de0a7b347258b199493871a1dc56e2a26cacb112@8edd53d272e49c4fc8fbbe6c7d08d563d62e482921f3131d0a0e068af30f0db9@83496cc4281c77b786c9b7ad88b74d42e01603a55c60577ebab81c3ba8d45657@65878a38747c176bc00e930ebafebb69d4e1e16cd3a704e264ea8f5e24f548db@7a984ae6dca26fd25374479e118b22f55db0aedccd5a0f2584ceada33db98605@d636d968e6a24ae92ab52fe11c46ac45b0897e98714426764e820a7d77602a61@956552176f77e7c9cb20d0118fc9cf690be488d790ed4b4c4747b965e61b0bb4@f84ba7feffda41e606e20b28dfc0f1ea9964a74574513d4a4cbc98433a8bfa45module)scopeparamsc                 t    V P                   \        V P                   ,          \        V P                   ,          3# N)param	INT_FUNCSINT_FUNC_HASHES)requests   &E/usr/lib/python3/dist-packages/numpy/random/tests/test_randomstate.pyint_funcr1   8   s*    MM9W]]3GMM*, ,    c               #     "   \         P                  P                  4       p Rx  \         P                  P                  V 4       R# 5i)z:Ensures that the singleton bitgen is restored after a testN)npr   get_bit_generatorset_bit_generator)orig_bitgens    r0   restore_singleton_bitgenr8   >   s.      ))--/K	II,s   AAc                 B   \        V R ,          VR ,          4       \        V R,          R,          VR,          R,          4       \        V R,          R,          VR,          R,          4       \        V R,          VR,          4       \        V R,          VR,          4       R# )bit_generatorstatekeypos	has_gaussgaussN)r
   r	   abs   &&r0   assert_mt19937_state_equalrC   F   sr    ?#Q%78qz%(!G*U*;<qz%(!G*U*;<;;07QwZ(r2   c                   J   a  ] tR t^Nt o R tR tR tR tR tR t	R t
RtV tR	# )
TestSeedc                    \         P                  ! ^ 4      p\        VP                  R4      R4       \         P                  ! R4      p\        VP                  R4      R4       R# )r     i      i  N)r   RandomStater
   randintselfss   & r0   test_scalarTestSeed.test_scalarO   sF    q!QYYt_c*z*QYYt_c*r2   c                   \         P                  ! \        ^
4      4      p\        VP	                  R4      R4       \         P                  ! \
        P                  ! ^
4      4      p\        VP	                  R4      R4       \         P                  ! ^ .4      p\        VP	                  R4      R4       \         P                  ! R.4      p\        VP	                  R4      R4       R# )
   rG   i  i  rH   i	  N)r   rI   ranger
   rJ   r4   arangerK   s   & r0   
test_arrayTestSeed.test_arrayU   s    uRy)QYYt_c*ryy}-QYYt_c*s#QYYt_c*
|,QYYt_c*r2   c                    \        \        \        P                  R4       \        \        \        P                  R4       R# )      ?N      r   	TypeErrorr   rI   
ValueErrorrL   s   &r0   test_invalid_scalarTestSeed.test_invalid_scalar_   s&    i!3!3T:j&"4"4b9r2   c                J   \        \        \        P                  R.4       \        \        \        P                  R.4       \        \        \        P                  R.4       \        \        \        P                  . RO4       \        \        \        P                  . RO4       R# )rW           NrX   rY   )      ra   )rb   ra   rZ   r]   s   &r0   test_invalid_arrayTestSeed.test_invalid_arrayd   sd    i!3!3dV<j&"4"4rd;j&"4"4zlCj&"4"46HIj&"4"46IJr2   c           	        \        \        \        P                  \        P
                  ! . \        P                  R 7      4       \        \        \        P                  . RO.4       \        \        \        P                  . RO. RO.4       R# )dtypeNrb   rc      )         )r   r\   r   rI   r4   arrayint64r]   s   &r0   test_invalid_array_shape!TestSeed.test_invalid_array_shapel   s\    j&"4"4bhhrEGXX7O 	Pj&"4"4ykBj&"4"4y7@7B 	Cr2   c                    \         P                  ! \        ^ 4      4      p\        \        4      ;_uu_ 4        VP                  R4       RRR4       R#   + '       g   i     R# ; i)r     N)r   rI   r   r   r[   seed)rL   rss   & r0   test_cannot_seedTestSeed.test_cannot_seedt   s;    a)9%%GGDM &%%%s   AA$	c                L    \        \        \        P                  \        4       R # r+   )r   r\   r   rI   r   r]   s   &r0   test_invalid_initialization$TestSeed.test_invalid_initializationy   s    j&"4"4g>r2    N)__name__
__module____qualname____firstlineno__rN   rT   r^   re   rq   rw   rz   __static_attributes____classdictcell____classdict__s   @r0   rE   rE   N   s/     ++:
KC
? ?r2   rE   c                   ,   a  ] tR t^}t o R tR tRtV tR# )TestBinomialc                    \         P                  ! ^RR7      pR FF  p\        \        P                  ! ^ V4      ^ 8H  4       \        \        P                  ! W4      V4       KH  	  R# )rc   intrh   N)r   rW   rb   )r4   zerosr   r   r   r	   )rL   r   ps   &  r0   test_n_zeroTestBinomial.test_n_zero~   sI     %(AFOOAq)Q./vu8%@ r2   c                b    \        \        \        P                  ^\        P
                  4       R# )rb   N)r   r\   r   r   r4   nanr]   s   &r0   test_p_is_nanTestBinomial.test_p_is_nan   s    j&//1bff=r2   r|   N)r}   r~   r   r   r   r   r   r   r   s   @r0   r   r   }   s     A> >r2   r   c                   V   a  ] tR t^t o R tR tR tR tR tR t	R t
R tR	 tR
tV tR# )TestMultinomialc                8    \         P                  ! ^dRR.4       R# )d   皙?皙?Nr   r   r]   s   &r0   
test_basicTestMultinomial.test_basic   s    3c
+r2   c                8    \         P                  ! ^d. RO4       R# )r   N)r   r           r   r   r   r]   s   &r0   test_zero_probability%TestMultinomial.test_zero_probability   s    3 9:r2   c                &   \        R\        P                  ! RR4      u;8*  ;'       d    R8  Mu 4       \        P                  ! RR^4      p\        \        P                  ! RV8*  4      4       \        \        P                  ! VR8  4      4       R# )rm   NrY   )r   r   rJ   r4   allrL   xs   & r0   test_int_negative_interval*TestMultinomial.test_int_negative_interval   s\    fnnR,11r12NN2r1%rQw q2vr2   c           	        R R .p\        \        P                  ! ^V\        P                  ! ^4      4      P
                  R4       \        \        P                  ! ^V\        P                  ! ^4      4      P
                  R4       \        \        P                  ! ^V\        P                  ! ^4      4      P
                  R4       \        \        P                  ! ^V^^.4      P
                  R4       \        \        P                  ! ^VR4      P
                  R4       \        \        P                  ! ^V\        P                  ! R4      4      P
                  R4       \        \        \        P                  ^V\        ^4      4       R# )rW   Nrb   rc   rc   rc   rc   rc   rc   )
r
   r   r   r4   uint32shapero   r   r[   floatrL   r   s   & r0   	test_sizeTestMultinomial.test_size   s   #JV''1biil;AA6JV''1biil;AA6JV''1biil;AA6JV''1q!f5;;YGV''1f5;;YGV''1bhhv.>?EE	  	i!3!3QAh	 r2   c                    \        \        \        P                  ^dRR.4       \        \        \        P                  ^dRR.4       R# )r   皙?r   ?N皙r   r\   r   r   r]   s   &r0   test_invalid_prob!TestMultinomial.test_invalid_prob   s2    j&"4"4cC:Fj&"4"4cC:Fr2   c                J    \        \        \        P                  RRR.4       R# )rb   r   r   NrY   r   r]   s   &r0   test_invalid_nTestMultinomial.test_invalid_n   s    j&"4"4b3*Er2   c                   \         P                  ! R 4      pV\         P                  ! VR,          4      ,          pVR,          p\        P                  ! R4       \        P
                  ! ^dVR7      p\        P                  ! R4       \        P
                  ! ^d\         P                  ! V4      R7      p\        W44       R# )g      .@:rb   Nrk   i۠iU)pvalsN)r4   rS   sumr   ru   r   ascontiguousarrayr	   )rL   r   r   
non_contigcontigs   &    r0   test_p_non_contiguous%TestMultinomial.test_p_non_contiguous   s}    IIcN	RVVAdG_$J''59
J##Cr/C/CE/JK:.r2   c                6   \         P                  ! . RO\         P                  R7      pWP                  4       ,          pRp\        P
                  ! \        VR7      ;_uu_ 4        \        P                  ! ^V4       RRR4       R#   + '       g   i     R# ; i)Gz?rh   z-[\w\s]*pvals array is cast to 64-bit floatingmatchN)
r   r   &.>r   r   r   r   r   r   r   )	r4   ro   float32r   pytestraisesr\   r   r   )rL   r   r   r   s   &   r0   test_multinomial_pvals_float32.TestMultinomial.test_multinomial_pvals_float32   s_    HH :ACMEEG@]]:U33q%( 4333s   %BB	c                8    \         P                  ! R RR.4       R# )g      Y@r   r   Nr   r]   s   &r0   test_multinomial_n_float(TestMultinomial.test_multinomial_n_float   s    53*-r2   r|   N)r}   r~   r   r   r   r   r   r   r   r   r   r   r   r   r   r   s   @r0   r   r      s9     ,;  GF/). .r2   r   c                   b   a  ] tR t^t o R tR tR tR tR tR t	R t
R tR	 tR
 tR tRtV tR# )TestSetStatec                    R V n         \        P                  ! V P                   4      V n        V P                  P	                  4       V n        R# iIN)ru   r   rI   random_state	get_stater;   r]   s   &r0   setup_methodTestSetState.setup_method   s6    	"..tyy9&&002
r2   c                    V P                   P                  ^4      pV P                   P                  V P                  4       V P                   P                  ^4      p\	        \
        P                  ! W8H  4      4       R# )   N)r   tomaxint	set_stater;   r   r4   r   rL   oldnews   &  r0   r   TestSetState.test_basic   sY    ((,##DJJ/((,sz"#r2   c                   V P                   P                  ^R7      pV P                   P                  V P                  4       V P                   P                  ^R7      p\	        \
        P                  ! W8H  4      4       R# rk   sizeN)r   standard_normalr   r;   r   r4   r   r   s   &  r0   test_gaussian_reset TestSetState.test_gaussian_reset   s_    //Q/7##DJJ///Q/7sz"#r2   c                V   V P                   P                  4        V P                   P                  4       pV P                   P                  ^R7      pV P                   P                  V4       V P                   P                  ^R7      p\	        \
        P                  ! W#8H  4      4       R# r   )r   r   r   r   r   r4   r   )rL   r;   r   r   s   &   r0    test_gaussian_reset_in_media_res-TestSetState.test_gaussian_reset_in_media_res   s     	))+!!++-//Q/7##E*//Q/7sz"#r2   c                   V P                   R R pV P                  P                  ^R7      pV P                  P                  V4       V P                  P                  ^R7      pV P                  P                  V P                   4       V P                  P                  ^R7      p\	        \
        P                  ! W#8H  4      4       \	        \
        P                  ! W$8H  4      4       R # )Nr   rd   )r;   r   r   r   r   r4   r   )rL   	old_statex1x2x3s   &    r0   test_backwards_compatibility)TestSetState.test_backwards_compatibility   s     JJsO	..B.7##I...B.7##DJJ/..B.7rx !rx !r2   c                >    V P                   P                  R R 4       R# rW   N)r   r   r]   s   &r0   test_negative_binomial#TestSetState.test_negative_binomial   s     	++C5r2   c                j   \         P                  ! \        4       4      p\        4       ;_uu_ 4       pVP	                  \
        4      pVP                  4       p\        \        V4      ^8H  4       \        V\        4      '       g   Q hVR,          R8X  g   Q h RRR4       R#   + '       g   i     R# ; i)rb   r:   r   N)r   rI   r   r   recordRuntimeWarningr   r   len
isinstancedict)rL   rv   supwr;   s   &    r0   test_get_state_warning#TestSetState.test_get_state_warning   s}    (  C

>*ALLNECFaK eT****)W444 !   s   A%B!!B2	c           	        V P                   P                  4       pRVR,          ,           p\        \        V P                   P                  V4       \        \
        V P                   P                  \        P                  ! V\        R7      4       V P                   P                  RR7      pVR \        \        V P                   P                  V4       R# )Unknownrb   NNrh   Flegacyr:   N)r   )	r   r   r   r\   r   r[   r4   ro   object)rL   r;   	new_states   &  r0   !test_invalid_legacy_state_setting.TestSetState.test_invalid_legacy_state_setting   s    !!++-!E"I-	j$"3"3"="=yIi!2!2!<!<hhy7	9!!++5+9/"j$"3"3"="=uEr2   c                   V P                   P                  ^ 4       V P                   P                  ^d4       V P                   P                  4        V P                   P	                  RR7      p\        VR,          ^4       \        P                  ! \        P                  ! V P                   4      4      pVP	                  RR7      p\        W4       R# )r   Fr   r>   N)
r   ru   random_sampler   r   r
   pickleloadsdumpsrC   )rL   pickled	rs_unpick	unpickleds   &   r0   test_pickleTestSetState.test_pickle  s    q!'',))+##--U-;W[)1-LLd.?.?!@A	''u'5	"76r2   c                    V P                   P                  4       pV P                   P                  4        V P                   P                  V4       V P                   P	                  R R7      p\        W4       R# )Fr   N)r   __getstate__r   __setstate__r   rC   )rL   
attr_stater;   s   &  r0   test_state_settingTestSetState.test_state_setting  s]    &&335
))+&&z2!!++5+9":5r2   c                ^    \        V P                  4      P                  R 4      '       g   Q hR# )zRandomState(MT19937)N)reprr   
startswithr]   s   &r0   	test_reprTestSetState.test_repr  s%    D%%&112HIIIIr2   )r   ru   r;   N)r}   r~   r   r   r   r   r   r   r   r   r   r  r  r  r  r   r   r   s   @r0   r   r      sD     3
$$	$
"6
5F76J Jr2   r   c            	         a  ] tR tRt o ]P
                  t]P                  ]P                  ]P                  ]P                  ]P                  ]P                  ]P                  ]P                  ]P                   .	tR tR tR tR tR tR t]P2                  P5                  ]P6                  ! R4      P8                  R8  R	R
7      R 4       tR tR tRt V t!R# )TestRandinti  c                H    \        \        V P                  ^\        R7       R# rb   rh   N)r   r[   rfuncr   r]   s   &r0   test_unsupported_type!TestRandint.test_unsupported_type#  s    iQe<r2   c           	        V P                    F  pV\        P                  J d   ^ M\        P                  ! V4      P                  pV\        P                  J d   ^M&\        P                  ! V4      P
                  ^,           p\        \        V P                  V^,
          W1R7       \        \        V P                  W#^,           VR7       \        \        V P                  W2VR7       \        \        V P                  ^^ VR7       K  	  R# )r   rh   N)	ityper4   booliinfominmaxr   r\   r  )rL   dtlbndubnds   &   r0   test_bounds_checking TestRandint.test_bounds_checking&  s    **Bbgg1288B<+;+;Dbgg1288B<+;+;a+?D*djj$(DK*djj$qK*djj$BG*djj!QbA r2   c           
     (   V P                    EF   pV\        P                  J d   ^ M\        P                  ! V4      P                  pV\        P                  J d   ^M&\        P                  ! V4      P
                  ^,           pV^,
          p\        V P                  WD^,           RVR7      V4       Tp\        V P                  WD^,           RVR7      V4       W#,           ^,          p\        V P                  WD^,           RVR7      V4       EK  	  R# )r   rG   r   ri   N)r#  r4   r$  r%  r&  r'  r
   r  )rL   r(  r)  r*  tgts   &    r0   test_rng_zero_and_extremes&TestRandint.test_rng_zero_and_extremes/  s    **Bbgg1288B<+;+;Dbgg1288B<+;+;a+?D(CCqt2FLCCqt2FL;1$CCqt2FL r2   c                   V P                    F  pV\        P                  J d   ^ M\        P                  ! V4      P                  pV\        P                  J d   ^M&\        P                  ! V4      P
                  ^,           p V P                  W#VR7       K  	  R#   \         d!   p\        R\        T4      ,          4      hRp?ii ; i)r   rh   zMNo error should have been raised, but one was with the following message:

%sN)
r#  r4   r$  r%  r&  r'  r  	ExceptionAssertionErrorstr)rL   r(  r)  r*  es   &    r0   test_full_rangeTestRandint.test_full_range=  s     **Bbgg1288B<+;+;Dbgg1288B<+;+;a+?D@

4R
0   @$ &68;A&? @ @@s   BC(CCc           	        \         P                  ! 4        V P                  R ,           FY  pR FP  pV P                  ^VRVR7      p\	        VP                  4       V8  4       \	        VP                  4       ^8  4       KR  	  K[  	  V P                  ^ ^R\        P                  R7      p\	        VP                  4       ^8  4       \	        VP                  4       ^ 8  4       R# )r   r.  N)rl      r   i   )	r   ru   r#  r  r   r'  r&  r4   r$  )rL   r(  r*  valss   &   r0   test_in_bounds_fuzzTestRandint.test_in_bounds_fuzzK  s    **R..B"zz!TRz@
T)*
a( # ! zz!QU"''z:
Q
a r2   c                `   R RRRRRRRRR	R
RRRRRRR	/	pV P                   R,           F  p\        P                  ! R4       \        P                  R8X  d   V P                  ^ ^RVR7      pM#V P                  ^ ^RVR7      P                  4       p\        P                  ! VP                  \        P                  4      4      P                  4       p\        V\        P                  ! V4      P                  ,          V8H  4       K  	  \        P                  ! R4       V P                  ^ ^R\         R7      P                  \        P                  4      p\        P                  ! V4      P                  4       p\        V\        P                  ! \         4      P                  ,          V8H  4       R# )r$  @509aea74d792fb931784c4b0135392c65aec64beee12b0cc167548a2c3d31e71int16@7b07f1a920e46f6d0fe02314155a2330bcfd7635e708da50e536c5ebb631a7d4int32@e577bfed6c935de944424667e3da285012e741892dcb7051a8f1ce68ab05c92frp   @0fbead0b06759df2cfb55e43148822d4a1ff953c7eb19a5b08445a63bb64fa9eint8@001aac3a5acb935a9b186cbe14a1ca064b8bb2dd0b045d48abeacf74d0203404uint16r   uint64uint8r   rt   littlerG   r.  N)r#  r   ru   sys	byteorderr  byteswaphashlibsha256viewr4   rE  	hexdigestr   ri   namer$  )rL   r/  r(  valress   &    r0   test_repeatabilityTestRandint.test_repeatabilityZ  sU    [[[[[[[[[] **R..BKK }}(jjADj;jjADj;DDF.."''!23==?CC))*c12 ! 	DjjADj5::277CnnS!++-BHHTN''(C/0r2   lzCannot test with 32-bit C longreasonc           
     <   \         P                  ! . RO. RO. RO.. RO. RO. R	O.. R
O. RO. RO.. RO. RO. RO.. RO. RO. RO..4      pR FM  p\        P                  ! R4       V P	                  R.^ .^... ROVR7      p\        Y2e   TMV^ ,          4       KO  	  R# )   Q[ Ni90  r   )r[  l   dm" l   0 )l   ;i l   vlm l   iXp )i\L_l   ZN iwU')l   <~ l   20l iP?)ifiwLl   @
Vo )l   o\ iwi
1])i{YSl   r=| i)l   0 l   l i&})l   QZ) l   (q l   '}Q )l   WqV1 iMl   't )inMl   b" l   )  )ial    l   S"f )idi98l   nDk )l   Jc i-l    )iMi'*l   l, )N)rm   rk   rk   rY   )rH   ra   l       )r4   ro   r   ru   r  r	   )rL   desiredr   r   s   &   r0   .test_repeatability_32bit_boundary_broadcasting:TestRandint.test_repeatability_32bit_boundary_broadcastingz  s     ((AAAC BAAC BAAC BAAC BAACD E &DKK

RD1#s+-J $  &Aq-='71:N	 &r2   c                   \         P                  p\         P                  ! \         P                  4      P                  p\         P                  ! \         P                  ! \         P                  4      P                  4      p\         P                  ! \         P                  ! \         P                  4      P                  ^,           4      p\
        P                  ! W4VR7      p\        WR4       R# r  )r4   rp   r%  r'  rH  r   rJ   r
   )rL   r(  r/  r)  r*  actuals   &     r0   test_int64_uint64_corner_case)TestRandint.test_int64_uint64_corner_case  s     XXhhrxx $$xx*../yy"((+//!34 "5V!r2   c                   V P                    F  pV\        P                  J d   ^ M\        P                  ! V4      P                  pV\        P                  J d   ^M&\        P                  ! V4      P
                  ^,           pV P                  W#VR7      p\        VP                  \        P                  ! V4      4       K  	  \        \        3 F  pV\        J d   RMRpV\        J d   ^ M\        P                  ! V4      P                  pV\        J d   ^M&\        P                  ! V4      P
                  ^,           pV P                  W#VR7      p\        \        VR4      '       * 4       \        \        V4      V4       K  	  R# )r   rh   longr$  ri   N)r#  r4   r$  r%  r&  r'  r  r
   ri   r   r   hasattrtype)rL   r(  r)  r*  sampleop_dtypes   &     r0   test_respect_dtype_singleton(TestRandint.test_respect_dtype_singleton  s	   **Bbgg1288B<+;+;Dbgg1288B<+;+;a+?DZZ"Z5Frxx|4  +B "$svHd
1(:(>(>Dd
1(:(>(>(BDZZ"Z5F001fr* r2   r|   Nra   )"r}   r~   r   r   r   rJ   r  r4   r$  rE  rI  r@  rG  rB  r   rp   rH  r#  r   r+  r0  r7  r<  rU  r   markskipifr%  r'  r]  ra  ri  r   r   r   s   @r0   r  r    s     NNE WWbggrxx299XXryy"((BII7E=BM@!1@ [[))E1?  AOAO,".+ +r2   r  c                     a  ] tR tRt o R tR tR tR tR tR t	R t
R	 tR
 tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR t R t!R  t"R! t#R" t$R# t%R$ t&R% t'R& t(R' t)R( t*R) t+R* t,R+ t-R, t.R- t/R. t0R/ t1R0 t2]3Ph                  Pk                  R1]6Pn                  ! R2RZ4      R3]6Pp                  R4.4      R5 4       t9R6 t:R7 t;R8 t<R9 t=R: t>R; t?R< t@R= tAR> tBR? tCR@ tDRA tERB tFRC tGRD tHRE tIRF tJRG tKRH tLRI tMRJ tNRK tORL tPRM tQRN tRRO tSRP tTRQ tURR tVRS tWRT tXRU tYRV tZRW t[RXt\V t]RY# )[TestRandomDisti  c                    R V n         R# r   ru   r]   s   &r0   r   TestRandomDist.setup_method  s	    	r2   c                    \         P                  ! V P                  4       \         P                  ! ^^4      p\        P                  ! RR.RR.RR..4      p\        W^R7       R# )	rk   _\*?琛?<p?,o?H?Z?decimalN)r   ru   randr4   ro   r   rL   r`  r\  s   &  r0   	test_randTestRandomDist.test_rand  s^    DIIQ"((02EF02EF/1CDF G 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! 4       pR p\        W^R7       R# )rs  ry  N)r   ru   r{  r   r|  s   &  r0   test_rand_singleton"TestRandomDist.test_rand_singleton  s,    DII%!&2>r2   c                ^   \         P                  ! V P                  4       \         P                  ! ^^4      p\        P                  ! RR.RR.RR..4      p\        W^R7       \         P                  ! V P                  4       \         P                  ! 4       p\        WR	,          ^R7       R# )
rk   !<Oq?4u,?3?@? @HS\@ry  NLI/DͿr   r   r   ru   randnr4   ro   r   r|  s   &  r0   
test_randnTestRandomDist.test_randn  s    DIIa#((02EF-/BC-/BCE F 	"&2>DII!&$-Dr2   c                    \         P                  ! V P                  4       \         P                  ! R^cRR7      p\        P                  ! ^^.R^).RR..4      p\        W4       R# c   r   Nirk   rc   iii)r   ru   rJ   r4   ro   r	   r|  s   &  r0   test_randintTestRandomDist.test_randint  sU    DIIRf5((RG "I #J( ) 	6+r2   c                   \         P                  ! V P                  4       \        4       ;_uu_ 4       pVP                  \        4      p\         P
                  ! R^cRR7      p\        \        V4      ^8H  4       RRR4       \        P                  ! ^^.R^).RR..4      p\        XV4       \         P                  ! V P                  4       \        4       ;_uu_ 4       pVP                  \        4      p\         P
                  ! ^RR7      p\        \        V4      ^8H  4       RRR4       \        W4^d,           4       R#   + '       g   i     L; i  + '       g   i     L7; ir  )r   ru   r   r   DeprecationWarningrandom_integersr   r   r4   ro   r	   )rL   r   r   r`  r\  s   &    r0   test_random_integers#TestRandomDist.test_random_integers  s    DII  C

-.A++C&AFCFaK  ! ((RG "I #J( ) 	67+DII  C

-.A++Cf=FCFaK  ! 	6S=1 !  ! s   AD?AE?E	E"	c                ^   \         P                  ! V P                  4       \         P                  ! V P                  4      pVP                  RR7      p\        P
                  ! \        P                  4      P                  R8X  d1   \        P                  ! RR.RR.RR..\        P                  R	7      pM/\        P                  ! R
R.RR.RR..\        P                  R	7      p\        W#4       VP                  V P                  4       VP                  4       p\        W#R,          4       R# )rk   r   ii4Oi˕+iRKiriFbqirh   l   K+W+y l   r&&J] l   ;	 l   nBz l   @XHT l   D+l++ Nr  r  )r   ru   rI   r   r4   r%  rd  r'  ro   rp   r
   )rL   rv   r`  r\  s   &   r0   test_tomaxintTestRandomDist.test_tomaxint  s    DII		*&)88BGG  J.hhi 8!+i 8!+i 8 :ACKG hh!46I J!46I J!46I J L &(XX/G
 	V%
		VT]+r2   c           
        \        4       ;_uu_ 4       pVP                  \        4      p\        P                  ! \
        P                  ! R 4      P                  \
        P                  ! R 4      P                  4      p\        \        V4      ^8H  4       RRR4       \
        P                  ! R 4      P                  p\        XV4       \        4       ;_uu_ 4       pVP                  \        4      p\
        P                  ! R 4      P                  p\        P                  ! V! \
        P                  ! R 4      P                  4      V! \
        P                  ! R 4      P                  4      4      p\        \        V4      ^8H  4       RRR4       \        W44       R#   + '       g   i     EL; i  + '       g   i     L1; i)rW  N)r   r   r  r   r  r4   r%  r'  r   r   r
   ri   rf  )rL   r   r   r`  r\  typers   &     r0   test_random_integers_max_int+TestRandomDist.test_random_integers_max_int  s       C

-.A++BHHSM,=,=,.HHSM,=,=?FCFaK 	 ! ((3-##VW%  C

-.AHHSM&&E++E"((3-2C2C,D,1"((3-2C2C,DFFCFaK  ! 	V% !   ! s   B FB,F.F+	.F>	c           
        \         P                  ! 4       ;_uu_ 4        \         P                  ! R \        4       \	        \        \
        P                  \        P                  ! R4      P                  4       \	        \        \
        P                  \        P                  ! R4      P                  \        P                  ! R4      P                  4       RRR4       R#   + '       g   i     R# ; i)errorrW  N)
warningscatch_warningssimplefilterr  r   r   r  r4   r%  r'  r]   s   &r0   test_random_integers_deprecated.TestRandomDist.test_random_integers_deprecated$  s    $$&&!!'+=> , 00((3-++-
 , 00((3-++RXXc]->->@ '&&&s   B5CC.	c                \   \         P                  ! V P                  4       \         P                  ! R	4      p\        P                  ! RR.RR.RR..4      p\        W^R7       \         P                  ! V P                  4       \         P                  ! 4       p\        WR
,          ^R7       R# )rk   rs  rt  ru  rv  rw  rx  ry  Nr  r  )r   ru   r  r4   ro   r   r|  s   &  r0   test_random_sample!TestRandomDist.test_random_sample2  s    DII%%f-((02EF02EF/1CDF G 	"&2>DII%%'!&$-Dr2   c                    \         P                  ! V P                  4       \         P                  ! ^^4      p\        P                  ! . RO4      p\        W4       R# )rl   N)rc   rk   rc   rk   r   ru   choicer4   ro   r	   r|  s   &  r0   test_choice_uniform_replace*TestRandomDist.test_choice_uniform_replace>  s8    DIIq!$((<(6+r2   c                    \         P                  ! V P                  4       \         P                  ! ^^. ROR7      p\        P                  ! . RO4      p\        W4       R# )rl   r   N)皙?r  皙?r  )rb   rb   rc   rc   r  r|  s   &  r0   test_choice_nonuniform_replace-TestRandomDist.test_choice_nonuniform_replaceD  s;    DIIq!';<((<(6+r2   c                    \         P                  ! V P                  4       \         P                  ! ^^RR7      p\        P                  ! . RO4      p\        W4       R# )rl   FreplaceN)r   rb   rk   r  r|  s   &  r0   test_choice_uniform_noreplace,TestRandomDist.test_choice_uniform_noreplaceJ  s:    DIIq!U3((9%6+r2   c                    \         P                  ! V P                  4       \         P                  ! ^^R. ROR7      p\        P                  ! . RO4      p\        W4       R# )rl   Fr  r   N)r  333333?rW   r  )rc   rk   rb   r  r|  s   &  r0    test_choice_nonuniform_noreplace/TestRandomDist.test_choice_nonuniform_noreplaceP  s=    DIIq!U6JK((9%6+r2   c                    \         P                  ! V P                  4       \         P                  ! . RO^4      p\        P                  ! . RO4      p\        W4       R# )rA   N)rA   rB   cd)r  r  r  r  r  r|  s   &  r0   test_choice_noninteger%TestRandomDist.test_choice_nonintegerV  s:    DII3Q7((/06+r2   c           	     l   \         P                  p\        \        VR
^4       \        \        VR^4       \        \        V^^.^^..^4       \        \        V. ^4       \        \        V. RO^RR.RR..R7       \        \        V^^.^. ROR7       \        \        V^^.^RR.R7       \        \        V^^.^RR.R7       \        \        V. RO^RR7       \        \        V. RORRR7       \        \        V. RORRR7       \        \        V. RORRR7       \        \        V. RO^R. ROR7       R	# )rb         @g      ?r  r  r   Fr  r  NrY   )rb   rc   rk   rl   )r  r  r   r   rj   rd   )rY   )rY   rb   )rb   r   r   )r   r  r   r\   )rL   rg  s   & r0   test_choice_exceptions%TestRandomDist.test_choice_exceptions\  s	   j&"a0j&"a0j&Aq6Aq6*:A>j&"a0j&,d|4	6j&1a&!Gj&1a&!T{Cj&1a&!SzBj&)QFj&)RGj&)UEJj&)WeLj&)Q#y	2r2   c                   R R.p\        \        P                  ! \        P                  ! ^RR7      4      4       \        \        P                  ! \        P                  ! ^RR7      4      4       \        \        P                  ! \        P                  ! ^RVR7      4      4       \        \        P                  ! \        P                  ! ^RVR7      4      4       \        \        P                  ! \        P                  ! ^^.RR7      4      4       \        \        P                  ! R.RR7      RJ 4       \        P
                  ! ^^.4      p\        P                  ! ^\        R7      pW#^ &   \        \        P                  ! VRR7      VJ 4       Rp\        \        P                  ! \        P                  ! ^VRR7      4      '       * 4       \        \        P                  ! \        P                  ! ^VRR7      4      '       * 4       \        \        P                  ! \        P                  ! ^VRVR7      4      '       * 4       \        \        P                  ! \        P                  ! ^VRVR7      4      '       * 4       \        \        P                  ! \        P                  ! ^^.VRR7      4      '       * 4       \        \        P                  ! R.VRR7      P                  ^ 8H  4       \        P
                  ! ^^.4      p\        P                  ! ^\        R7      pW#^ &   \        \        P                  ! W4RR7      P                  4       VJ 4       Rp. ROp\        \        P                  ! ^VRR7      P                  V4       \        \        P                  ! ^VRR7      P                  V4       \        \        P                  ! ^VRVR7      P                  V4       \        \        P                  ! ^VRVR7      P                  V4       \        \        P                  ! \        P                  ! ^4      VRR7      P                  V4       \        \        P                  ! ^ ^ RR7      P                  R4       \        \        P                  ! ^ R^ R7      P                  R4       \        \        P                  ! ^
^
^ R7      P                  R4       \        \        P                  ! ^ ^ R7      P                  R4       \        \        P                  ! . RR7      P                  R4       \        \        P                  ! R	R
.RR7      P                  R4       \        \        \        P                  . ^
4       R# )r  r   Tr  Fr  Nrh   r   rA   rB   r|   )rc   rk   )r  r  r  r  r  r   )rk   r   rl   i)r   )r   r4   isscalarr   r  ro   emptyr  ndimitemr
   r   rS   rJ   r   r\   )rL   r   rA   arrrM   s   &    r0   test_choice_return_shape'TestRandomDist.test_choice_return_shapeo  s   #JFMM!T:;<FMM!U;<=FMM!TQ?@AFMM!Ua@ABFMM1a&$?@Atfd3t;<HHaVhhq'Ac40A56 BKKaD ABBCBKKaE BCCDBKKaDA FGGHBKKaEQ GHHIBKKq!fa FGGHtfa6;;q@AHHaVhhq'Acd388:a?@ *V]]1a6<<a@V]]1a7==qAV]]1a;AA1EV]]1a!<BBAFV]]299Q<DAGGK 	V^^Aqy9??KV^^As3994@V^^B3994@V]]11-33T:V]]2D177>V]]C:I>DD	 j&--R8r2   c                ~    \         P                  ! . RO4      p. ROp\        \        \        P
                  WR7       R# )*   Nr  )r  rb   rc   )NNN)r4   ro   r   r\   r   r  )rL   rA   r   s   &  r0   test_choice_nan_probabilities,TestRandomDist.test_choice_nan_probabilities  s%    HHZ j&--8r2   c                   \         P                  ! ^
4      ^,          pRVR&   \        P                  ! V P                  4       \        P                  ! ^^VR,          R7      p\        P                  ! V P                  4       \        P                  ! ^^\         P
                  ! VR,          4      R7      p\        W#4       R# )rQ   r  :rb   Nrc   NNrc   r  N)r4   onesr   ru   r  r   r	   )rL   r   r   r   s   &   r0   test_choice_p_non_contiguous+TestRandomDist.test_choice_p_non_contiguous  s{    GGBK!O$DII]]1a1S62
DIIq!r';';AcF'CD:.r2   c                    \         P                  ! V P                  4       \         P                  ! ^
4      pRp\        W4       R# )rQ   s
   Ui+WfN)r   ru   bytesr
   r|  s   &  r0   
test_bytesTestRandomDist.test_bytes  s-    DIIb!.V%r2   c                    R  R R R R R R R R R	 R
 3 FZ  p\         P                  ! V P                  4       V! . RO4      p\         P                  ! V4       TpV! . RO4      p\        W44       K\  	  R# )c                 .    \         P                  ! . 4      # r+   )r4   ro   r   s   &r0   <lambda>-TestRandomDist.test_shuffle.<locals>.<lambda>  s    rxx|r2   c                     V # r+   r|   r  s   &r0   r  r    s    qr2   c                 h    \         P                  ! V 4      P                  \         P                  4      # r+   )r4   asarrayastyperE  r  s   &r0   r  r    s    rzz!}33BGG<r2   c                 h    \         P                  ! V 4      P                  \         P                  4      # r+   )r4   r  r  r   r  s   &r0   r  r    s    rzz!}33BJJ?r2   c                 h    \         P                  ! V 4      P                  \         P                  4      # r+   )r4   r  r  	complex64r  s   &r0   r  r    s    rzz!}33BLLAr2   c                 T    \         P                  ! V 4      P                  \        4      # r+   )r4   r  r  r  r  s   &r0   r  r    s    rzz!}33F;r2   c                 2    V  Uu. uF  qV3NK  	  up# u upi r+   r|   r   is   & r0   r  r    s    21A22s   c                 Z    \         P                  ! V  Uu. uF  qV.NK  	  up4      # u upi r+   )r4   r  r  s   & r0   r  r    s!    rzz1*=1aq61*=>*=s   (c                 D    \         P                  ! W .4      P                  # r+   )r4   vstackTr  s   &r0   r  r    s    ryy!022r2   c                     \         P                  ! V  Uu. uF  qV3NK  	  upR \        3R\        3.4      P                  \         P                  4      # u upi r@   )r4   r  r   rP  recarrayr  s   & r0   r  r    sG    

A+>AqFA+>-0#Jc
+C!E!%bkk!2!3+>s   Ac                     \         P                  ! V  Uu. uF  qV3NK  	  upR \        R3R\         P                  R3.4      # u upi )rA   rB   rb   )r4   r  r  rB  r  s   & r0   r  r    sB    rzz1*=1aq61*=,/+>,/4+@+B C*=s   AN
rb   rc   rk   rl   rm   rn      r:  	   r   
r   rb   r  rn   rc   rl   rm   r:  r  rk   )r   ru   shuffler	   )rL   convalistr`  r\  s   &    r0   test_shuffleTestRandomDist.test_shuffle  sy     , <?A;2>24CDD" KK		"78ENN5!F9:Gv/-Dr2   c                <   \         P                  P                  \         P                  ! \	        ^4      R4      ^,          ^,
          R4      p\         P                  P                  \         P
                  ! ^4      ^,          ^,
          R4      pVP                  4       pVP                  4       p\	        ^24       F  p\        P                  ! V4       \        \        VP                  VP                  ( ,          4      \        VP                  VP                  ( ,          4      4       \        P                  ! V4       \        \        VP                  VP                  ( ,          4      \        VP                  VP                  ( ,          4      4       K  	  R pR# )   c                 p    \         P                  ! ^4      p\        \        \        P
                  V4       R# )rk   N)r4   ro   r   r[   r   r  r   s   & r0   test_shuffle_invalid_objectsHTestRandomDist.test_shuffle_masked.<locals>.test_shuffle_invalid_objects  s    A)V^^Q7r2   N)rm   rl   rY   )r4   mamasked_valuesreshaperR   rS   copyr   r  r
   sorteddatamask)rL   rA   rB   a_origb_origr  r  s   &      r0   test_shuffle_masked"TestRandomDist.test_shuffle_masked  s   EE

59f = AA ErJEE		" 1A 5r:rANN1qvvqvvg'V[[L0I)JLNN1qvvqvvg'V[[L0I)JL 	8r2   c                .   \         P                  ! V P                  4       . ROp\         P                  ! V4      p. ROp\        W#4       \         P                  ! V P                  4       \        P
                  ! . RO4      P                  p\         P                  ! V4      p\        V\        P
                  ! V4      P                  4       \         P                  ! V P                  4       Rp\        \        \         P                  V4       \         P                  ! V P                  4       Rp\        \        \         P                  V4       ^
p. ROp\         P                  ! V P                  4       \         P                  ! V4      p\        W#4       R# )rb   abcdg333333?Nr  r  )
r  r   r:  rm   rb   rk   rl   r  rn   rc   )	r   ru   permutationr	   r4   
atleast_2dr  r   
IndexError)rL   r  r`  r\  arr_2d	bad_x_strbad_x_floatinteger_vals   &       r0   test_permutationTestRandomDist.test_permutation  s   DII.##E*06+DII=>@@##F+62==#9#;#;<DII	j&"4"4i@DIIj&"4"4kB0DII##K06+r2   c                    \         P                  ! V P                  4       \         P                  ! R RRR7      p\        P                  ! RR.RR.RR..4      p\        W^R	7       R
# )r  r   r   gAKč?ghA?g ҇o>gάXf+q?gS1$?g'8zX ?ry  Nr  )r   ru   betar4   ro   r   r|  s   &  r0   	test_betaTestRandomDist.test_beta  s`    DIIR&1(()+BC)+BC)+BCEF 	"&2>r2   c                T   \         P                  ! V P                  4       \         P                  ! R RRR7      p\        P                  ! ^%^+.^*^0.^.^-..4      p\        W4       \         P                  ! V P                  4       \         P                  ! R R4      p^%p\        W4       R# )gZd;Y@gv/?r   Nr  )r   ru   r   r4   ro   r	   r|  s   &  r0   test_binomialTestRandomDist.test_binomial  s    DII$V<((RHHH& ' 	6+DII$/6+r2   c                    \         P                  ! V P                  4       \         P                  ! ^2R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )2   r   g+Q]uO@g+Q@gY7`ZqP@ge(fG@gvtR@gEIȋR@ry  Nr  )r   ru   	chisquarer4   ro   r   r|  s   &  r0   test_chisquareTestRandomDist.test_chisquare  s`    DII!!"62((13GH13GH02FGI J 	"&2>r2   c                H   \         P                  ! V P                  4       \        P                  ! R R.4      p\         P                  ! VRR7      p\        P                  ! RR.RR..RR.R	R
..RR.RR...4      p\        W#^R7       \        P                  ! RR.4      p\        \        \         P                  V4       \         P                  ! V P                  4       \        P                  ! R R.4      p\         P                  ! V4      p\        W#R,          ^R7       R# )I<I@EZC@r   gi{s?gn,	A?g]^?gpDB?gȧ#y?gr?g1U?gѨUC?g^,%?gB?gډOoX;?gM`!O?ry  HzG?Nr  缉ؗҜr  )r   ru   r4   ro   	dirichletr   r   r\   )rL   alphar`  r\  	bad_alphas   &    r0   test_dirichletTestRandomDist.test_dirichlet  s
   DII.0DEF!!%f5((13FG13FGI13FG13FGI13FG13FGI	J K 	"&2>HHgx01	j&"2"2I>DII.0DEF!!%(!&$-Dr2   c                0   \         P                  ! R R.4      p\        \        P                  ! V\         P
                  ! ^4      4      P                  R4       \        \        P                  ! V\         P
                  ! ^4      4      P                  R4       \        \        P                  ! V\         P
                  ! ^4      4      P                  R4       \        \        P                  ! V^^.4      P                  R4       \        \        P                  ! VR4      P                  R4       \        \        P                  ! V\         P                  ! R4      4      P                  R4       \        \        \        P                  V\        ^4      4       R# )r&  r'  Nr   r   r   )
r4   ro   r
   r   r*  r   r   r   r[   r   r   s   & r0   test_dirichlet_size"TestRandomDist.test_dirichlet_size*  s   HH*,@ABV%%a16<<fEV%%a16<<fEV%%a16<<fEV%%a!Q066	BV%%a066	BV%%a&)9:@@)Li!1!11eAh?r2   c                t    \         P                  ! R R.4      p\        \        \        P
                  V4       R# )r(  Nr)  )r4   ro   r   r\   r   r*  )rL   r+  s   & r0   test_dirichlet_bad_alpha'TestRandomDist.test_dirichlet_bad_alpha6  s'    '8,-j&"2"2E:r2   c                f   \         P                  ! . RO4      pVR,          p\        P                  ! V P                  4       \        P                  ! VRR7      p\        P                  ! V P                  4       \        P                  ! \         P
                  ! V4      RR7      p\        W44       R# )r&  r  r   N)r&  g      r'  r  )r4   ro   r   ru   r*  r   r   )rL   rA   r+  r   r   s   &    r0   #test_dirichlet_alpha_non_contiguous2TestRandomDist.test_dirichlet_alpha_non_contiguous;  st    HHGH#DII%%e&9
DII!!""6"6u"='-/!*5r2   c                    \         P                  ! V P                  4       \         P                  ! R R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )g8EGr?r   gNU?gbI0?gVU\@g:3@gU?g"qo?ry  Nr  )r   ru   exponentialr4   ro   r   r|  s   &  r0   test_exponentialTestRandomDist.test_exponentialE  s`    DII##F8((02EF02EF02EFH I 	"&2>r2   c                    \        \        P                  ! ^ R7      ^ 4       \        \        \        P                  RR7       R# r   scaleN       )r
   r   r9  r   r\   r]   s   &r0   test_exponential_0!TestRandomDist.test_exponential_0M  s)    V''a0!4j&"4"4C@r2   c                    \         P                  ! V P                  4       \         P                  ! ^^MR
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )   r   g7?g`j?g6"+?gܳ2>?gc>+Y?g_}S?ry  Nr  )r   ru   fr4   ro   r   r|  s   &  r0   test_fTestRandomDist.test_fQ  s`    DII"bv.((02EF02EF02EFH I 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! ^^R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rm   r   gԏGM8@gȌ<@g	":@gv#)@gZQ?@gr[@@ry  Nr  )r   ru   gammar4   ro   r   r|  s   &  r0   
test_gammaTestRandomDist.test_gammaY  s`    DIIa0((13GH13GH13GHJ K 	"&2>r2   c                    \        \        P                  ! ^ ^ R7      ^ 4       \        \        \        P                  RRR7       R# )r   )r   r?  Nr@  )r
   r   rI  r   r\   r]   s   &r0   test_gamma_0TestRandomDist.test_gamma_0a  s)    V\\3Q7j&,,cEr2   c                    \         P                  ! V P                  4       \         P                  ! R RR7      p\        P                  ! ^^.^^.^^..4      p\        W4       R# )_c97ݚ?r   Nr  )r   ru   r   r4   ro   r	   r|  s   &  r0   test_geometricTestRandomDist.test_geometrice  sU    DII!!*6:((QFHG% & 	6+r2   c                j   \        \        \        P                  R 4       \        \        \        P                  R .^
,          4       \        \        \        P                  R4       \        \        \        P                  R.^
,          4       \	        4       ;_uu_ 4       pVP                  \        4       \        \        \        P                  \        P                  4       \        \        \        P                  \        P                  .^
,          4       RRR4       R#   + '       g   i     R# ; i)r   Nr   )	r   r\   r   r   r   r   r   r4   r   rL   r   s   & r0   test_geometric_exceptions(TestRandomDist.test_geometric_exceptionsm  s    j&"2"2C8j&"2"2SEBJ?j&"2"2D9j&"2"2TFRK@  CJJ~&*f&6&6?*f&6&62F !   s   A8D!!D2	c                    \         P                  ! V P                  4       \         P                  ! R RRR7      p\        P                  ! RR.R	R
.RR..4      p\        W^R7       R# )rP         @locr?  r   gؕ?gs0 ?g-KD?ry  Nr  g#0g(xgůp`@)r   ru   gumbelr4   ro   r   r|  s   &  r0   test_gumbelTestRandomDist.test_gumbelw  s`    DII:SvF((02EF02FG02FGI J 	"&2>r2   c                    \        \        P                  ! ^ R7      ^ 4       \        \        \        P                  RR7       R# r=  )r
   r   r[  r   r\   r]   s   &r0   test_gumbel_0TestRandomDist.test_gumbel_0  %    V]]+Q/j&--s;r2   c                   \         P                  ! V P                  4       \         P                  ! R R^RR7      p\        P                  ! ^
^
.^
^
.^	^	..4      p\        W4       \         P                  ! ^^ ^^R7      p\        P                  ! . RO4      p\        W4       \         P                  ! ^^ ^^R7      p\        P                  ! . RO4      p\        W4       \         P                  ! ^ ^^^R7      p\        P                  ! . RO4      p\        W4       \         P                  ! ^ ^^^R7      p\        P                  ! . RO4      p\        W4       R# )g333333$@g      @r   Nr  )rk   rk   rk   rk   )rD  rD  rD  rD  )r   r   r   r   )r   ru   r   r4   ro   r	   r|  s   &  r0   test_hypergeometric"TestRandomDist.test_hypergeometric  s   DII&&tS"6B((RHHF$ % 	6+ &&q!QQ7((<(6+&&r1bq9((+,6+ &&q!QQ7((<(6+&&q"bq9((<(6+r2   c                    \         P                  ! V P                  4       \         P                  ! R RR
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rP  rX  rY  g bO?g¸?gpJm	@g{K*t	@gY~o?ry  Nr  g:^w-)r   ru   laplacer4   ro   r   r|  s   &  r0   test_laplaceTestRandomDist.test_laplace  s`    DIIJcG((02EF02EF13FGI J 	"&2>r2   c                    \        \        P                  ! ^ R7      ^ 4       \        \        \        P                  RR7       R# r=  )r
   r   rf  r   r\   r]   s   &r0   test_laplace_0TestRandomDist.test_laplace_0  s%    V^^!,a0j&..<r2   c                    \         P                  ! V P                  4       \         P                  ! R RR
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rP  rX  rY  g#K-z?gJ?g92@gر[@g-@ry  Nr  g#+^˿)r   ru   logisticr4   ro   r   r|  s   &  r0   test_logisticTestRandomDist.test_logistic  s`    DIIZsH((02DE02EF13FGI J 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! R RRR7      p\        P                  ! RR.RR.RR..4      p\        W^R	7       R
# )rP  rX  )meansigmar   gɁ0@go,+4FB@g)ʭ6@g5?gnxNnP@g)U@ry  Nr  )r   ru   	lognormalr4   ro   r   r|  s   &  r0   test_lognormalTestRandomDist.test_lognormal  sb    DII!!z6J((13GH13FG13GHJ K 	"&2>r2   c                    \        \        P                  ! ^ R7      ^4       \        \        \        P                  RR7       R# )r   )rr  Nr@  )r
   r   rs  r   r\   r]   s   &r0   test_lognormal_0TestRandomDist.test_lognormal_0  s)    V%%A.2j&"2"2#>r2   c                    \         P                  ! V P                  4       \         P                  ! R RR7      p\        P                  ! ^^.^^.^^..4      p\        W4       R# )gƀ@?)r   r   Nr  )r   ru   r   r4   ro   r	   r|  s   &  r0   test_logseriesTestRandomDist.test_logseries  sU    DII!!JV<((QFGF$ % 	6+r2   c                @    \         P                  ! ^ 4      ^8X  g   Q hR# r   N)r   r   r]   s   &r0   test_logseries_zero"TestRandomDist.test_logseries_zero  s    "a'''r2   valuer         ?g      @c           
        \         P                  ! R R7      ;_uu_ 4        \        P                  ! \        4      ;_uu_ 4        \
        P                  ! V4       RRR4       \        P                  ! \        4      ;_uu_ 4        \
        P                  ! \         P                  ! V.^
,          4      4       RRR4       \        P                  ! \        4      ;_uu_ 4        \
        P                  ! \         P                  ! V.^
,          4      R,          4       RRR4       RRR4       R#   + '       g   i     L; i  + '       g   i     L; i  + '       g   i     L@; i  + '       g   i     R# ; i)ignoreinvalidNr  )r4   errstater   r   r\   r   r   ro   )rL   r  s   &&r0   test_logseries_exceptions(TestRandomDist.test_logseries_exceptions  s    [[**z**  ' +z**  5'B,!78 + z**  5'B,!7!<= + +***** +* +**sS   #E&D-	*E&3E 	7*E&!:E	E&-D=8E& EE&E#E&&E7	c                    \         P                  ! V P                  4       \         P                  ! ^R.^,          RR7      p\        P                  ! . RO. RO.. RO. RO.. R	O. R
O..4      p\        W4       R# )r  r   NUUUUUU?r  )rl   rk   rm   rl   rc   rc   )rm   rc   r:  rc   rc   rb   )rk   rl   rk   rn   r   rl   )rc   rb   rl   rk   rn   rl   )rl   rl   rc   rm   rc   rk   )rl   rk   rl   rc   rk   rl   )r   ru   r   r4   ro   r	   r|  s   &  r0   test_multinomialTestRandomDist.test_multinomial  sj    DII##B16B((//1//1//1	2 3 	6+r2   c                D   \         P                  ! V P                  4       Rp^^ .^ ^..pRp\         P                  ! WV4      p\        P                  ! RR.RR..RR.RR..R	R
.RR...4      p\        WE^R7       \         P                  ! W4      p\        P                  ! RR.4      p\        WE^R7       ^ ^ .p^^.^^..p\        \        \         P                  W4       \        \         P                  WRR7       \        \        \         P                  WRR7       \        P                  ! ^R.R^..\        P                  R7      p\        4       ;_uu_ 4       p\         P                  ! W4       VP                  \        4      p\        V4      ^ 8X  g   Q h RRR4       \        P                  ! ^4      p\        P                   ! ^4      p\        \        \         P                  WRR7       \        \        \         P                  \        P                  ! R4      V4       \        \        \         P                  V\        P"                  ! R4      4       \        \        \         P                  V\        P                   ! ^4      4       R#   + '       g   i     L; i)rP  g4Vj?gy'@gI1?gSB#@ge<@g 4W(@g6R¿?g9r
v"@gс?g{#@g"f"@ry  gN}O6?gYMW"@r  )check_validraiser  rh   Nother)rP  rQ   r  g4x)rc   rb   rb   )r   ru   multivariate_normalr4   ro   r   r   r   r   r   r\   r   r   r   r   r   eyer  )	rL   rq  covr   r`  r\  r   r   mus	   &        r0   test_multivariate_normal'TestRandomDist.test_multivariate_normal  s3   DII1v1v++Dt<((/1BC/1BCE/1CD/1BCE/1BC02CDF	G H 	"&2> ++D6((-/?@A!&2> 1v1v1v^V%?%?K 	655t'/	1 	j&"<"<d")	+ hhC3(+2::>  C&&t1

>*Aq6Q;; !
 XXa[ffQij&"<"<d")	+j&"<"<hhy)3	0j&"<"<"((6*	,j&"<"<"&&)	% ! s   >JJ	c                    \         P                  ! V P                  4       \         P                  ! ^dRR
R7      p\        P                  ! RR.RR.RR..4      p\        W4       R	# )r   g|Pk?)nr   r   iP  iI  i|  ic  i  i  Nr  )r   ru   r   r4   ro   r	   r|  s   &  r0   r   %TestRandomDist.test_negative_binomial  sW    DII))C6G((S#J #J #J( ) 	6+r2   c           	     V   \        4       ;_uu_ 4       pVP                  \        4       \        \        \
        P                  ^d\        P                  4       \        \        \
        P                  ^d\        P                  .^
,          4       RRR4       R#   + '       g   i     R# ; i)r   N)	r   r   r   r   r\   r   r   r4   r   rT  s   & r0   !test_negative_binomial_exceptions0TestRandomDist.test_negative_binomial_exceptions  sa      CJJ~&*f&>&>RVVL*f&>&>66(R-) !   s   A:BB(	c                $   \         P                  ! V P                  4       \         P                  ! ^^RR7      p\        P                  ! RR.RR.RR..4      p\        W^R7       \         P                  ! R	R
RR7      p\        P                  ! RR.RR.RR..4      p\        W^R7       \         P                  ! V P                  4       \         P                  ! ^^ RR7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R# )rm   )dfnoncr   gG7@g! ܴ*@g1}z9?@g+驸0@g26E_r#@gI!1@ry  rW   r   g?gTD?g?T?g+qnl?g~|D?g밬?g{01#@gprs'@g~;$@g"dI@g*@g}',@Nr  )r   ru   noncentral_chisquarer4   ro   r   r|  s   &  r0   test_noncentral_chisquare(TestRandomDist.test_noncentral_chisquare!  s   DII,,G((13GH13GH02FGI J 	"&2>,,&I((03FG03FG.1DEG H 	"&2>DII,,G((.0BC/1BC/1CDF G 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! ^^^R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rm   )dfnumdfdenr  r   g^~?g/+c?g".@g@g7?gE?ry  Nr  )r   ru   noncentral_fr4   ro   r   r|  s   &  r0   test_noncentral_f TestRandomDist.test_noncentral_f6  sg    DII$$1AA*02((02EF02EF02DEG H 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! ^^\        P                  R7      p\        P
                  ! V4      '       g   Q hR# )rm   )r  r  r  N)r   ru   r  r4   r   isnan)rL   r`  s   & r0   test_noncentral_f_nan$TestRandomDist.test_noncentral_f_nan?  s?    DII$$1ABFFCxxr2   c                    \         P                  ! V P                  4       \         P                  ! R RR
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rP  rX  rY  g&&n@gOG_@g~w@gm&5@g$>@ry  Nr  gtw]տ)r   ru   normalr4   ro   r   r|  s   &  r0   test_normalTestRandomDist.test_normalD  s`    DII:SvF((02EF.0DE02EFH I 	"&2>r2   c                    \        \        P                  ! ^ R7      ^ 4       \        \        \        P                  RR7       R# r=  )r
   r   r  r   r\   r]   s   &r0   test_normal_0TestRandomDist.test_normal_0L  ra  r2   c                    \         P                  ! V P                  4       \         P                  ! R R
R7      p\        P                  ! RR.RR.RR..4      p\        P
                  P                  W^R7       R	# )rP  rA   r   gWI@gԨy@gy]0Ag1~\Aga@gY
7A)nulpNr  )r   ru   paretor4   ro   testingassert_array_almost_equal_nulpr|  s   &  r0   test_paretoTestRandomDist.test_paretoP  sk    DII&9(()+BC)+BC)+BCEF 	

11&1Kr2   c                    \         P                  ! V P                  4       \         P                  ! R RR7      p\        P                  ! ^ ^ .^^ .^ ^ ..4      p\        W4       R# )rP  )lamr   Nr  )r   ru   r   r4   ro   r	   r|  s   &  r0   test_poissonTestRandomDist.test_poisson_  sS    DIIJV<((QFFF$ % 	6+r2   c                   \         P                  ! R 4      P                  pRp\        \        \
        P                  V4       \        \        \
        P                  V.^
,          4       \        \        \
        P                  V4       \        \        \
        P                  V.^
,          4       \        4       ;_uu_ 4       pVP                  \        4       \        \        \
        P                  \         P                  4       \        \        \
        P                  \         P                  .^
,          4       RRR4       R#   + '       g   i     R# ; i)rW  NrY   )r4   r%  r'  r   r\   r   r   r   r   r   r   )rL   lambiglamnegr   s   &   r0   test_poisson_exceptions&TestRandomDist.test_poisson_exceptionsg  s    #""j&..&9j&..6(R-@j&..&9j&..6(R-@  CJJ~&*fnnbff=*fnnrvvhmD !   s   A8EE	c                    \         P                  ! V P                  4       \         P                  ! R R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rP  r  g;'?gܴw*?g5?gFG?g D]?g$`?ry  Nr  )r   ru   powerr4   ro   r   r|  s   &  r0   
test_powerTestRandomDist.test_powers  s^    DII
8((02EF02EF02EFH I 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! ^
R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rQ   )r?  r   g"u+@gN$MB*@g7v8B4@g55@ge&@g~ӣZ1@ry  Nr  )r   ru   rayleighr4   ro   r   r|  s   &  r0   test_rayleighTestRandomDist.test_rayleigh{  s^    DIIr7((02DE13GH13GHJ K 	"&2>r2   c                    \        \        P                  ! ^ R7      ^ 4       \        \        \        P                  RR7       R# r=  )r
   r   r  r   r\   r]   s   &r0   test_rayleigh_0TestRandomDist.test_rayleigh_0  s%    V__1-q1j&//=r2   c                    \         P                  ! V P                  4       \         P                  ! RR7      p\        P                  ! RR.RR	.R
R..4      p\        W^R7       R# )rk   r   gMoDL?grF=?gVA:Qy?ry  Nr  g6([9gM'	- gV)r   ru   standard_cauchyr4   ro   r   r|  s   &  r0   test_standard_cauchy#TestRandomDist.test_standard_cauchy  s^    DII''V4((02FG02FG13FGI J 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rk   r   g܁?gc!z?g&N"@gNI@gF>?g~ME?ry  Nr  )r   ru   standard_exponentialr4   ro   r   r|  s   &  r0   test_standard_exponential(TestRandomDist.test_standard_exponential  s^    DII,,&9((02EF/1DE/1DEG H 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! ^R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )rk   )r   r   g)@gľ@gd],q@gPk{@g9B#1@gv @ry  Nr  )r   ru   standard_gammar4   ro   r   r|  s   &  r0   test_standard_gamma"TestRandomDist.test_standard_gamma  s`    DII&&QV<((02EF02EF02CDF G 	"&2>r2   c                    \        \        P                  ! ^ R7      ^ 4       \        \        \        P                  RR7       R# )r   )r   Nr@  )r
   r   r  r   r\   r]   s   &r0   test_standard_gamma_0$TestRandomDist.test_standard_gamma_0  s)    V**3Q7j&"7"7sCr2   c                    \         P                  ! V P                  4       \         P                  ! R	R7      p\        P                  ! RR.RR
.RR..4      p\        W^R7       R# )rk   r   r  r  r  r  r  ry  Nr  r  )r   ru   r   r4   ro   r   r|  s   &  r0   test_standard_normal#TestRandomDist.test_standard_normal  s^    DII''V4((02EF.0CD.0CDF G 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! 4       p\        P                  ! R 4      p\        W^R7       R# )r  ry  Nr  r|  s   &  r0   test_randn_singleton#TestRandomDist.test_randn_singleton  s6    DII((./!&2>r2   c                    \         P                  ! V P                  4       \         P                  ! ^
RR7      p\        P                  ! RR.RR	.R
R..4      p\        W^R7       R# )rQ   )r  r   g\VH?gH$M?g㖀?ry  Nr  ghU%gLgVqdzǿ)r   ru   
standard_tr4   ro   r   r|  s   &  r0   test_standard_tTestRandomDist.test_standard_t  s`    DII""bv6((02FG02FG13FGI J 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! R RRRR7      p\        P                  ! RR.RR.RR	..4      p\        W^R
7       R# )g{Gz@g(\u$@gףp=
W4@)leftmoderightr   g:}\)@ghرTj(@gǨL30@g6ڜA0@g6sh&@g<,@ry  Nr  )r   ru   
triangularr4   ro   r   r|  s   &  r0   test_triangularTestRandomDist.test_triangular  sg    DII""5(.0((13FG13GH13FGI J 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! R RRR7      p\        P                  ! RR.RR.RR..4      p\        W^R	7       R
# )Gz?gGz%@)lowhighr   g>#H@gu@g#@g}d]#@gN@gw)* @ry  Nr  )r   ru   uniformr4   ro   r   r|  s   &  r0   test_uniformTestRandomDist.test_uniform  s`    DIIDu6B((02EF02EF02EFH I 	"&2>r2   c                <   \         P                  ! R 4      P                  p\         P                  ! R 4      P                  p\        P
                  p\        \        V\         P                  ) ^ 4       \        \        V^ \         P                  4       \        \        W1V4       \        \        V\         P                  ) .^ .4       \        \        V^ .\         P                  .4       \        P
                  ! \         P                  ! V^4      VR,          R7       R# )r   g ؅W4vC)r  r  N)
r4   finfor&  r'  r   r  r   OverflowErrorinf	nextafter)rL   fminfmaxfuncs   &   r0   test_uniform_range_bounds(TestRandomDist.test_uniform_range_bounds  s    xx $$xx $$~~mTBFF7A6mT1bff5mT6mTRVVG9qc:mTA39
 	2<<a0td{Cr2   c                    ! R  R\         P                  4      p\         P                  ! R4      P                  V4      p\	        \
        \        P                  VV4        ! R R\         P                  4      p\         P                  ! ^4      P                  V4      p\	        \
        \        P                  V^^4       R# )c                   &   a  ] tR tRt o R tRtV tR# )GTestRandomDist.test_scalar_exception_propagation.<locals>.ThrowingFloati  c                    \         hr+   r[   r]   s   &r0   	__float__QTestRandomDist.test_scalar_exception_propagation.<locals>.ThrowingFloat.__float__      r2   r|   N)r}   r~   r   r   r  r   r   r   s   @r0   ThrowingFloatr            r2   r	  r  c                   &   a  ] tR tRt o R tRtV tR# )ITestRandomDist.test_scalar_exception_propagation.<locals>.ThrowingIntegeri  c                    \         hr+   r  r]   s   &r0   __int__QTestRandomDist.test_scalar_exception_propagation.<locals>.ThrowingInteger.__int__  r  r2   r|   N)r}   r~   r   r   r  r   r   r   s   @r0   ThrowingIntegerr    r
  r2   r  N)	r4   ndarrayro   rP  r   r[   r   r  r   )rL   r	  throwing_floatr  throwing_ints   &    r0   !test_scalar_exception_propagation0TestRandomDist.test_scalar_exception_propagation  s    	 BJJ 	  #++M:i$	&	 bjj 	  xx{''8i!6!6aKr2   c                    \         P                  ! V P                  4       \         P                  ! R RRR7      p\        P                  ! RR.RR.RR..4      p\        W^R	7       R
# )r  p=
ף?r  kappar   gLZI@g'N"@gkr?gk=m@gډ?g^=\?ry  Nr  r   ru   vonmisesr4   ro   r   r|  s   &  r0   test_vonmisesTestRandomDist.test_vonmises  s`    DIID6B((02EF02EF02EFH I 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! R RRR7      p\        \        P
                  ! V4      P                  4       4       R# )r   gg5_PG>r  N@B )r   ru   r  r   r4   isfiniter   rL   rs   & r0   test_vonmises_small"TestRandomDist.test_vonmises_small  s=    DIIOOre<A""$%r2   c                    \         P                  ! V P                  4       \         P                  ! R R^R7      p\        P                  ! . RO4      p\        W^R7       R# )r   g    cAr  ry  N)g A^>?g @R7?g x.r  r|  s   &  r0   test_vonmises_large"TestRandomDist.test_vonmises_large  sC    DIIBc:(( 4 5 	"&1=r2   c                    \         P                  ! V P                  4       \         P                  ! R \        P                  R7      p\        \        P                  ! V4      4       R# )r   )r  r  N)r   ru   r  r4   r   r   r  r!  s   & r0   test_vonmises_nan TestRandomDist.test_vonmises_nan  s6    DIIOOr0r2   c                    \         P                  ! V P                  4       \         P                  ! R RRR7      p\        P                  ! RR.RR.RR..4      p\        W^R	7       R
# )r  r  )rq  r?  r   gZ@g-g@g8
m?gVP"?g`V?gx^&3?ry  Nr  )r   ru   waldr4   ro   r   r|  s   &  r0   	test_waldTestRandomDist.test_wald  s`    DII$d@((02EF02EF02EFH I 	"&2>r2   c                    \         P                  ! V P                  4       \         P                  ! R R
R7      p\        P                  ! RR.RR.RR..4      p\        W^R7       R	# )r  r  g@6?g]A?g(1ڥR?gU?g2_u?g^}-Q?ry  Nr  )r   ru   weibullr4   ro   r   r|  s   &  r0   test_weibullTestRandomDist.test_weibull  s^    DII$V4((02EF02EF02EFH I 	"&2>r2   c                    \         P                  ! V P                  4       \        \         P                  ! ^ ^R7      \        P
                  ! ^4      4       \        \        \         P                  RR7       R# )r   r  )rA   Nr@  )r   ru   r
   r0  r4   r   r   r\   r]   s   &r0   test_weibull_0TestRandomDist.test_weibull_0  s?    DIIV^^ab1288B<@j&..C8r2   c                    \         P                  ! V P                  4       \         P                  ! R RR7      p\        P                  ! ^B^.^^.^^..4      p\        W4       R# )r  r  Nr  )r   ru   r   r4   ro   r	   r|  s   &  r0   	test_zipfTestRandomDist.test_zipf!  sS    DIIt&1((RHFG% & 	6+r2   rp  NrY   )^r}   r~   r   r   r   r}  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r#  r-  r0  r3  r6  r:  rA  rF  rJ  rM  rQ  rU  r\  r_  rc  rg  rj  rn  rt  rw  rz  r~  r   rk  parametrizer4   r  r   r  r  r  r   r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r#  r&  r)  r-  r1  r4  r7  r   r   r   s   @r0   rn  rn    s    ??
E,2$,(&,@
E,,,,,2&,9\9
/&068$,6?,?E&
@;
6?A??F,G?<,4?=???,( [[Wr||B';R&LM	> N	>	,1%f,)?*? 
?<L,
E??>???D?????D L,?&>
??9
, ,r2   rn  c                      a  ] tR tRt o R tR tR tR tR tR t	R t
R	 tR
 tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR t R t!R  t"R! t#R"t$V t%R## )$TestBroadcasti*  c                    R V n         R# )[Nrp  r]   s   &r0   r   TestBroadcast.setup_method-  s	    	r2   c                F    \         P                  ! V P                  4       R # r+   )r   ru   r]   s   &r0   set_seedTestBroadcast.set_seed0  s    DIIr2   c                   ^ .p^.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        WT^R7       V P	                  4        V! W^,          4      p\        WT^R7       R# )r   ry  Ngl?g_x?g=*BN?)r   r  r4   ro   r@  r   )rL   r  r  r  r\  r`  s   &     r0   r  TestBroadcast.test_uniform3  sr    cs..(( 1 2 	q$'!&2>Qh'!&2>r2   c                z   ^ .p^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        We^R7       \        \        WA^,          V4       V P	                  4        V! W^,          4      p\        We^R7       \        \        WAV^,          4       R# )r   ry  NrY   )g-r@gYl@g-`w?)r   r  r4   ro   r@  r   r   r\   )rL   rZ  r?  	bad_scaler  r\  r`  s   &      r0   r  TestBroadcast.test_normalC  s    cD	(( 0 1 	a'!&2>j&'9=QY'!&2>j&y1}=r2   c                   ^.p^.pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        Wv^R7       \        \        WS^,          V4       \        \        WQ^,          V4       V P	                  4        V! W^,          4      p\        Wv^R7       \        \        WSV^,          4       \        \        WQV^,          4       R# )rb   ry  NrY   rd   )gnQVf?gVKB?gv`k?)r   r  r4   ro   r@  r   r   r\   )rL   rA   rB   bad_abad_br  r\  r`  s   &       r0   r  TestBroadcast.test_betaV  s    CC{{(( 1 2 	a!eQ!&2>j$	15j$Au5aQ!&2>j$q1u5j$5195r2   c                    ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       R# rb   ry  NrY   )g.UgZ?gi Prq?gEK?)r   r9  r4   ro   r@  r   r   r\   )rL   r?  rF  r9  r\  r`  s   &     r0   r:  TestBroadcast.test_exponentiall  s_    D	(((( 1 2 	UQY'!&2>j+1}=r2   c                    ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       R# rM  )r   r  r4   ro   r@  r   r   r\   )rL   r   	bad_shape	std_gammar\  r`  s   &     r0   r  !TestBroadcast.test_standard_gammay  s_    D	))	(( 1 2 	519%!&2>j)];r2   c                   ^.p^.pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        Wv^R7       \        \        WS^,          V4       \        \        WQ^,          V4       V P	                  4        V! W^,          4      p\        Wv^R7       \        \        WSV^,          4       \        \        WQV^,          4       R# )rb   ry  NrY   rd   )g.UgZ?gi Prq?gEK?)r   rI  r4   ro   r@  r   r   r\   )rL   r   r?  rP  rF  rI  r\  r`  s   &       r0   rJ  TestBroadcast.test_gamma  s    D	D	(( 0 1 	uqy%(!&2>j%Q>j%I>uai(!&2>j%EAI>j%	A>r2   c                   ^.p^.pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        Wv^R7       \        \        WS^,          V4       \        \        WQ^,          V4       V P	                  4        V! W^,          4      p\        Wv^R7       \        \        WSV^,          4       \        \        WQV^,          4       R# )rb   ry  NrY   rd   )gbyʜ?go?gT7@)r   rE  r4   ro   r@  r   r   r\   )rL   r  r  	bad_dfnum	bad_dfdenrE  r\  r`  s   &       r0   rF  TestBroadcast.test_f  s    D	D	HH(( 0 1 	519e$!&2>j!]E:j!QY	:5!)$!&2>j!	:j!IM:r2   c           
        ^.p^.p^.p^ .pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          W#4      p	\        W^R7       \        P                  ! \        P                  ! V! W\        P                  .^,          4      4      4      '       g   Q h\        \        Wt^,          W#4       \        \        Wq^,          WS4       \        \        Wq^,          W&4       V P	                  4        V! W^,          V4      p	\        W^R7       \        \        WtV^,          V4       \        \        WqV^,          V4       \        \        WqV^,          V4       V P	                  4        V! WV^,          4      p	\        W^R7       \        \        WtW#^,          4       \        \        WqWS^,          4       \        \        WqW&^,          4       R# )rc   ry  NrY   rd   )gr^G"@g/*@gц!@)r   r  r4   ro   r@  r   r   r  r   r   r\   )
rL   r  r  r  rV  rW  bad_noncnonc_fr\  r`  s
   &         r0   r  TestBroadcast.test_noncentral_f  sz   sC	D	4$$(( 0 1 		5/!&2>vvbhhveRVVHqLABCCCCj&a-Ej&!)YEj&!)UEqy$/!&2>j&UQYEj&QEj&HEdQh/!&2>j&U1HEj&1HEj&1Er2   c                    V P                  4        \        P                  ! R R.4      p\        P                  ! RR^^R7      p\        W!^R7       R# )gaz@gn4M;%?r   r   ry  N)r@  r4   ro   r   r  r   )rL   r\  r`  s   &  r0   test_noncentral_f_small_df(TestBroadcast.test_noncentral_f_small_df  s@    ((-/@AB$$S#qq9!&2>r2   c                    ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       R# )rb   ry  NrY   )g~}N??g$F?g'rS?)r   r"  r4   ro   r@  r   r   r\   )rL   r  bad_dfr"  r\  r`  s   &     r0   r#  TestBroadcast.test_chisquare  s_    S$$	(( 0 1 	26"!&2>j)aZ8r2   c                   ^.p^.pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        Wv^R7       \        \        WS^,          V4       \        \        WQ^,          V4       V P	                  4        V! W^,          4      p\        Wv^R7       \        \        WSV^,          4       \        \        WQV^,          4       R# )rb   ry  NrY   rd   )g w "@g2WR@gRY@)r   r  r4   ro   r@  r   r   r\   )rL   r  r  ra  rZ  nonc_chir\  r`  s   &       r0   r  'TestBroadcast.test_noncentral_chisquare  s    Ss4..(( 0 1 	"q&$'!&2>j(QJ=j(FH="Qh'!&2>j(D1H=j(1=r2   c                4   ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       \        \        \         P                  V^,          4       R# )rb   ry  NrY   )gT@g~Fl@gƚtp?)r   r  r4   ro   r@  r   r   r\   )rL   r  ra  tr\  r`  s   &     r0   r  TestBroadcast.test_standard_t  st    S(( 0 1 	26!&2>j!aZ0j&"3"3VaZ@r2   c                z   ^.p^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        We^R7       \        \        WA^,          V4       V P	                  4        V! W^,          4      p\        We^R7       \        \        WAV^,          4       R# )rc   ry  NrY   )gW!@gOBg}?)r   r  r4   ro   r@  r   r   r\   )rL   r  r  	bad_kappar  r\  r`  s   &      r0   r  TestBroadcast.test_vonmises  s    SD	??(( 1 2 	"q&%(!&2>j(FI>"ai(!&2>j(	A>r2   c                4   ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       \        \        \         P                  V^,          4       R# )rb   ry  NrY   )g&8??geFX?gՋː?)r   r  r4   ro   r@  r   r   r\   )rL   rA   rI  r  r\  r`  s   &     r0   r  TestBroadcast.test_pareto  sp    C(( 0 1 	A!&2>j&!)4j&--;r2   c                4   ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       \        \        \         P                  V^,          4       R# rM  )r   r0  r4   ro   r@  r   r   r\   )rL   rA   rI  r0  r\  r`  s   &     r0   r1  TestBroadcast.test_weibull-  sp    C..(( 1 2 	Q!&2>j'195j&..%!)<r2   c                4   ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       \        \        \         P                  V^,          4       R# )rb   ry  NrY   rC  )r   r  r4   ro   r@  r   r   r\   )rL   rA   rI  r  r\  r`  s   &     r0   r  TestBroadcast.test_power;  sp    C(( 1 2 	q1u!&2>j%3j&,,	:r2   c                z   ^ .p^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        We^R7       \        \        WA^,          V4       V P	                  4        V! W^,          4      p\        We^R7       \        \        WAV^,          4       R# )r   ry  NrY   )g:BKc?g3k?g~q?)r   rf  r4   ro   r@  r   r   r\   )rL   rZ  r?  rF  rf  r\  r`  s   &      r0   rg  TestBroadcast.test_laplaceI  s    cD	..(( 2 3 	q%(!&2>j'7I>ai(!&2>j'	A>r2   c                z   ^ .p^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        We^R7       \        \        WA^,          V4       V P	                  4        V! W^,          4      p\        We^R7       \        \        WAV^,          4       R# )r   ry  NrY   )g'Zy?gdSO=?g3L1?)r   r[  r4   ro   r@  r   r   r\   )rL   rZ  r?  rF  r[  r\  r`  s   &      r0   r\  TestBroadcast.test_gumbel\  s    cD	(( 1 2 	a'!&2>j&'9=QY'!&2>j&y1}=r2   c                   ^ .p^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        We^R7       \        \        WA^,          V4       V P	                  4        V! W^,          4      p\        We^R7       \        \        WAV^,          4       \        \         P                  ! RR4      R4       R# )r   ry  r  r   NrY   )gy?gJR?g
~&?)	r   rm  r4   ro   r@  r   r   r\   r
   )rL   rZ  r?  rF  rm  r\  r`  s   &      r0   rn  TestBroadcast.test_logistico  s    cD	??(( 2 3 	#'5)!&2>j(!GY?#qy)!&2>j(Q?V__S#.4r2   c                   ^ .p^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        We^R7       \        \        WA^,          V4       \        \        \         P                  V^,          V4       V P	                  4        V! W^,          4      p\        We^R7       \        \        WAV^,          4       \        \        \         P                  W^,          4       R# )r   ry  NrY   )gH"@gܮ @gvv	:@)r   rs  r4   ro   r@  r   r   r\   )rL   rq  rr  	bad_sigmars  r\  r`  s   &      r0   rt  TestBroadcast.test_lognormal  s    sD	$$	(( 0 1 	4!8U+!&2>j)AXyAj&"2"2D1HiH4+!&2>j)9q=Aj&"2"2Da-Hr2   c                    ^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT^R7       \        \        W2^,          4       R# )rb   ry  NrY   )gݱlo?g/ӂ?gz~R?)r   r  r4   ro   r@  r   r   r\   )rL   r?  rF  r  r\  r`  s   &     r0   r  TestBroadcast.test_rayleigh  s]    D	??(( 0 1 	%!)$!&2>j(M:r2   c                   R .p^.p^ .pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        Wv^R7       \        \        WS^,          V4       \        \        WQ^,          V4       \        \        \         P                  V^,          V4       \        \        \         P                  V^,          V4       V P	                  4        V! W^,          4      p\        Wv^R7       \        \        WSV^,          4       \        \        WQV^,          4       \        \        VR^4       \        \        VR R4       R# )rW   ry  r   Nrd   )g@m e?g`I߿?g|2?)r   r,  r4   ro   r@  r   r   r\   )rL   rq  r?  bad_meanrF  r,  r\  r`  s   &       r0   r-  TestBroadcast.test_wald  s   u3D	{{(( 0 1 	dQh&!&2>j$1e<j$q)<j&++x!|UCj&++taxCdAI&!&2>j$%!)<j$i!m<j$Q/j$S1r2   c                   ^.p^.p^.p^.p^.pV^,          w  rg\         P                  p\        P                  ! . RO4      p	V P	                  4        V! V^,          W24      p
\        W^R7       \        \        W^,          W24       \        \        W^,          WR4       \        \        W^,          VV4       V P	                  4        V! W^,          V4      p
\        W^R7       \        \        WV^,          V4       \        \        WV^,          V4       \        \        WV^,          V4       V P	                  4        V! WV^,          4      p
\        W^R7       \        \        WW2^,          4       \        \        WWR^,          4       \        \        WVV^,          4       \        \        VRRR4       \        \        VRRR4       \        \        VRRR4       R# )rb   ry        $@r   g      4@g      9@N)g,P;bD @g%G @g,~S @)r   r  r4   ro   r@  r   r   r\   )rL   r  r  r  bad_left_onebad_mode_onebad_left_twobad_mode_twor  r\  r`  s   &          r0   r  TestBroadcast.test_triangular  s   ssss%*QY"&&
(( 0 1 	D1Hd2!&2>j*Q.>Lj*QhLj*Q.>	 	D(E2!&2>j*D1HeLj*L14DeLj*L1<L	 	D	2!&2>j*D!)Lj*L!)Lj*Lai	! 	j*c2s;j*c3<j*c3<r2   c                >   ^.pR.pR.pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        W4       \        \        Wc^,          V4       \        \        Wa^,          V4       \        \        Wa^,          V4       V P	                  4        V! W^,          4      p\        W4       \        \        WcV^,          4       \        \        WaV^,          4       \        \        WaV^,          4       R# )rb   rW         ?NrY   rb   rb   rb   )r   r   r4   ro   r@  r	   r   r\   )	rL   r  r   bad_n	bad_p_one	bad_p_twobinomr\  r`  s	   &        r0   r  TestBroadcast.test_binomial  s    CED	E	((9%q1ua6+j%A6j%Q	:j%Q	:qa%6+j%A6j%IM:j%IM:r2   c                >   ^.pR.pR.pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          V4      p\        W4       \        \        Wc^,          V4       \        \        Wa^,          V4       \        \        Wa^,          V4       V P	                  4        V! W^,          4      p\        W4       \        \        WcV^,          4       \        \        WaV^,          4       \        \        WaV^,          4       R# )rb   rW   r  NrY   )rb   r   rb   )r   r   r4   ro   r@  r	   r   r\   )	rL   r  r   r  r  r  	neg_binomr\  r`  s	   &        r0   r   $TestBroadcast.test_negative_binomial  s    CED	E	,,	((9%1q5!$6+j)QY:j)UI>j)UI>1!e$6+j)AE:j)	A>j)	A>r2   c                d   \         P                  ! 4       P                  p^.pR.pV^,          .p\         P                  p\        P
                  ! . RO4      pV P                  4        V! V^,          4      p\        Wv4       \        \        WS^,          4       \        \        WT^,          4       R# )rb   NrY   )rb   rb   r   )
r   rI   _poisson_lam_maxr   r4   ro   r@  r	   r   r\   )rL   max_lamr  bad_lam_onebad_lam_twor   r\  r`  s   &       r0   r  TestBroadcast.test_poisson  s    $$&77cd{m..((9%q!6+j'?;j'?;r2   c           	        ^.p^ .p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        WT4       \        \        W2^,          4       \        P                  ! RR7      ;_uu_ 4        \        \        V\        P                  4       \        \        V^ ^ \        P                  .4       RRR4       R#   + '       g   i     R# ; i)rc   r  r  N)rc   rc   rb   )
r   r   r4   ro   r@  r	   r   r\   r  r   )rL   rA   rI  r   r\  r`  s   &     r0   r7  TestBroadcast.test_zipf$  s    C{{((9%a!e6+j$	2[[***dBFF3*dQ266N; +***s   ACC,	c                   R .pR.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        We4       \        \        WB^,          4       \        \        WC^,          4       R# )rW   r  NrY   r   )r   r   r4   ro   r@  r	   r   r\   )rL   r   r  r  geomr\  r`  s   &      r0   rQ  TestBroadcast.test_geometric2  sj    ED	E	((9%a!e6+j$A6j$A6r2   c                b   ^.p^.p^.pR.pR.p^ .p^.p\         P                  p\        P                  ! . RO4      p	V P	                  4        V! V^,          W#4      p
\        W4       \        \        W^,          W#4       \        \        W^,          WS4       \        \        W^,          W&4       \        \        W^,          W'4       V P	                  4        V! W^,          V4      p
\        W4       \        \        WV^,          V4       \        \        WV^,          V4       \        \        WV^,          V4       \        \        WV^,          V4       V P	                  4        V! WV^,          4      p
\        W4       \        \        WW#^,          4       \        \        WWS^,          4       \        \        WW&^,          4       \        \        WW'^,          4       \        \        VR^
^4       \        \        V^
R^4       \        \        V^
^
^ 4       \        \        V^
^
^4       R# )rb   NrY   rd   r  )r   r   r4   ro   r@  r	   r   r\   )rL   ngoodnbadnsample	bad_ngoodbad_nbadbad_nsample_onebad_nsample_two	hypergeomr\  r`  s   &          r0   rc  !TestBroadcast.test_hypergeometric?  s   s#D	4##))	((9%519d46+j)]DJj)QYJj)QYNj)QYN5(G46+j)q'Jj)HqL'Jj)D1HoNj)D1HoN5!46+j)kJj)HkJj)DA:MNj)DA:MNj)RR8j)RR8j)RQ7j)RR8r2   c                   R .p^.pR.p\         P                  p\        P                  ! . RO4      pV P	                  4        V! V^,          4      p\        We4       \        \        WB^,          4       \        \        WC^,          4       R# )rW   NrY   r  )r   r   r4   ro   r@  r	   r   r\   )rL   r   r  r  r   r\  r`  s   &      r0   rz  TestBroadcast.test_logseriesg  sk    EC	D	$$	((9%1q5!6+j)];j)];r2   rp  N)&r}   r~   r   r   r   r@  r  r  r  r:  r  rJ  rF  r  r^  r#  r  r  r  r  r1  r  rg  r\  rn  rt  r  r-  r  r  r   r  r7  rQ  rc  rz  r   r   r   s   @r0   r;  r;  *  s     ? >&6,><?,;,!FF?9>,A?&<=;?&>&5(I*;24&=P;.?.<<7&9P< <r2   r;  zcan't start threadrX  c                   >   a  ] tR tRt o R tR tR tR tR tRt	V t
R# )	
TestThreadiu  c                &    \        ^4      V n        R# )rl   N)rR   seedsr]   s   &r0   r   TestThread.setup_methodx  s    1X
r2   c           
     *   ^ RI Hp \        P                  ! \	        V P
                  4      3V,           4      p\        P                  ! \	        V P
                  4      3V,           4      p\        V P
                  V4       UUu. uF%  w  rgV! V\        P                  ! V4      V3R7      NK'  	  pppV U	u. uF  qP                  4       NK  	   p	V U	u. uF  qP                  4       NK  	   p	\        V P
                  V4       F"  w  rgV! \        P                  ! V4      V4       K$  	  \        P                  ! 4       P                  P                  ^8X  d#   \        P                  R8X  d   \!        WE4       R# \#        WE4       R# u uppi u up	i u up	i )r   )Thread)targetargswin32N)	threadingr  r4   r  r   r  zipr   rI   startjoinintpri   itemsizerK  platformr   r	   )
rL   functionszr  out1out2rM   org  r   s
   &&&       r0   check_functionTestThread.check_function{  s!   $xxTZZ*R/0xxTZZ*R/0 TZZ.0. 86+=+=a+@!*DE. 	
 0AqA1a1 

D)DAV''*A. * 779??##q(S\\W-D%d1t*0s   +F4FFc                2    R  pV P                  VRR7       R# )c                 0    V P                  R R7      VR&   R# )'  r   .N)r  r;   outs   &&r0   
gen_random*TestThread.test_normal.<locals>.gen_random  s    |||/CHr2   r  N)r  r  rL   r  s   & r0   r  TestThread.test_normal  s    	0 	J84r2   c                2    R  pV P                  VRR7       R# )c                 X    V P                  \        P                  ! R4      R7      VR&   R# )r   r>  .Nr   rG   )r9  r4   r  r  s   &&r0   r  'TestThread.test_exp.<locals>.gen_random  s"    ((rww{/C(DCHr2   r  Nr  r  r  s   & r0   test_expTestThread.test_exp  s    	E 	J;7r2   c                2    R  pV P                  VRR7       R# )c                 D    V P                  ^
R.^,          RR7      VR&   R# )rQ   r  r   .Nr  )r   r  s   &&r0   r  /TestThread.test_multinomial.<locals>.gen_random  s#    ((fX\(FCHr2   r  N)r  rn   r  r  s   & r0   r  TestThread.test_multinomial  s    	G 	J:6r2   )r  N)r}   r~   r   r   r   r  r  r  r  r   r   r   s   @r0   r  r  u  s#     +,587 7r2   r  c                   8   a  ] tR tRt o R tR tR tR tRtV t	R# )TestSingleEltArrayInputi  c                    \         P                  ! ^.4      V n        \         P                  ! ^.4      V n        \         P                  ! ^.4      V n        RV n        R# )rc   Nr  )r4   ro   argOneargTwoargThreetgtShaper]   s   &r0   r   $TestSingleEltArrayInput.setup_method  s<    hhsmhhsm!r2   c                p   \         P                  \         P                  \         P                  \         P                  \         P
                  \         P                  \         P                  \         P                  \         P                  \         P                  \         P                  \         P                  3p\         P                  \         P                  3pV FY  pW29   d   V! \        P                  ! R .4      4      pMV! V P                  4      p\!        VP"                  V P$                  4       K[  	  R# r   )r   r9  r  r"  r  r  r0  r  r  r   r   r   r   r4   ro   r  r
   r   r  )rL   funcs	probfuncsr  r  s   &    r0   test_one_arg_funcs*TestSingleEltArrayInput.test_one_arg_funcs  s    ##V%:%:!!6#4#4v!!6#3#35 %%v'7'78	D 288SE?+ 4;;'DMM2 r2   c                   \         P                  \         P                  \         P                  \         P                  \         P
                  \         P                  \         P                  \         P                  \         P                  \         P                  \         P                  \         P                  \         P                  \         P                  3p\         P                  \         P                  3pV F  pW29   d   \        P                   ! R .4      pMV P"                  pV! V P$                  V4      p\'        VP(                  V P*                  4       V! V P$                  ^ ,          V4      p\'        VP(                  V P*                  4       V! V P$                  V^ ,          4      p\'        VP(                  V P*                  4       K  	  R# r   )r   r  r  r  rI  rE  r  r  rf  r[  rm  rs  r,  r   r   r4   ro   r  r  r
   r   r  )rL   r  r  r  r  r  s   &     r0   test_two_arg_funcs*TestSingleEltArrayInput.test_two_arg_funcs  s   fll666&..!!6;;&":":< __f&>&>?	D 3% t{{F+CDMM2t{{1~v.CDMM2t{{F1I.CDMM2 r2   c                B   \         P                  \         P                  \         P                  .pV F  pV! V P                  V P
                  V P                  4      p\        VP                  V P                  4       V! V P                  ^ ,          V P
                  V P                  4      p\        VP                  V P                  4       V! V P                  V P
                  ^ ,          V P                  4      p\        VP                  V P                  4       K  	  R# r}  )
r   r  r  r   r  r  r  r
   r   r  )rL   r  r  r  s   &   r0   test_three_arg_funcs,TestSingleEltArrayInput.test_three_arg_funcs  s    $$f&7&7&&( Dt{{DKK?CDMM2t{{1~t{{DMMBCDMM2t{{DKKNDMMBCDMM2 r2   )r  r  r  r  N)
r}   r~   r   r   r   r  r  r  r   r   r   s   @r0   r  r    s     3&363 3r2   r  c                     \         P                  ! R 4       V w  rp\        \         V4      pV! VR^/ p\        VP                  \
        P                  ! R4      8H  4       R# )r=  r   rW  N)r   ru   getattrr   ri   r4   )r1   fnamer  rO  rE  r`  s   &     r0   test_integer_dtyper    sL    
KK	"EA1FFLLBHHSM)*r2   c                 R   \         P                  ! R 4       V w  rp\        \         V4      pV! VRR/ p\        P                  R8w  d   VP                  4       p\        P                  ! VP                  \        P                  4      4      P                  4       p\        Wc8H  4       R# )r=  r   r  rJ  N)r   ru   r  rK  rL  rM  rN  rO  rP  r4   rE  rQ  r   )r1   r  r  rO  rE  rS  rT  s   &      r0   test_integer_repeatr    sx    
KK	"EA
T
 
 C
}} lln
.."''*
+
5
5
7CCMr2   c                  "   \         P                  ! \        4      ;_uu_ 4        \        P                  ! ^RR.RR7       RRR4       \         P                  ! \        4      ;_uu_ 4        \        P                  ! ^^.RRR7       RRR4       \         P                  ! \        4      ;_uu_ 4        \        P                  ! ^^.RR.RR7       RRR4       R#   + '       g   i     L; i  + '       g   i     Lm; i  + '       g   i     R# ; i)rb   r  gffffff?r   N)rc   rb   )r   r   r\   r   r   r|   r2   r0   test_broadcast_size_errorr    s    	z	"	"C:F3 
#	z	"	"A&1 
#	z	"	"Ac
8 
#	"	 
#	"	"	"	"	"	"s#   C)C*/C=C'	*C:	=D	c                  t   \         P                  P                  \        ^ 4      4      p V P	                  ^4       V P                  4       w  rpV^ ,          P                  P                  R8X  g   Q hV! R!  pVP                  V4       VP                  RR7      p\        VR,          VR,          4       \        VR,          R,          VR,          R,          4       \        VR,          R,          VR,          R,          4       \        VR,          VR,          4       \        VR	,          VR	,          4       R
# )r   r   Fr   r:   r;   r<   r=   r>   r?   N)r   )r4   r   rI   r   r   
__reduce__	__class__r}   r   r   r
   r	   )rv   ctorr  state_arB   state_bs         r0   &test_randomstate_ctor_old_style_pickler    s    			wqz	*Bq--/D7%%222lAKKkkk'G)7?+CDww'.0@0GHww'.0@0GH%w{';<!77#34r2   c                 v   \         P                  P                  ^ 4      pVP                  p\         P                  P	                  V4       \        \         P                  P                  P                  P                  \        V4      4      '       g   Q h\         P                  P                  4       pW#J g   Q hR# r}  )r4   r   default_rngr:   r6   r   mtrand_rand_bit_generatorrf  r5   )r8   def_bgbg	second_bgs   &   r0   test_hot_swapr     s|    YY""1%F			BII#bii&&,,;;T"XFFFF		++-I??r2   c                    \        ^ 4      p\        P                  P                  V4       \        P                  P	                  RR7      p\        P                  P                  ^4       \        P                  P	                  RR7      p\        V4       \        V4       VR,          R8X  g   Q hVR,          R,          VR,          R,          8w  g   Q hVR,          R,          VR,          R,          8w  g   Q hR# )r   Fr   r:   r   r;   incN)r   r4   r   r6   r   ru   print)r8   r  r;   r  s   &   r0   test_seed_alt_bit_genr  $  s    	qBII#IIu-EIINN1		##5#1I	%L	)!W,,,>'"i&8&AAAA>% Ig$6u$====r2   c                 V   \         P                  P                  4       p\        ^ 4      p\         P                  P	                  V4       \
        P                  ! \        RR7      ;_uu_ 4        \         P                  P                  V4       RRR4       R#   + '       g   i     R# ; i)r   zstate must be for a PCG64r   N)	r4   r   r   r   r6   r   r   r\   r   )r8   r;   r  s   &  r0   test_state_error_alt_bit_genr  2  sc    II!E	qBII#	z)D	E	E
		E" 
F	E	E	Es   - BB(	c                    \         P                  P                  R 4       \         P                  P                  ^ R^
4      p\	        ^ 4      pVP
                  p\         P                  P                  V4       \         P                  P                  RR7      pV F  pW5,          WE,          8X  d   K  Q h	  \         P                  P                  R 4       \         P                  P                  ^ R^
4      p\         P                  ! W8H  4      '       d   Q hVP
                  pVR,          R,          VR,          R,          8w  g   Q hVR,          R,          VR,          R,          8X  g   Q hR# )́ Fr   r;   r  N   @)	r4   r   ru   rJ   r   r;   r6   r   r   )r8   r;  r  r;   state_directfieldpcg_valsr  s   &       r0   test_swap_workedr  ;  s   IINN599Q,D	qBHHEII#99&&e&4L||2222 IINN5yy  GR0Hvvd&''''IWg&%.*AAAAWe$	'(:5(AAAAr2   c                 $   \         P                  P                  \        R 4      4       \         P                  P	                  ^ R^
4      p\         P                  P                  \        R 4      4      pVP	                  ^ R^
4      p\        W14       R# )r  Nr	  )r4   r   r6   r   rJ   rI   r
   )r8   singleton_valsrgnon_singleton_valss   &   r0   %test_swapped_singleton_against_directr  M  sd    IIe-YY&&q'26N			uU|	,BAw3#4r2   )g      Y@g333333?)rW   )r  r  rQ   )r   rW   )r  )rc   ra   )3rN  r  rK  r  r   numpyr4   r   numpy.randomr   r   numpy.testingr   r   r   r	   r
   r   r   r   r   r  r-   r%  rd  r'  r.   fixturer1   r8   rC   rE   r   r   r   r  rn  r;  rk  rl  r  r  r  r  r  r  r   r  r  r  r  r|   r2   r0   <module>r     s     
     '
 
 
 %|%Rc!12 )T	 88BGG5 !,n",n",n',n$,n*,n ,n,nO ",n",n',n",n$,n*,n ,n,nO hy1, 2,
 - -),? ,?^> >6. 6.pTJ TJna+ a+Hh, h,VH	< H	<V G$89+7 +7 :+7^A3 A3J+95$>#B$5r2   