mirror of
https://github.com/hpcaitech/ColossalAI.git
synced 2025-09-09 04:50:17 +00:00
add an example of ViT-B/16 and remove w_norm clipping in LAMB (#29)
This commit is contained in:
@@ -94,7 +94,7 @@ class Lamb(Optimizer):
|
||||
# * math.sqrt(bias_correction2) / bias_correction1
|
||||
step_size = group['lr']
|
||||
|
||||
weight_norm = p.data.pow(2).sum().sqrt().clamp(0, 10)
|
||||
weight_norm = p.data.pow(2).sum().sqrt()
|
||||
|
||||
adam_step = exp_avg / exp_avg_sq.sqrt().add(group['eps'])
|
||||
if group['weight_decay'] != 0:
|
||||
|
Reference in New Issue
Block a user