def test_misclassification(backend_default):
    NervanaObject.be.bsz = 3
    outputs = np.array(
        [[0.25, 0.99, 0.33], [0.5, 0.005, 0.32], [0.25, 0.005, 0.34]])
    targets = np.array([[0, 1, 0], [1, 0, 1], [0, 0, 0]])
    expected_result = np.ones((1, 1)) / 3.
    compare_metric(Misclassification(),
                   outputs, targets, expected_result, tol=1e-7)
dataset/ETHPy150Open NervanaSystems/neon/tests/test_costs.py/test_misclassification/original