Reputation: 6538
I am trying to understand how Tensorflow debugger tfdbg works:
with sv.managed_session(config=config_proto) as session:
session = tf_debug.LocalCLIDebugWrapperSession(session)
for i in range(config.max_epoch):
session.run(model.lr)
When the debugger starts it presents us with the following window:
After reading the docs and watching one small tutorial on youtube I could not understand what does "run" and "step" commands actually stand for and what's more important how do they compare with neural network training time steps and epochs?
From the docs:
The run command causes tfdbg to execute until the end of the next Session.run() call, which calculates the model's accuracy using a test data set.
But the Session.run
it is just:
... one "step" of TensorFlow computation, by running the necessary graph fragment to execute every Operation and evaluate every Tensor in fetches, substituting the values in feed_dict for the corresponding input values.
I am new to TF and I still do not understand how to interpret "run" in terms of neural network steps and epochs. This of course makes difficult to use tfdbg because after couple of "run"s I get a list of ~5000 lines of misc tensor and ops which I need to search through and I don't understand what am I looking at, the results of one time step or epoch. We don't think in terms of session runs when we develop a neural network model, do we?
So, how many session "runs" is one epoch so I could at least find the tensors that go into the loss op?
Upvotes: 0
Views: 357
Reputation: 5206
In most tensorflow models a session.run
call processes a minibatch of training data. How many minibatches do you have per epoch depends on the particular model and dataset you're working with.
Upvotes: 1