Comments (3)
버그 고친 버전 v2.6.1 배포했습니다! 요 이슈는 닫아볼게요!
감사합니다!
from pytorch_optimizer.
제보 감사합니다! 아마 exp_avg_sq_row
, exp_avg_sq_col
를 torch.zeros로 만들때 device를 지정하지 않아서 말씀하신 문제가 발생한 거 같네요. 바로 고쳐보겠슴다
from pytorch_optimizer.
덕분에 Adafactor optimizer 구현 문제를 하나 더 발견해서 같이 고쳐봤습니다. + GPU 에서 테스트 완료 했습니다!
example code
from timm import create_model
from tqdm import tqdm
import torch
from torch.nn import functional as F
from pytorch_optimizer import load_optimizer
bs = 16
backbone = 'resmlp_12_distilled_224'
model = create_model(backbone, pretrained=False, num_classes=1)
model.train()
model.cuda()
optimizer = load_optimizer('adafactor')(model.parameters(), warmup_init=True, weight_decay=1e-3)
inp = torch.randn((bs, 3, 224, 224), dtype=torch.float32)
y = torch.randn((bs, 1), dtype=torch.float32)
inp = inp.cuda()
y = y.cuda()
for _ in tqdm(range(50)):
optimizer.zero_grad()
F.binary_cross_entropy_with_logits(model(inp), y).backward()
optimizer.step()
from pytorch_optimizer.
Related Issues (20)
- Prodigy: An Expeditiously Adaptive Parameter-Free Learner HOT 2
- LOMO: LOw-Memory Optimization HOT 1
- Can a variant of Lion named Tiger be added to your package? HOT 2
- sophiah bug HOT 5
- sophiah in https://github.com/booydar/LM-RMT HOT 8
- Adding the CAME optimizer HOT 2
- Lookahead is not a subclass of torch.optim.Optimizer HOT 4
- Empty Docs Sections HOT 6
- Request to add 4-bit AdamW HOT 3
- ipex failed for Adan from pytorch_optimizer HOT 1
- Improvement to SAM: SAM as an Optimal Relaxation of Bayes HOT 1
- FR: Sharpness-Aware Minimization Revisited: Weighted Sharpness as a Regularization Term (WSAM) HOT 2
- Ranger21 has undocumented required arguments HOT 3
- [Feature request]REX LR scheduler HOT 2
- Aida optimizer HOT 3
- GaLore: Memory-Efficient LLM Training by Gradient Low-Rank Projection HOT 1
- Adalite HOT 1
- ScheduleFree
- Entropy-MCMC: Sampling from flat basins with ease
- Ranger sign inversion HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pytorch_optimizer.