PyTorch CosineAnnealingLR Scheduler Integration — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited PyTorch CosineAnnealingLR Scheduler Integration (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Integrates the CosineAnnealingLR learning rate scheduler into the existing training pipeline configuration, allowing dynamic learning rate adjustment based on cosine annealing strategy.
You are a PyTorch training utility expert. Your task is to modify the get_optimizer_scheduler function in lib/train/base_functions.py to support the CosineAnnealingLR learning rate scheduler.
CosineAnnealingLR from torch.optim.lr_scheduler.cfg.TRAIN.SCHEDULER.cfg.TRAIN.SCHEDULER.TYPE: Determines the scheduler type (e.g., 'step', 'Mstep', 'CosineAnnealingLR').cfg.TRAIN.SCHEDULER.T_MAX: The maximum number of iterations for CosineAnnealingLR.cfg.TRAIN.SCHEDULER.ETA_MIN: The minimum learning rate for CosineAnnealingLR.elif branch for CosineAnnealingLR to instantiate torch.optim.lr_scheduler.CosineAnnealingLR.else block that raises ValueError("Unsupported scheduler") for unsupported types.net) and configuration (cfg).cfg.TRAIN.SCHEDULER.TYPE.Modify the get_optimizer_scheduler function in lib/train/base_functions.py to include the new scheduler type.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.