def METHOD_NAME(cfg, activations: List[torch.Tensor], sample_idx=0):
    """ Upsample activations and concatenate them to form a feature tensor """
    assert all([isinstance(acts, torch.Tensor) for acts in activations])
    size = tuple(cfg.mlp.dim[:-1])
    resized_activations = []
    for feats in activations:
        feats = feats[sample_idx][None]
        feats = nn.functional.interpolate(
            feats, size=size, mode=cfg.ddpm.upsample_mode)
        resized_activations.append(feats[0])
    return torch.cat(resized_activations, dim=0)