MCPcopy Create free account
hub / github.com/Tiiny-AI/PowerInfer / cosine_decay_restart

Function cosine_decay_restart

common/train.cpp:417–423  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

415}
416
417float cosine_decay_restart(int64_t step, int64_t decay_steps, float minimum, float restart_step_mult) {
418 while (step > decay_steps) {
419 step -= decay_steps;
420 decay_steps = (int64_t) (restart_step_mult * decay_steps);
421 }
422 return cosine_decay(step, decay_steps, minimum);
423}
424
425float learning_schedule(
426 int64_t step,

Callers 1

learning_scheduleFunction · 0.85

Calls 1

cosine_decayFunction · 0.85

Tested by

no test coverage detected