Cleaned up the conversion from str to f64