FYI the latest documentation is inconsistent about how bicubic works with align_corners: Upsample — PyTorch master documentation 17
For the align_corners argument documentation bicubic is not included after “This only has effect when mode is”. However in the warning section below that bicubic is mentioned and align_corners does seem to affect it when used:
import torch
import torch.nn.functional as F
import numpy as np

z = torch.from_numpy(np.array([
    [1, 2],
    [3, 4]
], dtype=np.float32)[np.newaxis, np.newaxis, ...])

print(F.interpolate(z, scale_factor=2, mode='bicubic', align_corners=True)[0, 0])
print(F.interpolate(z, scale_factor=2, mode='bicubic', align_corners=False)[0, 0])

tensor([[1.0000, 1.3148, 1.6852, 2.0000],
        [1.6296, 1.9444, 2.3148, 2.6296],
        [2.3704, 2.6852, 3.0556, 3.3704],
        [3.0000, 3.3148, 3.6852, 4.0000]])
tensor([[0.6836, 1.0156, 1.5625, 1.8945],
        [1.3477, 1.6797, 2.2266, 2.5586],
        [2.4414, 2.7734, 3.3203, 3.6523],
        [3.1055, 3.4375, 3.9844, 4.3164]])