MCPcopy Create free account
hub / github.com/CompVis/diff2flow / get_batch_stats

Function get_batch_stats

diff2flow/helpers.py:163–170  ·  view source on GitHub ↗
(x: Tensor, stats=None)

Source from the content-addressed store, hash-verified

161
162
163def get_batch_stats(x: Tensor, stats=None):
164 out = {
165 "min": torch.min(x).item(),
166 "max": torch.max(x).item(),
167 "mean": torch.mean(x).item(),
168 "std": torch.std(x).item(),
169 }
170 return out
171
172
173def un_normalize_ims(ims):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected