You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 17, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Nov 17, 2023. It is now read-only.
DyNet's autobatching approach is predicated on their lazy execution semantics (build a graph imperatively but don't execute it until later -- the autobatching can happen in between) and this limits the applicability of autobatching to truly dynamic situations (where the graph structure depends on runtime values of tensors e.g. because of discrete samples from a stochastic policy network).
PyTorch and Chainer are currently using eager execution semantics (other than the minimal laziness that comes from CUDA async execution), which means they'd either need to implement lazy eval or apply a very different autobatching approach. The problems with choosing lazy eval are a) the runtime conditionals mentioned above and b) the fact that as GPUs get faster and faster graph-building starts to be more costly than execution.
Ultimately what we need is either a magical static analyzer that can convert imperative-looking Python into an MXNet-like symbolic graph or a combination of autobatching with lazy eval together with annotations that say "this function can be statically compiled." MXNet is pretty well-positioned to do that since it's always had a mixed imperative-symbolic approach.
Reacted by Tianqi Chen, Sebastian Bodenstein, Thuyen Ngo, serhii-havrylov, Ravil Bayramgalin, pklfz, Yingfeng, Branden Carrier, WEI HAORAN, Xan (Alex) Merritt and 2 more
Activity
piiswrong commentedon May 23, 2017
Yeah we have been thinking about doing the same thing. Haven't got to it yet. Never thought you can write a paper about it...
jekbradbury commentedon May 23, 2017
DyNet's autobatching approach is predicated on their lazy execution semantics (build a graph imperatively but don't execute it until later -- the autobatching can happen in between) and this limits the applicability of autobatching to truly dynamic situations (where the graph structure depends on runtime values of tensors e.g. because of discrete samples from a stochastic policy network).
PyTorch and Chainer are currently using eager execution semantics (other than the minimal laziness that comes from CUDA async execution), which means they'd either need to implement lazy eval or apply a very different autobatching approach. The problems with choosing lazy eval are a) the runtime conditionals mentioned above and b) the fact that as GPUs get faster and faster graph-building starts to be more costly than execution.
Ultimately what we need is either a magical static analyzer that can convert imperative-looking Python into an MXNet-like symbolic graph or a combination of autobatching with lazy eval together with annotations that say "this function can be statically compiled." MXNet is pretty well-positioned to do that since it's always had a mixed imperative-symbolic approach.
yajiedesign commentedon Sep 30, 2017
This issue is closed due to lack of activity in the last 90 days. Feel free to reopen if this is still an active issue. Thanks!