Skip to content
Snippets Groups Projects
Commit 34887809 authored by Craig Tiller's avatar Craig Tiller
Browse files

Handle floats in bm_json

parent 9a514b58
Branches
Tags
No related merge requests found
......@@ -103,11 +103,11 @@ _BM_SPECS = {
def numericalize(s):
if not s: return ''
if s[-1] == 'k':
return int(s[:-1]) * 1024
return float(s[:-1]) * 1024
if s[-1] == 'M':
return int(s[:-1]) * 1024 * 1024
return float(s[:-1]) * 1024 * 1024
if 0 <= (ord(s[-1]) - ord('0')) <= 9:
return int(s)
return float(s)
assert 'not a number: %s' % s
def parse_name(name):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment