def METHOD_NAME(a: torch.Tensor, dim: int, repeats: int) -> torch.Tensor:
    """
    Repeat a tensor along a given dimension, using ``torch.repeat`` internally.
    Parameters
    ----------
    a
        Original tensor to repeat.
    dim
        Dimension to repeat data over.
    repeats
        How many time to repeat the input tensor.
    Returns
    -------
    torch.Tensor
        A tensor with the same size as the input one, except dimension
        ``dim`` which is multiplied by ``repeats``.
    """
    if repeats == 1:
        return a
    r = [1] * len(a.shape)
    r[dim] = repeats
    return a.repeat(*r)