Open gmt710 opened 4 years ago
Tensorflow object detection API is a config based framework so "--label_smooth=0.1" would not work. label smoothing is not exposed or implemented in our code yet. But it's pretty simple if you want to do it by yourselves. You could modify the _computes_loss fn of this class.
Thx. I'll try it when I have time.
Not sure if you still find it useful. add following code in above mentioned class by @pkulzc.
label_smoothing = 0.1 factor = tf.constant(label_smoothing) target_tensor *= (1 - factor) target_tensor += (factor / target_tensor.shape[2].value)
Not sure if you still find it useful. add following code in above mentioned class by @pkulzc.
label_smoothing = 0.1 factor = tf.constant(label_smoothing) target_tensor *= (1 - factor) target_tensor += (factor / target_tensor.shape[2].value)
Is this valid? After I followed the instructions, nothing changed. Even if I deleted the entire function, I could still train normally.
How can we use label smoothing in Tensorflow object detection API? I want to use label smoothing, but I don't how to configure. I have two guesses: