Need example to downsample plots with Bokeh

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

Hi,

The stocks downsample dashboard demo should be what you are looking for (or at least give you useful examples).

https://github.com/bokeh/bokeh-demos/tree/master/stocks

Best

Fabio

···

On Tue, Nov 10, 2015 at 8:55 AM, [email protected] wrote:

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

You received this message because you are subscribed to the Google Groups “Bokeh Discussion - Public” group.

To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].

To post to this group, send email to [email protected].

To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/2d045cb7-4319-43e5-a5bb-07f00a03c637%40continuum.io.

For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Fabio Pliger

Senior Software Engineer, Bokeh

Hi Alec,

Thanks for your questions. The first thing to mention is that it is possible to do this in bokeh in a variety of ways, both with and without the server. If your data is already behind some REST interface, then the simplest route is probably to use the AjaxDataSource, which does not require the server. A simple example of its use is here:\

  https://github.com/bokeh/bokeh/blob/master/examples/plotting/file/ajax_source.py

The "Ocean Surface Temperature" demo that is also around on YouTube also uses the AjaxDataSource. It is here:

  https://gist.github.com/bryevdv/7a9564266b663a1cf06e

The server is also an option, but I should warn you to wait. The server has recently been completely re-written from the ground up and is faster, smaller/simpler, and much easier to use and deploy and explain. The major PR was just merged into master, and will show up in the upcoming 0.11 release in December. It will come with much expanded docs as well as many new examples so of how to use it. I would not advise anyone to start a project with the old server at this point in time.

Bryan

···

On Nov 10, 2015, at 12:55 PM, [email protected] wrote:

I'm relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I'm conscient that actual browsers can't handle such an amount of data. This is why I'm trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That's what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn't seem complete to help me :Deploying the Bokeh Server — Bokeh 0.10.0 documentation

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I'm not able to recover any of this examples on Internet. All links I found were invalid. This is why I'm posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/2d045cb7-4319-43e5-a5bb-07f00a03c637%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

First of all, thanks for your interest and your answers.

So Fabio, I already found the stocks downsample dashboard demo but I wasn’t able to run it. Indeed I think it is based on an old version of Bokeh because it calls bokeh.models.actions.Callback and there isn’t any bokeh.models.actions anymore according to the documentation. I tried to replace this import by bokeh.models.callbacks.Callback but it didn’t work. I think it’s two different classes. But thanks for the link anyway !

And Bryan thanks for your answer very helpful. Forward I think I will use the bokeh-server but for now I’m going to give a try to the solution without server waiting for the 0.11 release. So I’m going to follow your advice and not implement any solution based on the 0.10 bokeh-server.

···

Le mardi 10 novembre 2015 16:01:55 UTC+1, [email protected] a écrit :

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

Just to inform you, I was able to run the example that Fabio linked in his message by replacing this line :
‘from bokeh.models.actions import Callback’

by this line :

‘from bokeh.models.callbacks import CustomJS’

which is compatible with Bokeh version 0.10

···

Le mardi 10 novembre 2015 16:42:57 UTC+1, [email protected] a écrit :

First of all, thanks for your interest and your answers.

So Fabio, I already found the stocks downsample dashboard demo but I wasn’t able to run it. Indeed I think it is based on an old version of Bokeh because it calls bokeh.models.actions.Callback and there isn’t any bokeh.models.actions anymore according to the documentation. I tried to replace this import by bokeh.models.callbacks.Callback but it didn’t work. I think it’s two different classes. But thanks for the link anyway !

And Bryan thanks for your answer very helpful. Forward I think I will use the bokeh-server but for now I’m going to give a try to the solution without server waiting for the 0.11 release. So I’m going to follow your advice and not implement any solution based on the 0.10 bokeh-server.

Le mardi 10 novembre 2015 16:01:55 UTC+1, [email protected] a écrit :

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

Hi,

It’s definitely a regression due to API changes between 0.9 and 0.10. Thank you very much for getting this back. Would you mind opening an issue on GitHub so we can track this or, even better, send a pull request with your fixes?

Thanks again

Fabio

···

On Tue, Nov 10, 2015 at 10:22 AM, [email protected] wrote:

Just to inform you, I was able to run the example that Fabio linked in his message by replacing this line :
‘from bokeh.models.actions import Callback’

by this line :

‘from bokeh.models.callbacks import CustomJS’

which is compatible with Bokeh version 0.10

Le mardi 10 novembre 2015 16:42:57 UTC+1, [email protected] a écrit :

First of all, thanks for your interest and your answers.

So Fabio, I already found the stocks downsample dashboard demo but I wasn’t able to run it. Indeed I think it is based on an old version of Bokeh because it calls bokeh.models.actions.Callback and there isn’t any bokeh.models.actions anymore according to the documentation. I tried to replace this import by bokeh.models.callbacks.Callback but it didn’t work. I think it’s two different classes. But thanks for the link anyway !

And Bryan thanks for your answer very helpful. Forward I think I will use the bokeh-server but for now I’m going to give a try to the solution without server waiting for the 0.11 release. So I’m going to follow your advice and not implement any solution based on the 0.10 bokeh-server.

Le mardi 10 novembre 2015 16:01:55 UTC+1, [email protected] a écrit :

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

You received this message because you are subscribed to the Google Groups “Bokeh Discussion - Public” group.

To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].

To post to this group, send email to [email protected].

To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/30c88ec7-5dce-4cbc-b185-6834878ad174%40continuum.io.

For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Fabio Pliger

Senior Software Engineer, Bokeh

Hello Fabio,

I sent a pull request to fix these incompatibilities issues with the 0.10 version.

I’m glad this helped.

Best regards,

Alec

···

Le mardi 10 novembre 2015 16:01:55 UTC+1, [email protected] a écrit :

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

This is awesome! Thank you Alec!

···

On Thu, Nov 12, 2015 at 3:03 AM, [email protected] wrote:

Hello Fabio,

I sent a pull request to fix these incompatibilities issues with the 0.10 version.

I’m glad this helped.

Best regards,

Alec

Le mardi 10 novembre 2015 16:01:55 UTC+1, [email protected] a écrit :

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

You received this message because you are subscribed to the Google Groups “Bokeh Discussion - Public” group.

To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].

To post to this group, send email to [email protected].

To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/caa64065-aed0-4916-abb1-83abf4814eef%40continuum.io.

For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Fabio Pliger

Senior Software Engineer, Bokeh

Hi,

always interested in using Bokeh to downsample some graphs, I would like to know if you could give me a date of the release of the 0.11 version.

Indeed, you adviced me not to begin a project with the bokeh server of version 0.10. So I’m looking forward to test the 0.11 version.

Alec

Hi Alec,

This is atually a current topic of discussion. We are very excited about the 0.11 release and the new server, many folks have already been able to use it more easily. But we want to make sure the 0.11 release is as solid, polished, and documented as it can be. With a big holiday season coming up, I would say a somewhat likely scenario is this:

* a well-publicized "release preview" in mid-December with initial (but probably incomplete) docs and examples for the server

* full 0.11 release the first week of January.

Once we come to a decision for certain regarding the release schedule I will update the mailing list.

Bryan

···

On Dec 1, 2015, at 2:40 AM, [email protected] wrote:

Hi,

always interested in using Bokeh to downsample some graphs, I would like to know if you could give me a date of the release of the 0.11 version.
Indeed, you adviced me not to begin a project with the bokeh server of version 0.10. So I'm looking forward to test the 0.11 version.

Alec

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/2224279d-793b-490a-b3ce-27ec64fe6a2d%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

Hi Bryan,

Thanks for all this information and thanks for keep me informed about the evolution of the 0.11 release.

I think I will try the new server since mid-December.

Best regards,

Alec

···

Le mardi 10 novembre 2015 16:01:55 UTC+1, [email protected] a écrit :

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

Just a quick update we wanted a chance to make sure this release is as polished as possible, the release date is now January 6.

Regards,

Bryan

···

On Dec 2, 2015, at 2:18 AM, [email protected] wrote:

Hi Bryan,

Thanks for all this information and thanks for keep me informed about the evolution of the 0.11 release.
I think I will try the new server since mid-December.

Best regards,

Alec

Le mardi 10 novembre 2015 16:01:55 UTC+1, alec...@gmail.com a écrit :
I'm relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I'm conscient that actual browsers can't handle such an amount of data. This is why I'm trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That's what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn't seem complete to help me :Deploying the Bokeh Server — Bokeh 0.10.0 documentation

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I'm not able to recover any of this examples on Internet. All links I found were invalid. This is why I'm posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/095233db-fab3-4bfe-b14b-08192ef7a1e8%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

Hello Bryan, Happy New Year !

Thanks for the quick update. A simple question : Is the release date always planned for tomorrow?

Best regards,

Alec

···

Le jeudi 10 décembre 2015 06:12:37 UTC+1, Bryan Van de ven a écrit :

Just a quick update we wanted a chance to make sure this release is as polished as possible, the release date is now January 6.

Regards,

Bryan

On Dec 2, 2015, at 2:18 AM, [email protected] wrote:

Hi Bryan,

Thanks for all this information and thanks for keep me informed about the evolution of the 0.11 release.

I think I will try the new server since mid-December.

Best regards,

Alec

Le mardi 10 novembre 2015 16:01:55 UTC+1, [email protected] a écrit :

I’m relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I’m conscient that actual browsers can’t handle such an amount of data. This is why I’m trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.

Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc

That’s what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn’t seem complete to help me :http://bokeh.pydata.org/en/0.10.0/docs/user_guide/server.html#downsampling-with-server

I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I’m not able to recover any of this examples on Internet. All links I found were invalid. This is why I’m posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.

Thank you in advance !


You received this message because you are subscribed to the Google Groups “Bokeh Discussion - Public” group.

To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].

To post to this group, send email to [email protected].

To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/095233db-fab3-4bfe-b14b-08192ef7a1e8%40continuum.io.

For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Yes, the 0.11 release is tomorrow, there is an RC1 available now.

Bryan

···

On Jan 5, 2016, at 2:34 AM, [email protected] wrote:

Hello Bryan, Happy New Year !

Thanks for the quick update. A simple question : Is the release date always planned for tomorrow?

Best regards,

Alec

Le jeudi 10 décembre 2015 06:12:37 UTC+1, Bryan Van de ven a écrit :
Just a quick update we wanted a chance to make sure this release is as polished as possible, the release date is now January 6.

Regards,

Bryan

> On Dec 2, 2015, at 2:18 AM, alec...@gmail.com wrote:
>
> Hi Bryan,
>
> Thanks for all this information and thanks for keep me informed about the evolution of the 0.11 release.
> I think I will try the new server since mid-December.
>
> Best regards,
>
> Alec
>
> Le mardi 10 novembre 2015 16:01:55 UTC+1, alec...@gmail.com a écrit :
> I'm relatively new on Python and Bokeh technology. My goal is actually to be able to display line charts containing millions of points (like around 5 millions) in a browser. I'm conscient that actual browsers can't handle such an amount of data. This is why I'm trying to implement a downsampling algorithm to adapt the amount of points according to the user zoom.
>
> Bokeh technology seems to be the technology I need. Indeed, I saw the following video on YouTube which presents a downsampling example which works perfectly : https://www.youtube.com/watch?v=kPknmEwQ3Rc
>
> That's what I want to implement for my project. So I read a lot of the User guide in the Bokeh website but the section for downsampling is empty and documentation doesn't seem complete to help me :Deploying the Bokeh Server — Bokeh 0.10.0 documentation
>
> I read some posts on Internet like on GitHub and some people talk about Bokeh examples for downsampling using bokeh-server. Unfortunately, I'm not able to recover any of this examples on Internet. All links I found were invalid. This is why I'm posting here. I would like to know if anybody would have a working project of downsampling using Bokeh or a link to share.
>
> Thank you in advance !
>
>
> --
> You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to bokeh+un...@continuum.io.
> To post to this group, send email to bo...@continuum.io.
> To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/095233db-fab3-4bfe-b14b-08192ef7a1e8%40continuum.io\.
> For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/393f31e0-edf4-4359-85c3-9ae95d01425f%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.