예제 #1
0
파일: mode.py 프로젝트: naisanza/Theano
 def apply(self, fgraph):
     for o in fgraph.outputs:
         try:
             fgraph.replace_validate(
                 o, _output_guard(o), reason='output_guard')
             _logger.info("Output variable %s required output_guard, "
                          "how was this output left unprotected against "
                          "destructive operations?" % o)
         except gof.InconsistencyError:
             # This output is already impossible to destroy.
             # No guard necessary
             pass
예제 #2
0
파일: mode.py 프로젝트: zmdfwh/Theano
 def apply(self, fgraph):
     for o in fgraph.outputs:
         try:
             fgraph.replace_validate(o,
                                     _output_guard(o),
                                     reason='output_guard')
             _logger.info("Output variable %s required output_guard, "
                          "how was this output left unprotected against "
                          "destructive operations?" % o)
         except gof.InconsistencyError:
             # This output is already impossible to destroy.
             # No guard necessary
             pass