Get Started with WWT 2022: For Researchers
For astronomy researchers and other people working with scientific astronomy data, a great way to use WWT 2022 is in the JupyterLab environment. This page walks you through:
Try It Out Online
To try out WWT in JupyterLab without needing to install anything, launch our cloud-based tutorial notebooks! Because they run on a free service (MyBinder), these notebooks lack the computational power for many tasks, but they will give you a sense of how the app works.
Install the Python Software
To use WWT 2022 on your own laptop, you should install JupyterLab and WWT’s Python software.
If you need to install JupyterLab, see these instructions.
For the WWT packages, you can install using either the pip
tool or conda
(or also mamba
) if you activate the conda-forge package channel. If you’re unsure, we recommend conda
and conda-forge. Learn more about conda-forge here.
To install with pip
, run the following in your terminal:
pip install pywwt toasty wwt_jupyterlab_extension wwt_kernel_data_relay
To install with conda
, run:
conda install pywwt toasty wwt_jupyterlab_extension wwt_kernel_data_relay
Once that is done, there are a few extra terminal commands to help ensure that the optimal JupyterLab experience is set up:
jupyter labextension install ipyevents @jupyter-widgets/jupyterlab-manager pywwt
jupyter nbextension install --py --sys-prefix pywwt
jupyter nbextension enable --py --sys-prefix pywwt
jupyter serverextension enable --py --sys-prefix pywwt wwt_kernel_data_relay
If the installation is successful, then the next time you start up JupyterLab the “Launcher” display should now contain an AAS WorldWide Telescope icon:
You can use this to open the WWT app, and then start controlling WWT from a Python notebook with:
from pywwt.jupyter import connect_to_app
wwt = await connect_to_app().becomes_ready()
The pywwt installation instructions contain additional information as well as some troubleshooting steps if the above recipe doesn’t work for you. See also Getting Help below.
Next Steps
Once the Python packages are installed, you should be ready to do a lot with WWT! Once again we recommend checking out our cloud-based tutorial notebooks to learn more about what you can do with WWT. The pywwt documentation gives the detailed information about how to control WWT from Python.
The WWT Python tools also install several command-line tools that you might find useful: wwtdatatool
and toasty
. The toasty view
command may come especially in handy for viewing images from the command line.
Getting Help
If you run into any issues, we recommend asking in the #wwt
channel of the Astropy Slack workspace. If you’re not already a member, you can get an Astropy Slack account in one simple step.