ARM-software / trappy

This repository has moved to https://gitlab.arm.com/tooling/trappy
Apache License 2.0
60 stars 39 forks source link

ILinePlot: Performance Improvements for ILinePLot #207

Closed sinkap closed 8 years ago

sinkap commented 8 years ago

Instead of converting the DataFrame to JSON and converting to the dyrgaph format in JS. Send the prepared data as expected by dygraphs to the JavaScript Library and get rid of convertToDataTable function.

With the current change the following plot works reasonably well on my laptop (Core i7 2.2GHz, 16GB RAM)

columns = ["tick", "tock", "toe"]
df = pd.DataFrame(numpy.random.randn(300000, 3),
columns=columns).cumsum()

trappy.ILinePlot(df, column=columns).view(max_datapoints=2000001)
sinkap commented 8 years ago

@derkling and @jlelli Can you try this out?

sinkap commented 8 years ago

An attempt to fix #103

JaviMerino commented 8 years ago

While I'm asking for things, can we also have a cute test for dict_to_dygraph() :blush:

JaviMerino commented 8 years ago

@mdigiorgio has fix ILinePlot::_fix_indexes() to always return an OrderedDict() with dicts as values. @sinkap , can you rebase this on top of master and change df_to_dygraph() into a dict_to_dygraph() please?

mdigiorgio commented 8 years ago

@sinkap the example you wrote works well also on my PC (Core i7@2.00 GHz, 8 GB RAM) :blush:

sinkap commented 8 years ago

Will finish this off soon, sorry for the delay :disappointed:

JaviMerino commented 8 years ago

Merged as fea80b8 .