
    
9jB                    *    S SK Jr  S SKrS SKrSS jrg)    )annotationsNc                   U c+  [         R                  " 5       R                  nUR                  n / n0 n[	        U R                  5       5       H  n[        X   [        R                  5      (       d  M&  X   n[        U5      nXcR                  5       ;   a  SR                  XCU   5      nSnOXCU'   UnSnSR                  [        [        UR                  5      5      n	[        UR                  5      n
UR!                  XyXR"                  R$                  U/5        M     SnSnSnSn['        [)        U5      5       H  nX/   nU[)        US   5      :  a  [)        US   5      nU[)        US   5      :  a  [)        US   5      nU[)        US   5      :  a  [)        US   5      nUS   (       d  Ms  U[+        US   5      -  nM     [)        U5      S:  aj  [-        SU5      n[-        SU5      n[-        SU5      nS	R                  US
-  US
-  US
-  5      n[/        SR                  US[)        U5      S-   -  5      5        ['        [)        U5      5       Hr  nX/   n[/        SR                  US   S
W[)        US   5      -
  S-   -  US   S
W[)        US   5      -
  S-   -  US   S
W[)        US   5      -
  S-   -  US   5      5        Mt     [/        SR                  U5      5        g)a  Print the CuPy arrays in the given dictionary.

Prints out the name, shape, bytes and type of all of the ndarrays
present in `vardict`.

If there is no dictionary passed in or `vardict` is None then returns
CuPy arrays in the globals() dictionary (all CuPy arrays in the
namespace).

Args:
    vardict : (None or dict)  A dictionary possibly containing ndarrays.
              Default is globals() if `None` specified


.. admonition:: Example

    >>> a = cupy.arange(10)
    >>> b = cupy.ones(20)
    >>> cupy.who()
    Name            Shape            Bytes            Type
    ===========================================================
    <BLANKLINE>
    a               10               80               int64
    b               20               160              float64
    <BLANKLINE>
    Upper bound on total bytes  =       240
    >>> d = {'x': cupy.arange(2.0),
    ... 'y': cupy.arange(3.0), 'txt': 'Some str',
    ... 'idx':5}
    >>> cupy.who(d)
    Name            Shape            Bytes            Type
    ===========================================================
    <BLANKLINE>
    x               2                16               float64
    y               3                24               float64
    <BLANKLINE>
    Upper bound on total bytes  =       40

Nz{} ({})r      z x       
   zName {} Shape {} Bytes {} Type z{}
{}
=   z{} {} {} {} {} {} {}   z'
Upper bound on total bytes  =       {})sys	_getframef_back	f_globalssortedkeys
isinstancecupyndarrayidformatjoinmapstrshapenbytesappenddtypenamerangelenintmaxprint)vardictframestacacher   varidvnamestroriginalshapestrbytestrmaxnamemaxshapemaxbyte
totalbyteskvalsp1sp2sp3prvals                        H/home/wildlama/miniconda3/lib/python3.13/site-packages/cupy/_misc/who.pywhor:      s   T &&//
CEw||~&gmT\\22-CS'Cjjl"#**4s<!c
zz#c399"56H#**oGJJGYY^^XF '" GHGJ3s8_fSQ[ #a&kGc#a&k!3q6{HSQ[ #a&kGq66#c!f+%J  3x!|"g"h"g077#IsSy#)
 	jsc%j1n'=>?3s8_f"))AsSQ[(1,-AsSQ[(1,-AsSQ[(1,-A
	
  

4
;
;J
GH    )N)
__future__r   r   r   r:    r;   r9   <module>r>      s    " 
 eIr;   