§
    dŠtj6  ã                   óÜ  — d Z ddlZddlZddlZddlZddlmZ ddlmZm	Z	 	 ddl
Z
n# e$ r dZ
Y nw xY w eed¦  «        Z ej        d¦  «        o ej        ¦   «          Z	 ddlZd„ Zn# e$ r d„ ZdZY nw xY w	 dd	lmZ d
„ Zd„ Zn# e$ r
 d„ ZdxZZY nw xY w e	edu d¬¦  «        Z e	ej                             d¦  «         d¬¦  «        Z e	e
du d¬¦  «        Z e	e
dud¬¦  «        ZdS )z
Small utilities for testing.
é    N)Úmp)ÚSkipTestÚskipifÚpypy_version_infoÚPy_GIL_DISABLEDc                 ó   — | S )ú*A decorator to skip tests requiring numpy.© ©Úfuncs    úP/var/www/html/CA-Chatbot/venv/lib/python3.11/site-packages/joblib/test/common.pyÚ
with_numpyr      ó   € àˆó    c                 ó   — d„ }|S )r	   c                  ó    — t          d¦  «        ‚)NzTest requires numpy©r   r
   r   r   Úmy_funczwith_numpy.<locals>.my_func%   s   € ÝÐ0Ñ1Ô1Ð1r   r
   )r   r   s     r   r   r   "   s   € ð	2ð 	2ð 	2ð ˆr   )Úmemory_usagec                 ó   — | S )ú4A decorator to skip tests requiring memory_profiler.r
   r   s    r   Úwith_memory_profilerr   3   r   r   c                 óŽ   — t          j        ¦   «          t          | ||fd¬¦  «        }t          |¦  «        t	          |¦  «        z
  S )z)Compute memory usage when executing func.gü©ñÒMbP?)Úinterval)ÚgcÚcollectr   ÚmaxÚmin)r   ÚargsÚkwargsÚmem_uses       r   Úmemory_usedr"   7   s=   € å
Œ
‰ŒˆÝ  d¨FÐ3¸eÐDÑDÔDˆÝ�7‰|Œ|�c '™lœlÑ*Ð*r   c                 ó   — d„ }|S )r   c                  ó    — t          d¦  «        ‚)NzTest requires memory_profiler.r   r
   r   r   Ú
dummy_funcz(with_memory_profiler.<locals>.dummy_funcB   s   € ÝÐ;Ñ<Ô<Ð<r   r
   )r   r%   s     r   r   r   ?   s   € ð	=ð 	=ð 	=ð Ðr   zNeeds multiprocessing to run.)Úreasonz/dev/shmz5This test requires a large /dev/shm shared memory fs.zNeeds lz4 compression to runz$Needs lz4 not being installed to run)Ú__doc__r   ÚosÚsysÚ	sysconfigÚjoblib._multiprocessing_helpersr   Újoblib.testingr   r   Úlz4ÚImportErrorÚhasattrÚIS_PYPYÚget_config_varÚ_is_gil_enabledÚIS_GIL_DISABLEDÚnumpyÚnpr   Úmemory_profilerr   r   r"   Úwith_multiprocessingÚpathÚexistsÚwith_dev_shmÚwith_lz4Úwithout_lz4r
   r   r   ú<module>r=      s)  ððð ð 
€	€	€	Ø 	€	€	€	Ø 
€
€
€
Ø Ð Ð Ð à .Ð .Ð .Ð .Ð .Ð .Ø +Ð +Ð +Ð +Ð +Ð +Ð +Ð +ðØ€J€J€J€JøØð ð ð Ø
€C€C€Cðøøøð ˆ'�#Ð*Ñ
+Ô
+€à€IÔÐ.Ñ/Ô/ÐMÐ8K¸Ô8KÑ8MÔ8MÐ4Mð ð
ØÐÐÐðð ð ð øð ð 
ð 
ð 
ðð ð ð 
€B€B€Bð
øøøð &Ø,Ð,Ð,Ð,Ð,Ð,ðð ð ð+ð +ð +ð +øð ð 
&ð 
&ð 
&ðð ð ð "&Ð%€L�;�;�;ð
&øøøð �v˜b D˜jÐ1PÐQÑQÔQÐ ð ˆvØ
Œ�Š�zÑ"Ô"Ð"ØBðñ ô €ð
 ˆ6�#˜�+Ð&DÐEÑEÔE€àˆf�S �_Ð-SÐTÑTÔT€€€s0   ¢' §1°1Á!A) Á)
A6Á5A6Á:B ÂBÂB