diff --git a/python/paddle/fluid/dygraph/amp/auto_cast.py b/python/paddle/fluid/dygraph/amp/auto_cast.py index bd97a61249f24cee0392a58e2f264e05cc3d9062..f7d4be7ee6e3c7cab973a1db97fbd00126034d9b 100644 --- a/python/paddle/fluid/dygraph/amp/auto_cast.py +++ b/python/paddle/fluid/dygraph/amp/auto_cast.py @@ -171,7 +171,7 @@ def pure_fp16_initialize(models): if (layer._dtype == 'float16') or isinstance( layer, (paddle.nn.BatchNorm, paddle.nn.BatchNorm1D, paddle.nn.BatchNorm2D, paddle.nn.BatchNorm3D, - paddle.nn.LayerNorm)): + paddle.nn.LayerNorm, paddle.nn.SyncBatchNorm)): continue layer._to_impl(dtype='float16', include_sublayers=False) return models