提交 c4d2776e authored 作者: Ilya Dyachenko's avatar Ilya Dyachenko

Fixed bug in tutorial -> Derivatives in Theano -> Jacobian times a Vector -> L-operator.

上级 56599206
...@@ -221,8 +221,8 @@ f(x)}{\partial x}`. The *L-operator* is also supported for generic tensors ...@@ -221,8 +221,8 @@ f(x)}{\partial x}`. The *L-operator* is also supported for generic tensors
>>> x = T.dvector('x') >>> x = T.dvector('x')
>>> y = T.dot(x, W) >>> y = T.dot(x, W)
>>> VJ = T.Lop(y, W, v) >>> VJ = T.Lop(y, W, v)
>>> f = theano.function([W,v,x], JV) >>> f = theano.function([v,x], VJ)
>>> f([[1, 1], [1, 1]], [2, 2], [0, 1]) >>> f([2, 2], [0, 1])
array([[ 0., 0.], array([[ 0., 0.],
[ 2., 2.]]) [ 2., 2.]])
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论