我得到了以下代码的均方根误差L
from sklearn.metrics import make_scorer
def rmsele(actual, pred):
squared_errors = (np.log(pred + 1) - np.log(actual + 1)) ** 2
mean_squared = np.sum(squared_errors) / len(squared_errors)
return np.sqrt(mean_squared)
rmsele_scorer = make_scorer(rmsele, greater_is_better=False)
我希望有一个用于多级对数损失。有人可以帮忙吗?