'Tests box scaling, checking scaled values.'

def testScaleBoxesToPixelCoordinates(self):

    in_shape = [60, 40, 3]
    in_boxes = [[0.1, 0.2, 0.4, 0.6], [0.5, 0.3, 0.9, 0.7]]
    expected_boxes = [[6.0, 8.0, 24.0, 24.0], [30.0, 12.0, 54.0, 28.0]]
    in_image = tf.random_uniform(in_shape)
    in_boxes = tf.constant(in_boxes)
    (_, out_boxes) = preprocessor.scale_boxes_to_pixel_coordinates(in_image, boxes=in_boxes)
    with self.test_session() as sess:
        out_boxes = sess.run(out_boxes)
        self.assertAllClose(out_boxes, expected_boxes)
