Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/VisionXLab/OF-Diff
/ isimage
Function
isimage
ldm/util.py:41–44 ·
view source on GitHub ↗
(x)
Source
from the content-addressed store, hash-verified
39
40
41
def
isimage(x):
42
if
not isinstance(x,torch.Tensor):
43
return
False
44
return
(len(x.shape) == 4) and (x.shape[1] == 3 or x.shape[1] == 1)
45
46
47
def
exists(x):
Callers
3
log_images
Method · 0.90
log_images
Method · 0.90
log_images
Method · 0.90
Calls
no outgoing calls
Tested by
no test coverage detected