JuliaOptimalTransport / OptimalTransport.jl

Optimal transport algorithms for Julia
https://juliaoptimaltransport.github.io/OptimalTransport.jl/dev
MIT License
93 stars 8 forks source link

Should we create a separate Examples Repository? #124

Closed davibarreira closed 2 years ago

davibarreira commented 2 years ago

Hey guys, I just saw the new Variational Problem example. Loved it! I was studying Wasserstein Gradient Flow these days, but more on theoretical terms, and the example implemented is quite neat! I was wondering what you think of creating a separate repository with notebooks (Pluto maybe?), or do you think this would be redundant? Sorry that I've been inactive these months, I'm quite busy with the phd right now, and hopefully will be able to do more stuff by the end of the year. I'd really like to update our examples using Makie for plots.

With Pluto I've created some very neat interactive Optimal Transport examples, that I presented at school (e.g. Wasserstein solution flowing).

devmotion commented 2 years ago

I use Makie as well, wo it would definitely be nice to have some example with Makie as well 🙂 That being said, Plots and in particular GR are really mature and optimized for static plots, also e.g. with respect to latencies.

I was on vacation in July and August and haven't even read through the new example, so I can't comment on the content. I think it's great if we add more examples but at this point I don't think it's necessary to move them to separare repo. In my experience a separate repo makes it usually more difficult to integrate them in the documentation and keep them uptodate. Apropos examples, my plan was to improve the integration with the documentation and the Github action, similar to what we use eg in JuliaGaussianProcesses (the environments are separated better and everything is built in parallel).

I used Pluto for some teaching and my talks at JuliaCon but I assume it would be less useful for the static exports on the webpage. You can already run the script or the notebook if you want to play around with the examples and IIRC there is a PR to Literate (not sure if it was merged?) that allows to export to Pluto notebooks as well. So it is possible to provide Pluto versions automatically.

davibarreira commented 2 years ago

Allowing Pluto notebook would be great, the interactivity for the plots is just great (but I hate the one-line code and the lack of vim). I agree with you, I'll clean some of my example, and submit to our documentation. I'm still a noob with Makie, but I'm trying to find an excuse to learn it properly. The latency is a b**** though, it really turns me off. But I think it's still worth writing examples on it, since more and more people seem to be migrating, and Makie still lacks a bunch of examples (I don't even now how to rotate the label in the axis and never found an example of such -.-).

zsteve commented 2 years ago

Seconded that the examples could be improved in many ways, but probably an examples repo is overkill for the time being.