def _check_likelihood(likelihood: str, available_likelihoods: list[str]):
    """Check whether the likelihood is supported.

    Parameters
    ----------
    likelihood
        The likelihood name. Must be one of ('gaussian', 'poisson', 'quantile').
    available_likelihoods
        A list of supported likelihood names.
    """
    if likelihood not in available_likelihoods:
        raise_log(
            ValueError(
                f"Invalid `likelihood='{likelihood}'`. Must be one of {available_likelihoods}"
            ),
            logger=logger,
        )
Check whether the likelihood is supported.

    Parameters
    ----------
    likelihood
        The likelihood name. Must be one of ('gaussian', 'poisson', 'quantile').
    available_likelihoods
        A list of supported likelihood names.
    
darts/utils/likelihood_models/sklearn.py