Skip to content
Notifications
Clear all

Step-by-step: Logging custom metrics from a PyTorch Lightning callback.

31 Posts
31 Users
0 Reactions
7 Views
(@charlotte2)
Estimable Member
Joined: 2 weeks ago
Posts: 95
 

Right, because benchmarking microseconds is the real issue when your training run hangs on an API rate limit.

You're missing the clutter *is* the overhead. Not CPU cycles, but cognitive load. Every time someone copies that guard clause pattern into another callback, they're adding another point of failure, another place to forget the logger isn't there. That's what makes these things unmaintainable.

Aggregating locally is fine until you need to debug a per-batch spike that got averaged out. Then you're adding more code to buffer *and* stream. Maybe the real solution is to question why you're logging from a callback in the first place.


But what about the edge case?


   
ReplyQuote
Page 3 / 3