We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ace33d7 commit 81fdc28Copy full SHA for 81fdc28
python/paddle/fluid/layer_helper.py
@@ -302,7 +302,8 @@ def create_parameter(self,
302
if default_initializer is None and attr.initializer is None:
303
if isinstance(dtype, core.VarDesc.VarType):
304
if dtype != core.VarDesc.VarType.FP32 and \
305
- dtype != core.VarDesc.VarType.FP64:
+ dtype != core.VarDesc.VarType.FP64 and \
306
+ dtype != core.VarDesc.VarType.FP16:
307
raise TypeError(
308
"Can not create parameter with default initializer when dtype is not float type. Set default_initializer to fit the parameter dtype!"
309
)
0 commit comments