U
    ,‰d[  ã                   @   sH   d dl Z d dlmZ d dlmZmZ G dd„ deƒZedkrDe ¡  dS )é    N)Úcuda)ÚunittestÚCUDATestCasec                   @   s   e Zd Zdd„ ZdS )ÚTestCudaMonteCarloc                 C   s   t  d¡dd„ ƒ}dS )z+Just make sure we can compile this
        z=void(double[:], double[:], double, double, double, double[:])c                 S   sJ   t  d¡}||jd krd S || }| | t || ||  ¡ ||< d S )Né   r   )r   ZgridÚshapeÚmathÚexp)ÚlastÚpathsÚdtZc0Zc1ZnormdistÚiZnoise© r   úK/tmp/pip-unpacked-wheel-eu7e0c37/numba/cuda/tests/cudapy/test_montecarlo.pyÚstep   s
    
z0TestCudaMonteCarlo.test_montecarlo.<locals>.stepN)r   Zjit)Úselfr   r   r   r   Útest_montecarlo   s    ÿz"TestCudaMonteCarlo.test_montecarloN)Ú__name__Ú
__module__Ú__qualname__r   r   r   r   r   r      s   r   Ú__main__)	r   Znumbar   Znumba.cuda.testingr   r   r   r   Úmainr   r   r   r   Ú<module>   s
   