There were a couple of issues when trying to use fp16 training. For one was that it was not exposed through the configuration system. The other was that the DynamicSoftLabelAssigner used binary_cross_entropy instead of binary_cross_entropy_with_logits. This changes where sigmoid is called on the predictions so that the more stable binary_cross_entropy_with_logits can be used and the Trainer can be configured to use fp16 precision.
There were a couple of issues when trying to use
fp16
training. For one was that it was not exposed through the configuration system. The other was that theDynamicSoftLabelAssigner
usedbinary_cross_entropy
instead ofbinary_cross_entropy_with_logits
. This changes wheresigmoid
is called on the predictions so that the more stablebinary_cross_entropy_with_logits
can be used and theTrainer
can be configured to usefp16
precision.