formatting on Float16 function
This commit is contained in:
@@ -18,9 +18,6 @@ def int_to_float16(int_to_convert):
|
||||
if int(bin_rep[0]) == 1:
|
||||
sign = -1.0
|
||||
exponent = float(int(bin_rep[1:6], 2))
|
||||
# if exponent == 30:
|
||||
# fraction = float(int("1" + bin_rep[:17], 2))
|
||||
# else:
|
||||
fraction = float(int(bin_rep[6:17], 2))
|
||||
|
||||
if exponent == float(0b00000):
|
||||
|
||||
Reference in New Issue
Block a user