示例#1
0
def test_relu_derivative():
    data = saved_data[8]
    t0 = data[0]
    gt = data[1]
    student = hw1.ReLU()
    student(t0)
    closeness_test(student.derivative(), gt, "relu.derivative()")
示例#2
0
def test_relu_forward():
    data = saved_data[7]
    t0 = data[0]
    gt = data[1]
    student = hw1.ReLU()
    student(t0)
    closeness_test(student.state, gt, "relu.state")