JS9: astronomical image display right in your browser
JS9 brings our Desktop DS9 image display to your browser:
  • display FITS images and tables in a web page
  • display FITS data cubes and multi-extension files
  • drag and drop FITS images and tables
  • retrieve FITS files from data archives
  • change the colormap and scale
  • image pan, zoom and blink, table binning
  • image arithmetic, Gaussian smoothing
  • blend images and apply RGB image filters
  • configure mouse movements and touch events
  • create and manipulate regions of interest
  • extend JS9 using plugins and the public API
  • perform data analysis (local and server-side)
  • configure and control JS9 from within a web page
  • control JS9 from a command shell or Python
  • print images, save images, etc ...

Drag and drop a FITS astronomical data file onto the display and JS9 functionality immediately becomes available: zoom, pan, colormaps, scaling, regions ...

By extending JS9 with the plugin facility and the public API, you can perform browser-based analysis on the displayed image: click the Plugins tab, create a region, move it around ...

In addition, images loaded from a server support remote (server-side) analysis. For example, analysis can run when a region changes, with results displayed back in your browser: click the Analysis tab, choose a task, create a region, move it around ...

Energy Spectrum Counts in Regions Radial Profile
A quick introduction to JS9, regions, and server-side data analysis:
  • Press the mouse in the image and move around to change the contrast and bias (to bring out features).
  • Create one or more regions using the JS9 Region menu.
  • Press the mouse inside a region and drag it to a desired location. (Use an annulus for radial profiles.)
  • Resize or rotate the region by clicking to select it, and then moving one of the handles.
  • Group regions by pressing the meta key and using mouse selection. You then can move/resize/rotate them together.
  • Choose an analysis to run on the back-end server:
    • Energy Spectrum plots a histogram of the energy value of photons in the region(s).
    • Counts in Regions presents a text display of the number of photons found in the region(s).
    • Radial Profile plots the number of photons in each region of an annulus.
  • As you move or resize, the task will run and results will be displayed here.
  • The region context menu has lots of region options.
  • These tasks also can be run from the JS9 Analysis menu.
See the Plugins tab for a demo of browser-based analysis.

Local Analysis Tasks: create a region, move it around ...

Release 1.9 (06/08/16) adds support for multi-extension FITS, 3D cubes, image arithmetic, RGB image processing, gesture configuration, new scales and colormaps

Release 1.8 (03/21/16) adds support for image blending, image filters, wcs reprojections, colorbar, blinking, Gaussian blur, line region with distance measure, raw data layer manipulation.

Release 1.7 (01/12/16) adds support for resizing the display, adding tooltips to catalogs, and embedding JS9 in Jupyter/IPython.

Release 1.6 (11/7/15) adds support for loading FITS URLs via proxy, dealing with large files, and iOS improvements.

Release 1.5 (7/9/15) adds support for importing DS9/Funtools regions, and for running the back-end helper using https.

Release 1.4 (5/3/15) provides bug fixes for the binning plugin, adds a user preference plugin, and supports export to FITS and PNG files.

Release 1.3 (3/30/15) incorporates the standard cfitsio FITS library, using Emscripten to compile to JavaScript.

Release 1.2 (1/4/15) adds support for the new pyjs9 Python interface via GET/POST support in the back-end Node.js server.

JS9 runs on web browsers that support the HTML5 canvas element, including all recent versions of FireFox, Chrome, Safari, and IE.

JS9 is distributed under the terms of The MIT License.

Contact: Eric Mandel, Harvard-Smithsonian Center for Astrophysics

The current JS9 source tar file is available below. This will allow you to display FITS images (drag-and-drop and URL-based access) with all essential functionality, including browser-based plugins.

The pyjs9 Python interface supports the JS9 Public API and a short-cut command interface, communicating with JS9 through the back-end Node helper.

To run the demo pages at your site, download the data tar file.

To configure a back-end Node helper (for server-side analysis and external control), you also will need to install the cfitsio library.

Tar files:

JS9 and pyjs9 also are available on GitHub, where the repositories contain the very latest bug fixes and enhancements:

JS9 is powered by the following technologies, to whom grateful acknowledgment is made:
  • HTML5 for image display and most everything
  • jquery for programming ease (http://jquery.com/)
  • fabric.js for 2D graphics (http://fabricjs.com/)
  • emscripten for C-to-JavaScript ( http://emscripten.org)
  • dynamic drive for light windows (http://www.dynamicdrive.com)
  • flot for plotting (http://www.flotcharts.org/)
  • medialize for jquery.contextMenu (http://medialize.github.io/jQuery-contextMenu/)
  • arrive.js for MutationObserver support (https://github.com/uzairfarooq/arrive)
  • appcropolis for double click support (http://appcropolis.com/blog/howto/implementing-doubletap-on-iphones-and-ipads/)
  • spin.js for spinner support (http://spin.js.org/)
  • Marc J Schmidt for CSS element queries (https://github.com/marcj/css-element-queries)
  • HEASARC for CFITSIO lib (https://heasarc.gsfc.nasa.gov/fitsio/)
  • IPAC for Montage (http://montage.ipac.caltech.edu/)
  • SAO/TDC for WCS lib (http://tdc-www.harvard.edu/wcstools/)

Thanks for important suggestions and (sometimes) code from:

  • Brian Cherinka, JHU (multi-extension FITS, data cubes)
  • Joseph DePasquale, CfA (image blending techniques)
  • Kathy Lestition, CfA (EPO)
  • Briehan Lombaard SAAO (telescope control)
  • John Roll, Facebook (fitsy, data analysis plugins)
  • Pat Slane, CfA (needs of research vs. education)
  • Science Education Department, CfA (EPO)

JS9 development at the Harvard-Smithsonian Center for Astrophysics is supported by Smithsonian Institution and the Chandra X-ray Science Center.

Questions? Please contact Eric Mandel
About |  Research |  Education & Outreach |  Facilities |  Opportunities |  Events |  Press Room |  Contacts |  Support CfA |  Privacy
     Harvard Logo Smithsonian Logo   HARVARD-SMITHSONIAN CENTER FOR ASTROPHYSICS  |   60 GARDEN STREET  |   CAMBRIDGE, MA 02138