Remove permute bug: rely on F.conv3d spatial padding
This commit is contained in:
parent
6fc7cf0ad6
commit
f7c48b067a
1 changed files with 0 additions and 3 deletions
|
|
@ -55,9 +55,6 @@ def _causal_conv3d(x, weight, bias, *, kernel_size, stride, spatial_padding):
|
|||
# if x.shape[2] == 1: return super().forward(x, autopad="causal_zero")
|
||||
# x = F.pad(x, (0, 0, 0, 0, (k-1), 0), mode="constant") -- temporal
|
||||
# return super().forward(x)
|
||||
if spatial_padding > 0:
|
||||
x = F.pad(x, (spatial_padding, spatial_padding, spatial_padding, spatial_padding, 0, 0), mode="reflect")
|
||||
x = x.permute(0, 2, 1, 3, 4)
|
||||
if x.shape[2] == 1:
|
||||
# Keyframe path (matches reference's `autopad="causal_zero"`): truncate
|
||||
# the temporal taps to the center 1 and run as an effective 2D conv.
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue