Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/VisionXLab/OF-Diff
/ default
Function
default
ldm/util.py:51–54 ·
view source on GitHub ↗
(val, d)
Source
from the content-addressed store, hash-verified
49
50
51
def
default(val, d):
52
if
exists(val):
53
return
val
54
return
d()
if
isfunction(d)
else
d
55
56
57
def
mean_flat(tensor):
Callers
6
q_sample
Method · 0.90
q_sample
Method · 0.90
p_losses
Method · 0.90
__init__
Method · 0.90
p_losses
Method · 0.90
p_losses
Method · 0.90
Calls
1
exists
Function · 0.70
Tested by
no test coverage detected