U
    9%e                     @   s   d dl Z d dlmZ d dlmZ d dlmZ d dlm	Z	 eege	f eege	f dddZ
eeege	f eeege	f dd	d
ZdS )    N)Callable)'NativeFunctionWithDifferentiabilityInfo)native_function_manager)T)funcreturnc                    s"   t  ttd fdd}|S )N)fr   c              
      s*   t | j  | W  5 Q R  S Q R X d S Nr   r   )r   r    a/var/www/html/Darija-Ai-API/env/lib/python3.8/site-packages/torchgen/packaged/autograd/context.pywrapper   s    zAwith_native_function_with_differentiability_info.<locals>.wrapper)	functoolswrapsNFWDIr   r   r   r   r   r   0with_native_function_with_differentiability_info   s    r   c                    s$   t  tttd fdd}|S )N)r   keyr   c              
      s,   t | j  | |W  5 Q R  S Q R X d S r	   r
   )r   r   r   r   r   r      s    zIwith_native_function_with_differentiability_info_and_key.<locals>.wrapper)r   r   r   strr   r   r   r   r   8with_native_function_with_differentiability_info_and_key   s    r   )r   typingr   Ztorchgen.api.autogradr   r   Ztorchgen.contextr   Ztorchgen.utilsr   r   r   r   r   r   r   r   <module>   s   