Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
Signed-off-by: João Lucas de Sousa Almeida <[email protected]>
  • Loading branch information
Joao-L-S-Almeida committed Feb 3, 2025
1 parent 25fa6fe commit 450c0b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion terratorch/models/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def pad_images(imgs: Tensor, patch_size: int | list, padding: str) -> Tensor:
f"but no multi-temporal data provided (data shape = {imgs.shape}).")

h, w = imgs.shape[-2:]
t = imgs.shape[-3:] if len(imgs.shape) > 4 else 1
t = imgs.shape[-3] if len(imgs.shape) > 4 else 1
t_pad, h_pad, w_pad = (p_t - t % p_t) % p_t, (p_h - h % p_h) % p_h, (p_w - w % p_w) % p_w
if t_pad > 0:
# Multi-temporal padding
Expand Down

0 comments on commit 450c0b8

Please sign in to comment.