"test/kaldi_compatibility_impl.py" did not exist on "3a4f356952e93a38b8f249e16b5bc97998f27462"
Commit 9e2050a6 authored by A. Unique TensorFlower's avatar A. Unique TensorFlower
Browse files

Merge pull request #8717 from freezestudio:patch-1

PiperOrigin-RevId: 318176474
parents 9d1a95c8 28a18f7f
......@@ -185,12 +185,12 @@ class Parser(object):
is_crowds = data['groundtruth_is_crowd']
# Skips annotations with `is_crowd` = True.
if self._skip_crowd_during_training and self._is_training:
num_groundtrtuhs = tf.shape(classes)[0]
with tf.control_dependencies([num_groundtrtuhs, is_crowds]):
num_groundtruths = tf.shape(classes)[0]
with tf.control_dependencies([num_groundtruths, is_crowds]):
indices = tf.cond(
tf.greater(tf.size(is_crowds), 0),
lambda: tf.where(tf.logical_not(is_crowds))[:, 0],
lambda: tf.cast(tf.range(num_groundtrtuhs), tf.int64))
lambda: tf.cast(tf.range(num_groundtruths), tf.int64))
classes = tf.gather(classes, indices)
boxes = tf.gather(boxes, indices)
if self._include_mask:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment