set_default_float_dtype#

ivy.set_default_float_dtype(float_dtype, /)[source]#

Set the ‘float_dtype’ as the default data type.

Parameters:

float_dtype (Union[Dtype, str]) – The float data type to be set as the default.

Examples

With :class: ivy.Dtype input:

>>> ivy.set_default_float_dtype(ivy.floatDtype("float64"))
>>> ivy.default_float_dtype()
'float64'
>>> ivy.set_default_float_dtype(ivy.floatDtype("float32"))
>>> ivy.default_float_dtype()
'float32'