Commit 92b1c118 authored by Douglas's avatar Douglas

results_statistics is a pure text file now

parent 9991b5a6
from statistics import median, stdev
results = {}
# Data size is 250mb
# Read is how we call the process of reading all the data to calculate the
# sum of a column.
# --------- FORMAT 0 ---------
# --------- Pandas -----------
hot_cache_read_0_pandas = {'name': 'Format 0 - Pandas - Hot cache - read'}
hot_cache_read_0_pandas['data'] = [0.268836975098, 0.280472040176, 0.289081096649, 0.297116041183, 0.273966789246]
cold_cache_read_0_pandas = {'name': 'Format 0 - Cold cache - read'}
cold_cache_read_0_pandas['data'] = [63.5034000874, 66.1114599705, 64.4692680836, 62.5943498611, 57.514384985]
# --------- NumPy -----------
hot_cache_read_0_numpy = {'name': 'Format 0 - NumPy - Hot cache - read'}
hot_cache_read_0_numpy['data'] = [0.0165619850159, 0.0179328918457, 0.0160620212555, 0.0203459262848, 0.017126083374]
cold_cache_read_0_numpy = {'name': 'Format 0 - NumPy - Cold cache - read'}
cold_cache_read_0_numpy['data'] = [57.818944931, 66.3065798283, 67.2626810074, 68.1461188793, 64.0724961758]
# --------- FORMAT 1 ---------
# --------- Pandas -----------
hot_cache_read_1_pandas = {'name': 'Format 1 - Pandas - Hot cache - read'}
hot_cache_read_1_pandas['data'] = [0.196627855301, 0.205650091171, 0.209545850754, 0.288589000702, 0.215779066086]
cold_cache_read_1_pandas = {'name': 'Format 1 - Cold cache - read'}
cold_cache_read_1_pandas['data'] = [65.1305730343, 65.0622851849, 63.2642118931, 62.5943498611, 67.4575021267]
# --------- NumPy -----------
hot_cache_read_1_numpy = {'name': 'Format 1 - NumPy - Hot cache - read'}
hot_cache_read_1_numpy['data'] = [0.0176479816437, 0.016725063324, 0.0190989971161, 0.0153241157532, 0.0148088932037]
cold_cache_read_1_numpy = {'name': 'Format 1 - NumPy -Cold cache - read'}
cold_cache_read_1_numpy['data'] = [62.6579291821, 66.3065798283, 66.8456640244, 62.6478569508, 61.6572990417]
# -------- MariaDB ----------
mysql_hot_cache_read = {'name': 'MySQL hot cache - read'}
mysql_hot_cache_read['data'] = [0.42, 0.50, 0.44, 0.48, 0.47]
mysql_cold_cache_read = {'name': 'MySQL cold cache - read'}
mysql_cold_cache_read['data'] = [2.67, 2.47, 1.39, 3.04, 2.03]
# Write is how much time wendelin.core spend to write all data into the storage.
# It's not affected by cache.
# --------- FORMAT 0 ---------
write_0 = {'name': 'Format 0 - Write'}
write_0['data'] = [72.602396965, 65.1651449203, 70.1477439404, 64.4070370197, 65.0965659618]
# --------- FORMAT 1 ---------
write_1 = {'name': 'Format 1 - Write'}
write_1['data'] = [69.884073019, 64.7676539421, 66.6788258553, 65.2601249218, 63.1648089886]
samples = [hot_cache_read_0_numpy, hot_cache_read_0_pandas,
hot_cache_read_1_numpy, hot_cache_read_1_pandas,
cold_cache_read_0_numpy, cold_cache_read_0_pandas,
cold_cache_read_1_numpy, cold_cache_read_1_pandas,
mysql_hot_cache_read, mysql_cold_cache_read,
write_0, write_1]
for key, statistic_function in [['average', median], ['stdev', stdev], ['max', max], ['min', min]]:
for sample in samples:
sample[key] = statistic_function(sample['data'])
for sample in samples:
print sample
\ No newline at end of file
Write results:
------ ---------------
Format wendelin.core
------ ---------------
ZBlk0 10.279 ± 11.77%
ZBlk1 63.990 ± 7.88%
------ ---------------
Read results for ZBlk1:
Tool Hot Cache Cold Cache
--------------- -------------- ---------------
wendelin.numpy 0.022 ± 0.76% 58.047 ± 1.42%
numpy.memmap 0.046 ± 7.42% 0.047 ± 11.48%
numpy.memory 0.012 ± 3.63% 0.013 ± 2.38%
wendelin.pandas 0.226 ± 3.25% 58.492 ± 2.07%
--------------- -------------- ---------------
Read results for ZBlk0:
Tool Hot Cache Cold Cache
--------------- --------------- --------------
wendelin.numpy 0.034 ± 1.69% 3.525 ± 11.34%
wendelin.pandas 0.462 ± 1.68% 4.026 ± 6.64%
numpy.memmap 0.050 ± 7.20% 0.236 ± 10.21%
numpy.memory 0.014 ± 4.37% 0.013 ± 10.13%
--------------- -------------- ---------------
Read Results for MySQL:
Tool Hot Cache Cold Cache
------- ------------- --------------
MariaDB 0.470 ± 6.80% 2.470 ± 25.70%
------- ------------- --------------
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment