torch / nngraph

Graph Computation for nn

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

how to skip some nodes ?

shuzi opened this issue · comments

Hey guys,

suppose I create a gmodule with two input A and B.
Now A will be the training example, and B will be some random sampled negative example
Now during forward path I want the full calculation only be done once, and from the second time only B will be changing and A will be fixed, so the calculation related with A is not necessary to be conducted again.

So is there some example show that how to skip some nodes in the nngraph during forward pass?

Currently, the way to do is would be to have different graphs that share those modules and use them in different parts of your training.