def _testBrightness(self, x_np, y_np, delta, min_value, max_value): with self.test_session(): x = constant_op.constant(x_np, shape=x_np.shape) y = image_ops.adjust_brightness(x, delta, min_value=min_value, max_value=max_value) y_tf = y.eval() self.assertAllEqual(y_tf, y_np)
def _testBrightness(self, x_np, y_np, delta): with self.test_session(): x = constant_op.constant(x_np, shape=x_np.shape) y = image_ops.adjust_brightness(x, delta) y_tf = y.eval() self.assertAllClose(y_tf, y_np, 1e-6)