human
I wrote the below code

    def masked(y_true, y_pred, mask=None):
        'Wrapper    function.\n\n                                #    Arguments\n                                                y_true:    `y_true`    argument    of    `fn`.\n                                                y_pred:    `y_pred`    argument    of    `fn`.\n                                                mask:    Mask    tensor.\n\n                                #    Returns\n                                                Scalar    tensor.\n                                '
        score_array = fn(y_true, y_pred)
        if (mask is not None):
            mask = K.cast(mask, K.floatx())
            score_array *= mask
            score_array /= K.mean(mask)
        return K.mean(score_array)
    return masked

What's a good function header?

Here's a good function header?
assistant
#Here's a good function header.

def _masked_objective(fn):