Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimized dynamic bokeh plots #968

merged 1 commit into from Nov 4, 2016


None yet
2 participants
Copy link

philippjfr commented Nov 2, 2016

Previously we added some optimization that avoids sending updated plot data if the data source is unchanged between frames. However the plotting class still went through the effort of updating the datasource even though it is unchanged, which can in some cases be fairly expensive in itself. This generalizes the previous optimization such that the data is only updated in dynamic mode if it has changed.

Philipp Rudiger Philipp Rudiger
Optimized dynamic bokeh plots
Avoid updating unchanged data sources

This comment has been minimized.

Copy link

jlstevens commented Nov 4, 2016

As a generalization of a previous optimization, this seems ok. The core condition seems to be:

self.static_source = self.dynamic and (current_id == previous_id)

Looking at the code, it seems that this self.static_source attribute now controls whether the datasource is updated and whether the (un)changed plot data is sent (or not). Overall this seems clearer than before (and more efficient) so I will now merge.

@jlstevens jlstevens merged commit 0ff7d8e into master Nov 4, 2016

4 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
continuous-integration/travis-ci/push The Travis CI build passed
coverage/coveralls Coverage decreased (-0.003%) to 75.712%
s3-reference-data-cache Test data is cached.

@philippjfr philippjfr deleted the static_source_opt branch Dec 10, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.