MCPcopy Create free account
hub / github.com/Meshcapade/difflocks / shifted_unwindow

Function shifted_unwindow

k_diffusion/models/modules.py:293–296  ·  view source on GitHub ↗
(window_shift, x)

Source from the content-addressed store, hash-verified

291
292
293def shifted_unwindow(window_shift, x):
294 x = unwindow(x)
295 x = torch.roll(x, shifts=(-window_shift, -window_shift), dims=(-2, -3))
296 return x
297
298
299@lru_cache

Callers 1

apply_window_attentionFunction · 0.85

Calls 1

unwindowFunction · 0.85

Tested by

no test coverage detected