MCPcopy Create free account
hub / github.com/YesianRohn/TextSSR / unpad

Method unpad

diffusers/examples/community/rerender_a_video.py:1191–1194  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

1189 return [F.pad(x, self._pad, mode="replicate") for x in inputs]
1190
1191 def unpad(self, x):
1192 ht, wd = x.shape[-2:]
1193 c = [self._pad[2], ht - self._pad[3], self._pad[0], wd - self._pad[1]]
1194 return x[..., c[0] : c[1], c[2] : c[3]]

Callers 1

get_warped_and_maskFunction · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected