Commit c1348ba0 authored by Anthony Larcher's avatar Anthony Larcher
Browse files

monitor display

parent 31be2e01
...@@ -600,7 +600,6 @@ class Xtractor(torch.nn.Module): ...@@ -600,7 +600,6 @@ class Xtractor(torch.nn.Module):
self.loss = loss self.loss = loss
if self.loss == "aam": if self.loss == "aam":
print("\n\n\nAAM\n\n\n")
self.after_speaker_embedding = ArcMarginProduct(self.embedding_size, self.after_speaker_embedding = ArcMarginProduct(self.embedding_size,
int(self.speaker_number), int(self.speaker_number),
s = 30, s = 30,
...@@ -1933,9 +1932,9 @@ def new_train_epoch(model, ...@@ -1933,9 +1932,9 @@ def new_train_epoch(model,
torch.nn.utils.clip_grad_norm_(model.parameters(), 1.) torch.nn.utils.clip_grad_norm_(model.parameters(), 1.)
scaler.step(optimizer) scaler.step(optimizer)
scaler.update() scaler.update()
optimizer.step()
else: else:
loss.backward() loss.backward()
print("optimizer.step")
optimizer.step() optimizer.step()
running_loss += loss.item() running_loss += loss.item()
accuracy += (torch.argmax(output.data, 1) == target).sum() accuracy += (torch.argmax(output.data, 1) == target).sum()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment