implements MOL-180: make run_test.py compatible with FUEL master
diff --git a/scripts/data.py b/scripts/data.py
index 0635789..b0c8f27 100644
--- a/scripts/data.py
+++ b/scripts/data.py
@@ -15,15 +15,15 @@
if not block.startswith("[{u'__meta__':"):
continue
- print
- print
- print block
- print
- print
-
for val in eval(block):
meta = val['__meta__']
- meta['sync'] = 's' if meta['sync'] else 'a'
+
+ if meta['sync']:
+ meta['sync'] = 's'
+ elif meta['direct_io']:
+ meta['sync'] = 'd'
+ else:
+ meta['sync'] = 'a'
key = "{action} {sync} {blocksize}k {concurence}".format(**meta)
results.setdefault(key, []).append(val['bw_mean'])
@@ -52,7 +52,7 @@
def show_data(*pathes):
- begin = "| {:>10} {:>5} {:>5} {:>3}"
+ begin = "| {:>10} {:>6} {:>5} {:>3}"
first_file_templ = " | {:>6} ~ {:>5} {:>2}% {:>5}"
other_file_templ = " | {:>6} ~ {:>5} {:>2}% {:>5} ---- {:>6}%"
@@ -82,9 +82,10 @@
common_keys &= set(result.keys())
for k in sorted(common_keys, key=ksort):
- tp = k.rsplit(" ", 1)[0]
+ tp = k.rsplit(" ", 2)[0]
op, s, sz, conc = k.split(" ")
- s = 'sync' if s == 's' else 'async'
+
+ s = {'a': 'async', "s": "sync", "d": "direct"}[s]
if tp != prev_tp and prev_tp is not None:
print sep
diff --git a/scripts/data_extractor.py b/scripts/data_extractor.py
index d3ba1ea..1f30b77 100644
--- a/scripts/data_extractor.py
+++ b/scripts/data_extractor.py
@@ -16,12 +16,17 @@
md5 text);
CREATE TABLE params_combination (id integer primary key, {params});
-CREATE TABLE param (id integer primary key, name text, type text);
+
+CREATE TABLE param (id integer primary key, name text, type text, descr text);
+
+CREATE TABLE lab (id integer primary key, name text, descr text);
CREATE TABLE result (build_id integer,
- params_combination integer,
+ time datetime,
+ lab_id integer,
+ params_combination_id integer,
bandwith float,
- deviation float);
+ meta text);
"""
diff --git a/scripts/run.sh b/scripts/run.sh
index 368410c..91fadc7 100644
--- a/scripts/run.sh
+++ b/scripts/run.sh
@@ -37,7 +37,7 @@
for SYNC_TYPE in $SYNC_TYPES ; do
# filter out too slow options
- if [ "$BLOCKSIZE" = "1k" -o "$BLOCK_SIZE" = "4k" ] ; then
+ if [ "$BSIZE" = "1k" -o "$BSIZE" = "4k" ] ; then
if [ "$SYNC_TYPE" = "a" ] ; then
continue
fi