def efficiency_score(y_true, y_pred, sample_weight=None):
    sample_weight = check_sample_weight(y_true, sample_weight=sample_weight)
    assert len(y_true) == len(y_pred), "Different size of arrays"
    isSignal = numpy.sum(y_true * sample_weight) - 1e-6
    isSignalAsSignal = numpy.sum(y_true * y_pred * sample_weight) + 1e-7
    return isSignalAsSignal / isSignal
    # the same, but with notifications
    # return recall_score(answer, prediction)
Returns True if categorical arrays are equal.
dataset/ETHPy150Open anaderi/lhcb_trigger_ml/hep_ml/metrics.py/efficiency_score--crossover with--dataset/ETHPy150Open pydata/pandas/pandas/core/categorical.py/Categorical.equals