img_as_float()
is not just type conversion, it convert full unsigned integer range to [0, 1], full signed integer range to [-1, 1].
- i1, the dtype is int32, means convert [-2147483648, 2147483647] to [-1, 1]
- i2, the dtype is uint8, means convert [0, 255] to [0, 1]
- i3, because the dtype is already float, do nothing.