npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

jupyter_firefly_extensions

v2.2.0

Published

A package for rendering FITS in Jupyter

Downloads

20

Readme

jupyter_firefly_extensions

A Jupyterlab extension for rendering FITS images with Firefly.

This package is in the development phase. jupyter_firefly_extensions is installable via npm (Javascript side) and pip (Python side).

Overview

This extension adds the following features to JupyterLab:

  • Double click or right-click on a FITS file and see it in a tab
  • Start the full Firefly viewer in a tab.
  • Use FireflyClient in a Python notebook to start Firefly in a tab and send data (tables, images, charts) to it using the FireflyClient API
  • The SlateWidget is a full Firefly viewer widget that provides a FireflyClient instance to embed a full Firefly in a notebook as a widget

Prerequisites

  • JupyterLab ^0.35.1
  • nodejs
  • astropy ^3.0.0
  • firefly_client ^2.1.1

The firefly_client package can be installed with pip install firefly_client.

Very Important: first setup the Firefly URL - 3 ways

  • Add the following line to your ~/.jupyter/jupyter_notebook_config.py

    c.Firefly.url = 'http://localhost:8080/firefly'

Or

  • Add the following line to your ~/.jupyter/jupyter_notebook_config.json under the root object.

    "Firefly": {
      "url": "http://localhost:8080/firefly"
    }

Or

  • Use the environment variable

    setenv FIREFLY_URL http://localhost:8080/firefly

where the URL points to a Firefly server.

Install

pip install firefly_client
jupyter labextension install jupyter_firefly_extensions
pip install jupyter_firefly_extensions
jupyter serverextension enable --py jupyter_firefly_extensions

Install for development

First:

If developing firefly_client, be sure to clone the firefly_client repository (https://github.com/Caltech-IPAC/firefly_client) and then do pip install -e . from inside its directory.

Then:

git clone https://github.com/Caltech-IPAC/jupyter_firefly_extensions
cd jupyter_firefly_extensions
jupyter labextension install . --no-build
jupyter lab build
pip install -e .
jupyter serverextension enable --py jupyter_firefly_extensions

Helpful commands

  • jupyter serverextension list - show a list of server extensions
  • jupyter labextension list - show a list of lab extensions
  • jupyter lab - run jupyter lab
  • jupyter lab build - rebuild after modifying the javascript:

To remove extensions:

jupyter labextension uninstall jupyter_firefly_extensions
jupyter serverextension disable --py jupyter_firefly_extensions
pip uninstall jupyter_firefly_extensions

Examples

The examples directory has several example notebooks to demonstrate the extension features. When using the examples you should copy the directory and contents to another place or jupyter lab will and to keep rebuilding

  • slate-demo-explicit.ipynb, slate-demo-explicit2.ipynb - demonstrates opening a Firefly tab and sending data to it with the FireflyClient python API
  • slate-widget-demo.ipnb - simple demo of the Firefly slate widget