
    giZ                        d Z ddlmZmZmZmZmZmZmZm	Z	m
Z
mZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZ ddlmZ  ed       G d d             Ze dk(  r e ed      d	      Z! ee!      Z" e# e$e"              e# ee"      e"j0                         e"d
dd
df   Z% e#e%       de%d<    e#e%d   e"d           e# ee%      dz  dz   ee%dz        z           e# ee%d       e& ee%d                    e# e&e% e ed       ee%            z                e# ee%d              e# ee%             y
y
)a7  
Container class for backward compatibility with NumArray.

The user_array.container class exists for backward compatibility with NumArray
and is not meant to be used in new code. If you need to create an array
container class, we recommend either creating a class that wraps an ndarray
or subclasses ndarray.

    )absoluteaddarangearrayasarraybitwise_and
bitwise_orbitwise_xordivideequalgreatergreater_equalinvert
left_shiftless
less_equalmultiply	not_equalpower	remainderreshaperight_shiftshapesinsqrtsubtract	transpose)
set_moduleznumpy.lib.user_arrayc                      e Zd ZdZd@dZdAdZd ZdBdZd Zd Z	d	 Z
d
 Zd Zd ZeZd Zd Zd Zd Zd ZeZd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Zd Z d Z!d Z"d  Z#d! Z$d" Z%d# Z&d$ Z'd% Z(d& Z)d' Z*d( Z+d) Z,d* Z-d+ Z.d, Z/d- Z0d. Z1d/ Z2d0 Z3d1 Z4d2 Z5d3 Z6d4 Z7d5 Z8d6 Z9d7 Z:d8 Z;d9 Z<d: Z=d; Z>d< Z?d= Z@d> ZAd? ZBy)C	containerz
    container(data, dtype=None, copy=True)

    Standard container-class for easy multiple-inheritance.

    Methods
    -------
    copy
    byteswap
    astype

    Nc                 <    dd l }|j                  dt        d       y )Nr   z_The numpy.lib.user_array.container class is deprecated and will be removed in a future version.   )
stacklevel)warningswarnDeprecationWarning)clsr$   s     R/var/www/html/audio_env/lib/python3.12/site-packages/numpy/lib/_user_array_impl.py__init_subclass__zcontainer.__init_subclass__8   s!    +	 	 	
    c                 *    t        |||      | _         y )N)copy)r   )selfdatadtyper,   s       r(   __init__zcontainer.__init__C   s    4T2
r*   c                     | j                   dkD  r8| j                  j                  t        | j                        t        d      d  z   S | j                  j                  dz   t        | j                        z   dz   S )Nr   r   ())ndim	__class____name__reprr   lenr-   s    r(   __repr__zcontainer.__repr__F   s^    99q=>>**T$**-=c'lm-LLL>>**S04

3CCcIIr*   c                 T    |r| j                   j                  |      S | j                   S N)r   astype)r-   ts     r(   	__array__zcontainer.__array__L   s$    ::$$Q''zzr*   c                 ,    t        | j                        S r<   )r8   r   r9   s    r(   __len__zcontainer.__len__R   s    4::r*   c                 >    | j                  | j                  |         S r<   _rcr   )r-   indexs     r(   __getitem__zcontainer.__getitem__U   s    xx

5)**r*   c                 J    t        || j                        | j                  |<   y r<   )r   r/   r   )r-   rE   values      r(   __setitem__zcontainer.__setitem__X   s    #E4::6

5r*   c                 J    | j                  t        | j                              S r<   )rD   r   r   r9   s    r(   __abs__zcontainer.__abs__[   s    xx,--r*   c                 :    | j                  | j                         S r<   rC   r9   s    r(   __neg__zcontainer.__neg__^   s    xx$$r*   c                 P    | j                  | j                  t        |      z         S r<   rD   r   r   r-   others     r(   __add__zcontainer.__add__a       xx

WU^344r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __iadd__zcontainer.__iadd__f   s    DJJtzz*r*   c                 P    | j                  | j                  t        |      z
        S r<   rO   rP   s     r(   __sub__zcontainer.__sub__j   rS   r*   c                 P    | j                  t        |      | j                  z
        S r<   )rD   r   r   rP   s     r(   __rsub__zcontainer.__rsub__m   s    xx344r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __isub__zcontainer.__isub__p       UDJJ/r*   c                 ^    | j                  t        | j                  t        |                  S r<   )rD   r   r   r   rP   s     r(   __mul__zcontainer.__mul__t   s     xxWU^<==r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __imul__zcontainer.__imul__y   r\   r*   c                 L    | j                  t        | j                  |            S r<   rD   r   r   rP   s     r(   __mod__zcontainer.__mod__}       xx	$**e455r*   c                 L    | j                  t        || j                              S r<   rb   rP   s     r(   __rmod__zcontainer.__rmod__   s    xx	%455r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __imod__zcontainer.__imod__   s    $**eTZZ0r*   c                     | j                  t        | j                  |            | j                  t        | j                  |            fS r<   rD   r   r   r   rP   s     r(   
__divmod__zcontainer.__divmod__   s:    

E234::u568 	8r*   c                     | j                  t        || j                              | j                  t        || j                              fS r<   rj   rP   s     r(   __rdivmod__zcontainer.__rdivmod__   s:    tzz235$**568 	8r*   c                 ^    | j                  t        | j                  t        |                  S r<   )rD   r   r   r   rP   s     r(   __pow__zcontainer.__pow__   s     xxdjj'%.9::r*   c                 ^    | j                  t        t        |      | j                              S r<   )rD   r   r   r   rP   s     r(   __rpow__zcontainer.__rpow__   s     xxgendjj9::r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __ipow__zcontainer.__ipow__   s    djj%,r*   c                 L    | j                  t        | j                  |            S r<   rD   r   r   rP   s     r(   
__lshift__zcontainer.__lshift__       xx
4::u566r*   c                 L    | j                  t        | j                  |            S r<   rD   r   r   rP   s     r(   
__rshift__zcontainer.__rshift__       xxDJJ677r*   c                 L    | j                  t        || j                              S r<   ru   rP   s     r(   __rlshift__zcontainer.__rlshift__       xx
5$**566r*   c                 L    | j                  t        || j                              S r<   ry   rP   s     r(   __rrshift__zcontainer.__rrshift__       xxE4::677r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __ilshift__zcontainer.__ilshift__       4::udjj1r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __irshift__zcontainer.__irshift__       DJJtzz2r*   c                 L    | j                  t        | j                  |            S r<   rD   r   r   rP   s     r(   __and__zcontainer.__and__   r{   r*   c                 L    | j                  t        || j                              S r<   r   rP   s     r(   __rand__zcontainer.__rand__   r   r*   c                 H    t        | j                  || j                         | S r<   )r   r   rP   s     r(   __iand__zcontainer.__iand__   r   r*   c                 L    | j                  t        | j                  |            S r<   rD   r
   r   rP   s     r(   __xor__zcontainer.__xor__   r{   r*   c                 L    | j                  t        || j                              S r<   r   rP   s     r(   __rxor__zcontainer.__rxor__   r   r*   c                 H    t        | j                  || j                         | S r<   )r
   r   rP   s     r(   __ixor__zcontainer.__ixor__   r   r*   c                 L    | j                  t        | j                  |            S r<   rD   r	   r   rP   s     r(   __or__zcontainer.__or__   rw   r*   c                 L    | j                  t        || j                              S r<   r   rP   s     r(   __ror__zcontainer.__ror__   r~   r*   c                 H    t        | j                  || j                         | S r<   )r	   r   rP   s     r(   __ior__zcontainer.__ior__   r   r*   c                 8    | j                  | j                        S r<   rC   r9   s    r(   __pos__zcontainer.__pos__   s    xx

##r*   c                 J    | j                  t        | j                              S r<   )rD   r   r   r9   s    r(   
__invert__zcontainer.__invert__   s    xxtzz*++r*   c                 L    | j                   dk(  r || d         S t        d      )Nr   z6only rank-0 arrays can be converted to Python scalars.)r4   	TypeError)r-   funcs     r(   _scalarfunczcontainer._scalarfunc   s-    99>Q= HJ Jr*   c                 ,    | j                  t              S r<   )r   complexr9   s    r(   __complex__zcontainer.__complex__   s    ((r*   c                 ,    | j                  t              S r<   )r   floatr9   s    r(   	__float__zcontainer.__float__   s    &&r*   c                 ,    | j                  t              S r<   )r   intr9   s    r(   __int__zcontainer.__int__       $$r*   c                 ,    | j                  t              S r<   )r   hexr9   s    r(   __hex__zcontainer.__hex__   r   r*   c                 ,    | j                  t              S r<   )r   octr9   s    r(   __oct__zcontainer.__oct__   r   r*   c                 L    | j                  t        | j                  |            S r<   )rD   r   r   rP   s     r(   __lt__zcontainer.__lt__   s    xxTZZ/00r*   c                 L    | j                  t        | j                  |            S r<   )rD   r   r   rP   s     r(   __le__zcontainer.__le__   rw   r*   c                 L    | j                  t        | j                  |            S r<   )rD   r   r   rP   s     r(   __eq__zcontainer.__eq__   s    xxdjj%011r*   c                 L    | j                  t        | j                  |            S r<   )rD   r   r   rP   s     r(   __ne__zcontainer.__ne__   rd   r*   c                 L    | j                  t        | j                  |            S r<   )rD   r   r   rP   s     r(   __gt__zcontainer.__gt__   s    xx

E233r*   c                 L    | j                  t        | j                  |            S r<   )rD   r   r   rP   s     r(   __ge__zcontainer.__ge__   s    xxdjj%899r*   c                 T    | j                  | j                  j                               S  )rD   r   r,   r9   s    r(   r,   zcontainer.copy   s    xx

)**r*   c                 6    | j                   j                         S r   )r   tobytesr9   s    r(   r   zcontainer.tobytes   s    zz!!##r*   c                 T    | j                  | j                  j                               S r   )rD   r   byteswapr9   s    r(   r   zcontainer.byteswap  s    xx

++-..r*   c                 V    | j                  | j                  j                  |            S r   )rD   r   r=   )r-   typecodes     r(   r=   zcontainer.astype  s     xx

))(344r*   c                 V    t        t        |            dk(  r|S | j                  |      S Nr   )r8   r   r5   )r-   as     r(   rD   zcontainer._rc	  s&    uQx=AH>>!$$r*   c                 *    | j                  |d         S r   )r5   )r-   argss     r(   __array_wrap__zcontainer.__array_wrap__  s    ~~d1g&&r*   c                     |dk(  rt         j                  | ||       y 	 | j                  j                  ||       y # t        $ r t         j                  | ||       Y y w xY wNr   )object__setattr__r   AttributeError)r-   attrrH   s      r(   r   zcontainer.__setattr__  sX    7?tT51	2JJ""4/ 	2tT51	2s   <  AAc                 n    |dk(  rt         j                  | |      S | j                  j                  |      S r   )r   __getattribute__r   )r-   r   s     r(   __getattr__zcontainer.__getattr__  s1    GO**466zz**400r*   )returnN)NTr<   )Cr6   
__module____qualname____doc__r)   r0   r:   r?   rA   rF   rI   rK   rM   rR   __radd__rU   rW   rY   r[   r^   __rmul__r`   rc   rf   rh   rk   rm   ro   rq   rs   rv   rz   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=   rD   r   r   r    r*   r(   r    r    *   sH   	
3J+7.%5 H55> H6688;;7878888877$,J)'%%%17264:+$/5%'21r*   r    __main__i'  )d   r   N      
   )r   r   g      @g      @r"   g      )r   r   )'r   numpy._corer   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   numpy._core.overridesr   r    r6   tempuaprintdirua_smalltyper   r*   r(   <module>r      sT         : - "#t1 t1 $t1t z6%=*-D	4B	#b'N	%)RXX"1"bqb&zH	(OHTN	(4."T(#	#h-"
r
!DQ$7
78	$x
tD3$789	$x'&*eHo>>
?@	'(F
#$	)H
# r*   