docstr: Tests we're not patching if we would lose all gt_boxes.
          
docstr_tok: ["Tests","we","'re","not","patching","if","we","would","lose","all","gt_boxes","."]
code: def testPatchImageUpdateCondition(self):
      """Tests we're not patching if we would lose all gt_boxes."""
      im_shape = (600, 800, 3)
      label = 3
      image_ph = tf.placeholder(shape=(None, None, 3), dtype=tf.float32)
      bboxes_ph = tf.placeholder(shape=(None, 5), dtype=tf.int32)
  
      with self.test_session() as sess:
          # Generate image and bboxes.
          image = self._gen_image(*im_shape)
          bboxes = [(0, 0, 40, 40, label), (430, 200, 480, 250, label)]
          # Get patch_image so that the proposed patch has no gt_box center
          # in it.
          patch = patch_image(
              image_ph,
              bboxes_ph,
              offset_height=45,
              offset_width=45,
              target_height=100,
              target_width=200,
          )
          feed_dict = {image_ph: image, bboxes_ph: bboxes}
          # Run patch in a test session.
          ret_dict = sess.run(patch, feed_dict)
  
          ret_image = ret_dict["image"]
          ret_bboxes = ret_dict.get("bboxes")
      # Assertions
      self.assertAllClose(ret_image, image)
      self.assertAllClose(ret_bboxes, bboxes)
  
imports: import numpy
  import tensorflow
  from easydict import EasyDict
  from luminoth.utils.image import resize_image, flip_image, random_patch, random_resize, random_distortion, patch_image
  from luminoth.utils.test.gt_boxes import generate_gt_boxes
label_desc: Use image node_id 11 for calling the ImageTest obj's underlying member method code with example usage: obj.testPatchImageUpdateCondition() without return types