ó
àÆ÷Xc           @` sx   d  d l  m Z m Z m Z d  d l Z d  d l Z d  d l Z d  d l j	 Z
 d Z d „  Z e d k rt e ƒ  n  d S(   i    (   t   absolute_importt   print_functiont   divisionNt   float32c          C` s  t  j j d }  t j d |  ƒ t  j j } | d k rB d } n  t  j j } z°t t  j _ t j	 d ƒ } t j	 d ƒ } t  j
 t j d d	 t ƒƒ } t  j
 t j d d	 t ƒƒ } t j t j t j | d
 | ƒ | ƒ | ƒ } t  j | | g | d | ƒ} t j	 d ƒ }	 t j	 d ƒ }
 t  j
 t j d d	 t ƒƒ } t  j
 t j d d	 t ƒƒ } t j t j t j |	 d
 |
 ƒ | ƒ | ƒ } t  j |	 |
 g | d | ƒ} t j d d	 t ƒ} t j d d	 t ƒ} | | | ƒ | | | ƒ k sýt ‚ Wd  | t  j _ Xd  S(   Ns   /optimized_graphs.pkls   rm %st
   DEBUG_MODEt	   DebugModet   FAST_RUNt   at   bi
   t   dtypei   t   modet   x1t   x2(   R   R   (   i
   i
   (   i
   i
   (   i
   i
   (   i
   i
   (   i
   i
   (   i
   i
   (   t   theanot   configt
   compiledirt   ost   systemR
   t   cache_optimizationst   Truet   Tt   fmatrixt   sharedt   npt   onest   floatXt   sumt   functiont   AssertionError(   t   opt_db_fileR
   t   defaultR   R   t   ct   dt   et   f1t   mt   nt   pt   qt   jt   f2t   in1t   in2(    (    sG   /tmp/pip-build-X4mzal/theano/theano/gof/tests/test_graph_opt_caching.pyt   test_graph_opt_caching
   s0    	11(t   __main__(   t
   __future__R    R   R   R   t   numpyR   R   t   theano.tensort   tensorR   R   R+   t   __name__(    (    (    sG   /tmp/pip-build-X4mzal/theano/theano/gof/tests/test_graph_opt_caching.pyt   <module>   s   	