MCPcopy Create free account
hub / github.com/huggingface/diffusers / pad

Method pad

examples/community/rerender_a_video.py:1201–1202  ·  view source on GitHub ↗
(self, *inputs)

Source from the content-addressed store, hash-verified

1199 self._pad = [pad_wd // 2, pad_wd - pad_wd // 2, 0, pad_ht]
1200
1201 def pad(self, *inputs):
1202 return [F.pad(x, self._pad, mode="replicate") for x in inputs]
1203
1204 def unpad(self, x):
1205 ht, wd = x.shape[-2:]

Callers 15

get_warped_and_maskFunction · 0.95
downsampleMethod · 0.80
encode_promptMethod · 0.80
encode_promptMethod · 0.80
encode_promptMethod · 0.80
pad_imageMethod · 0.80
_filter2dFunction · 0.80
_encode_prompt_qwenMethod · 0.80
_encode_prompt_qwenMethod · 0.80

Calls

no outgoing calls

Tested by 1

get_audioMethod · 0.64