check if value is None before trying to cast float

the tool used to fail when there were NULL values in the fields