Skip to content

Commit

Permalink
Update PythonApplication2.py indentation
Browse files Browse the repository at this point in the history
  • Loading branch information
anamitraupadhyay authored Nov 2, 2024
1 parent 1bc5361 commit ead7c99
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions PythonApplication2.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ def validation_epoch_end(self, outputs):
epoch_acc = torch.stack(batch_accs).mean()
return {'val_loss': epoch_loss.item(), 'val_acc': epoch_acc.item()}

def epoch_end(self, epoch, result):
print("Epoch [{}], val_loss: {:.4f}, val_acc: {:.4f}".format(epoch, result['val_loss'], result['val_acc']))
def epoch_end(self, epoch, result):
print("Epoch [{}], val_loss: {:.4f}, val_acc: {:.4f}".format(epoch, result['val_loss'], result['val_acc']))

def accuracy(outputs, labels):
_, preds = torch.max(outputs, dim=1)
Expand Down

0 comments on commit ead7c99

Please sign in to comment.