3D-ResNets-PyTorch
3D-ResNets-PyTorch copied to clipboard
Will using nn.AdaptiveAvgPool3d more convenient?
https://github.com/kenshohara/3D-ResNets-PyTorch/blob/d9847ea56b0d4bc7601a229099deb2b483539514/models/resnet.py#L139
As the title stated, is there a reason to use nn.AvgPool3d
instead of nn.AdaptiveAvgPool3d
?
Using nn.AdaptiveAvgPool3d
can help us get rid of calculating last_size
and last_duration
explicitly and passing sample_duration
and sample_size
as well. Furthermore, it will create a size/length agnostic model which seems to be more convenient.
I think it is. But it is equal to the current code because sizes are calculated carefully.