def METHOD_NAME(self, sample_shape=torch.Size()):
    mask = self.mask.reshape(self.mask.shape + (1,) * self.event_dim)
    mask = mask.expand(sample_shape + self.shape())
    result = torch.where(
        mask,
        self.component1.METHOD_NAME(sample_shape),
        self.component0.METHOD_NAME(sample_shape),
    )
    return result