Last active
March 19, 2019 18:04
-
-
Save VXU1230/77182cc7dfab78ac5456e3825b39e13b to your computer and use it in GitHub Desktop.
Evaluate Model
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def evaluate(model, loss_fn, target_data, context_data, label_data): | |
predictions = model(target_data, context_data) | |
batch_loss = loss_fn(label_data, predictions) | |
return batch_loss |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment