Update classifier.py
Browse files- classifier.py +1 -1
classifier.py
CHANGED
@@ -118,7 +118,7 @@ class Classifier:
|
|
118 |
grad.append(torch.as_tensor(grad_))
|
119 |
# update weights
|
120 |
grad = torch.stack(grad, dim=0)
|
121 |
-
self.weight -= 0.
|
122 |
self.weight /= torch.norm(
|
123 |
self.weight, p=2, dim=-1, keepdim=True
|
124 |
)
|
|
|
118 |
grad.append(torch.as_tensor(grad_))
|
119 |
# update weights
|
120 |
grad = torch.stack(grad, dim=0)
|
121 |
+
self.weight -= 0.01 * grad
|
122 |
self.weight /= torch.norm(
|
123 |
self.weight, p=2, dim=-1, keepdim=True
|
124 |
)
|