• David Warde-Farley's avatar
    Remove annoying raise_with_op behaviour, document. · cefc5553
    David Warde-Farley 提交于
    This adds a docstring for raise_with_op and also modifies its behaviour
    somewhat. Previously, the exception was re-raised with a different
    'args' member -- namely, in addition to the exception message it added
    two new elements to the tuple: the Op itself and a string telling you
    where in the graph the corresponding Apply node appeared.
    
    This gets in the way if you want to have an exception message containing
    formatting (newlines and tabs), since the entire tuple is printed, and
    the formatting on the string is not rendered.
    
    I've never seen the Apply node index be of use to anyone debugging, but
    my proposed solution is to stash that information in __op_instance__
    and __applynode_index__ on the object instead of in the args tuple.
    I would not be against appending to args[0], the exception message,
    with applynode information, but this is easy enough to obtain at the
    pdb prompt with my modifications.
    cefc5553
名称
最后提交
最后更新
benchmark 正在载入提交数据...
bin 正在载入提交数据...
doc 正在载入提交数据...
theano 正在载入提交数据...
.gitignore 正在载入提交数据...
DESCRIPTION.txt 正在载入提交数据...
EMAIL.txt 正在载入提交数据...
HISTORY.txt 正在载入提交数据...
LICENSE.txt 正在载入提交数据...
MANIFEST.in 正在载入提交数据...
NEWS.txt 正在载入提交数据...
README.txt 正在载入提交数据...
distribute_setup.py 正在载入提交数据...
setup.cfg 正在载入提交数据...
setup.py 正在载入提交数据...