Skip to content

Instantly share code, notes, and snippets.

@random-forests random-forests/snippet2.py Secret
Created Mar 5, 2019

Embed
What would you like to do?
# See https://github.com/tensorflow/docs/blob/master/site/en/r2/guide/autograph.ipynb
@tf.function
def train(model, optimizer):
train_ds = mnist_dataset()
step = 0
loss = 0
accuracy = 0
for x, y in train_ds:
# as above, including the "if" and "print()"
return step
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.