[Solved] Training a simple RNN

You are right in that they go out of scope. However, there are still references to them from the computation graph, which is not explicitly shown. So they are not deallocated/gc’ed.

By the way, how did you init char_input?