You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
All values come out as 0 while converting int32 to float16 using tf.image.convert_image_dtype #35450
using scale as 1/image.dtype.max which is 1/(max Int32) and multiplying leads to very small values of order 1e-10, float16 cannot handle such large precisions, if you use dtype=float32 in convert_image_dtype the value is not 0 but the actual small value.
Hello, as your comment explains, I think that is some expected thing? But I'm not too sure about this so I'll leave decide to whether to close/not close this issue to @mihaimaruseac
Activity
msteknoadam commentedon Dec 27, 2019
@mihaimaruseac Hello, I created the issue but looks like I can't assign you so I'm just tagging you here.
Lasers67 commentedon Dec 28, 2019
In the code:
tensorflow/tensorflow/python/ops/image_ops_impl.py
Line 1809 in 1cf0898
using scale as 1/image.dtype.max which is 1/(max Int32) and multiplying leads to very small values of order 1e-10, float16 cannot handle such large precisions, if you use dtype=float32 in convert_image_dtype the value is not 0 but the actual small value.
msteknoadam commentedon Dec 28, 2019
Hello, as your comment explains, I think that is some expected thing? But I'm not too sure about this so I'll leave decide to whether to close/not close this issue to @mihaimaruseac
mihaimaruseac commentedon Dec 28, 2019
Closing then as it is working as intended.