Skip to content

Commit

Permalink
Refine LSTMBlockCell to support dynamic rnn (apache#5963)
Browse files Browse the repository at this point in the history
1. Refine conversion of `LSTMBlockCell`
       1) Make its output follows definition in TensorFlow
       2) Avoid introducing variables which doesn't match any placeholder nodes in TensorFlow graph

    2. About change in test_forward_ptb
       States nodes of LSTMBlockCell in this PB file  are actually Constant node.
       TF can feed data to those Constant nodes but relay can't do that, so current conversion of LSTMBockCell introduces extra variables to solve this issue.
       But this causes that relay IR doesn't match original TF graph. This PR solves this issue by convert those states node into placeholders.
  • Loading branch information
lixiaoquan authored and trevor-m committed Sep 3, 2020
1 parent 857c0a0 commit 50756d5
Show file tree
Hide file tree
Showing 3 changed files with 231 additions and 345 deletions.
Loading

0 comments on commit 50756d5

Please sign in to comment.