• James Bergstra's avatar
    Several related fixes: · 28aedba1
    James Bergstra 提交于
    - added allow_gc option to PerformLinker and OpWiseCLinker, which results in
      temporary results being freed as soon as possible.  This can have a negative
      impact on performance (we have to re-allocate outputs) but allows us to
      evaluate graphs piecewise, even if not all temporaries fit in memory at
      once.
    
    - modified Function so that internal references to `required` input arguments
      and computed output arguments are removed after a call.  This means that
      these values are not stored by pickle.
    
    - modified MergeOptimizer to use a more efficient algorithm.  The previous one
      was at best quadratic in depth, and at worst exponential in depth.  The new
      one should be worst-case linear.
    28aedba1
function_module.py 31.0 KB