MCPcopy Create free account
hub / github.com/VisionXLab/OF-Diff / uniform_on_device

Function uniform_on_device

ldm/models/diffusion/ddpm.py:49–50  ·  view source on GitHub ↗
(r1, r2, shape, device)

Source from the content-addressed store, hash-verified

47
48
49def uniform_on_device(r1, r2, shape, device):
50 return (r1 - r2) * torch.rand(*shape, device=device) + r2
51
52
53class DDPM(pl.LightningModule):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected