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

aladin lite in the viewers list? #99

Open
ManonMarchand opened this issue Jun 27, 2023 · 11 comments
Open

aladin lite in the viewers list? #99

ManonMarchand opened this issue Jun 27, 2023 · 11 comments

Comments

@ManonMarchand
Copy link

Hello again Gluepyter's team,

Would you be interested in a collaboration to add aladin-lite as the possible viewers?

It is a web app that allows visualization of fits files, votables, hips, mocs... and other astronomy standards.
The software looks like this : https://aladin.cds.unistra.fr/AladinLite/

Its source code is there : https://github.com/cds-astro/aladin-lite
There is an ipywidget version here (it was presented at the JupyterCon where I heard of Gluepyter 😉 ) : https://github.com/cds-astro/ipyaladin

image

There was an extension for the glue-desktop software a long time ago : https://github.com/glue-viz/glue-aladin but it does not work anymore

Tagging aladin-lite's dev : @bmatthieu3 cause he asked me to be tagged 🙂

@martinRenou
Copy link
Member

Hello!

That's a good idea!

I guess we have multiple possible approaches for this:

  • Gluepyter makes use of viewers in glue-jupyter (are you confused yet? :P). So we could implement a viewer with ipyaladin in glue-jupyter so that gluepyter can use it.
  • Implement the viewer with ipyaladin directly in Gluepyter for now, and either export it upstream once it's stable or just keep it in Gluepyter.
  • Implement a plugin system for viewers in glue-jupyter (unless it exists already?) and make glue-ipyaladin-viewer a separate Python package that exposes the ipyaladin viewer for gluejupyter to use.

The cleanest would be the later IMO, but the fastest to implement would be the second one probably.

@trungleduc
Copy link
Member

trungleduc commented Jun 28, 2023

  • Implement the viewer with ipyaladin directly in Gluepyter for now, and either export it upstream once it's stable or just keep it in Gluepyter.
  • Implement a plugin system for viewers in glue-jupyter (unless it exists already?) and make glue-ipyaladin-viewer a separate Python package that exposes the ipyaladin viewer for gluejupyter to use.

I prefer a viewer plugin system for gluepyter and make glue-jupyter one of its plugins. So users are free to add more kinds of viewers without depending on glue-jupyter.
Another point is how to keep the compatibility with the glue QT app, if a viewer is added to gluepyter, should it be available also in the QT app?

@martinRenou
Copy link
Member

martinRenou commented Jun 28, 2023

I prefer a viewer plugin system for gluepyter and make glue-jupyter one of its plugins. So users are free to add more kinds of viewers without depending on glue-jupyter.

I'm not sure I understand. glue-jupyter provides our glue application object, so it's the one responsible for handling the interface between the viewers and the application, right? So viewers in gluepyter wouldn't have a choice to depend on glue-jupyter?

should it be available also in the QT app?

That sounds difficult :S Unless we get ipywidgets running in a Qt app using the web viewer Qt thing.

@ManonMarchand
Copy link
Author

ManonMarchand commented Jun 28, 2023

The QT app has this addon : https://github.com/glue-viz/glue-aladin . It got a bit abandoned but I guess we could make it work again?

PS: I'm a bit lost between the three solutions.

@trungleduc
Copy link
Member

I'm not sure I understand. glue-jupyter provides our glue application object, so it's the one responsible for handling the interface between the viewers and the application, right? So viewers in gluepyter wouldn't have a choice to depend on glue-jupyter?

the viewer like aladin does not require a glue-jupyter application object, we only need to feed it the data.

That sounds difficult :S Unless we get ipywidgets running in a Qt app using the web viewer Qt thing.

Or the plugin author needs to create 2 versions of the viewer, one using ipywidgets for gluepyter and another (native/ webview...) for the QT app.

@ManonMarchand
Copy link
Author

Or the plugin author needs to create 2 versions of the viewer, one using ipywidgets for gluepyter and another (native/ webview...) for the QT app.

There is an existing ipywidget version : https://github.com/cds-astro/ipyaladin
You mean that this could be used directly?

@trungleduc
Copy link
Member

trungleduc commented Jun 28, 2023

Or the plugin author needs to create 2 versions of the viewer, one using ipywidgets for gluepyter and another (native/ webview...) for the QT app.

There is an existing ipywidget version : https://github.com/cds-astro/ipyaladin You mean that this could be used directly?

Not with the current architect. For now, we only support the widgets provided by glue-jupyter and the types defined in a session file.
Supporting standalone ipywidgets needs a lot of refactoring and should be discussed with the glue core team.

@martinRenou
Copy link
Member

PS: I'm a bit lost between the three solutions.

We should definitely clarify all this in the README

@astrofrog
Copy link

I think the best way forward would be to revive the glue-aladin plugin and to do something similar to what was done for glue-wwt which is that the plugin package can provide both the Qt and Jupyter viewers. We should get aladin working with 'vanilla' glue-jupyter and we will then get it 'for free' in glue-jupyterlab.

@ManonMarchand
Copy link
Author

Nice! I see that you're the dev of the plugin. Should we move the conversation in the other repository?

@astrofrog
Copy link

@ManonMarchand - sounds good! I've opened an issue here: glue-viz/glue-aladin#2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants