code: def _loglikelihood(self, y, mu, weights=None):
          
          return self.distribution.log_pdf(y=y, mu=mu, weights=weights).sum()
docs: compute the log-likelihood of the dataset using the current model
  
          Parameters
          ---------
          y : array-like of shape (n,)
              containing target values
          mu : array-like of shape (n_samples,)
              expected value of the targets given the model and inputs
          weights : array-like of shape (n,), optional
              containing sample weights
  
          Returns
          -------
          log-likelihood : np.array of shape (n,)
              containing log-likelihood scores