x = float(val) if  type(val).__name__ == 'str' or  type(val).__name__ == 'unicode' else val