
    Ph                         d dl Z d dlZd dlZd dlmZmZmZ  ej                  d      Z	e	dne	j                  d      Z G d d      Zy)    N)assert_assert_raisesIS_WASMHOST_GNU_TYPEFgnueabic                   $   e Zd Zej                  j                  ed      ej                  j                  ed      d               Zej                  j                  ed      ej                  j                  ed      d               Z	d Z
d Zy	)
TestErrstatezfp errors don't work in wasm)reasonz+platform/cpu issue with FPU (gh-413,-15562)c                 z   t        j                  dd      5  t        j                  d       }t        j                  d      5  t        j                  |       d d d        t	        t
              5  t        j                  |       d d d        d d d        y # 1 sw Y   ?xY w# 1 sw Y   xY w# 1 sw Y   y xY w)Nraiseignoreallunder   )invalid)nperrstatearangesqrtr   FloatingPointErrorselfas     iC:\Users\daisl\Desktop\realtime-object-detection\venv\Lib\site-packages\numpy/core/tests/test_errstate.pytest_invalidzTestErrstate.test_invalid   s{     [[WH51AX.
 / 12
 3 65 /. 32 65s;   -B1BB12B%B1B"	B1%B.	*B11B:z&platform/cpu issue with FPU (gh-15562)c                    t        j                  dd      5  t        j                  d       }t        j                  d      5  |dz   d d d        t        t              5  |dz   d d d        t        t              5  ||z   d d d        d d d        y # 1 sw Y   LxY w# 1 sw Y   ;xY w# 1 sw Y   *xY w# 1 sw Y   y xY w)Nr   r   r   r   )divider   )r   r   r   r   r   r   s     r   test_dividezTestErrstate.test_divide   s     [[WH51AH-Q . 12Q 3 12Q 3 65 .- 32 32 65sS   -B:BB:"B"(B:?B.B:B	B:"B+	'B:.B7	3B::Cc                    d }t        j                         }t        j                  |      5  t        t        j                         |u d       t        j                  d       5  t        t        j                         d u d       d d d        d d d        t        t        j                         |u d       y # 1 sw Y   2xY w# 1 sw Y   6xY w)Nc                      t        |        y )N)print)argss    r   fooz&TestErrstate.test_errcall.<locals>.foo-   s	    $K    )callzcall is not foozcall is not Nonezcall is not olderrcall)r   
geterrcallr   r   )r   r$   
olderrcalls      r   test_errcallzTestErrstate.test_errcall,   s    	 ]]_
[[c"BMMOs*,=>$'4/1CD ( # 	:-/GH (' #"s#   7C%!B7C7C 	<CCc                 J    t        j                  d      d        } |        y )Nr   )r   c                  :    t        j                  d       } | dz   y )Nr   r   )r   r   )r   s    r   r$   z1TestErrstate.test_errstate_decorator.<locals>.foo8   s    1AFr%   )r   r   )r   r$   s     r   test_errstate_decoratorz$TestErrstate.test_errstate_decorator7   s$    		"	 
#	 	r%   N)__name__
__module____qualname__pytestmarkskipifr   arm_softfloatr   r   r)   r,    r%   r   r	   r	      s    [[(FG[[L  NN H [[(FG[[G  II H	Ir%   r	   )r0   	sysconfignumpyr   numpy.testingr   r   r   get_config_varhosttypeendswithr3   r	   r4   r%   r   <module>r;      sI       9 9 $9##O4!)x/@/@/K/ /r%   