Page tree
Skip to end of metadata
Go to start of metadata

A specific plug-in is being developed to provide SAMP connection and receive data from other VO tools.
This update also improves the support of fits files and compress formats in ImageJ. This requires a version of ImageJ running under java 1.8 (v 1.51 here)
Note: Check if this still works with 2020 version v1.53 - there is apparently something to adapt.

With SAMP connection, ImageJ will provide extended visualization, format conversion, and image processing functions to the VO.

Installation procedure

  • Install a recent version of ImageJ on your computer (see
    For Mac OS, the version "bundled with Java 1.8.0_101" is OK (requires OS X 10.8 or later)
    Plugin files to be distributed on the VESPA wiki when finalized!
  • Install file
    In directory ImageJ/plugins or plugins/Input-Output

  • Install files
    In directory ImageJ/plugins/jar

  • Install file
    in directory ImageJ/macros/AutoRun
    (create directory AutoRun if not present)


Launch ImageJ on your machine and click on new menu item SAMP > SAMP to register it to the Hub (no need to launch TOPCAT first). ImageJ will now receive images sent to the SAMP Hub by other VO applications.
ImageJ will accept fits, jpeg, png, and tiff images, among others. More fits images are now supported, including multi-extension files. Tiff images are prime products in some EPN-TAP services (from digitized photographic plates, e.g., BDIP) but are not usually viewable in a web browser.

For the time being, ImageJ cannot send back images to the Hub. Results have to be stored on the user machine in a VO compliant format (eg, fits, jpg, or png), and possibly loaded in another environment.

A manual of ImageJ in astronomical context is available here:
Additional plugins of interest include:

Use cases:

- ImageJ is now a VO viewer for Tiff images (provided e.g. by the BDIP data service)

- Any image sent to ImageJ can benefit from image processing functions

- Image format can be modified on output (via Save As…), providing effective format conversion functionalities.
Additional type conversions (e.g. 16 to 8 bits, stacking/unstacking, etc) are accessible via menu item Image > Type
Any B&W image can be saved as fits with a minimal header - beware that for fits images, the original header is lost (including WCS)
Saved images can be reopened in a VO tool or a computing environment such as IDL


From the VESPA search interface

On a service result page, select one or more lines (dataproduct_type must be "image") and click the Selected Data > Send Images button (bottom left).
A progress bar is located on the small ImageJ palette during loading of large images (related to each frame for stacks).

From VESPA, many image formats (Fits, JPG, PNG, TIFF, at least) will be samped to ImageJ

• Ex in APIS:

Jupiter_-_1999_14-16_Aug/o5g202x4q_proc.fits    are OK
Uranus_-_2011_09-29_Nov/obrx18hbq_x2d.fits        (multi-extension fits file - this loads as a stack of images with multiple frames)

• Geotiff images are not supported (included in CRISM service or provided via WMS links) - but versions converted to geofits via Gdal are OK (Chiara's routines).

Compressed images such as *.fts.bz2 from CLIMSO are not handled (even with commons-compress installed)
   - A workaround is to samp them to Aladin, then from Aladin to ImageJ

From Aladin

Images can be samped to ImageJ via the menu items:

Interop > Broadcast selected plane
Interop > Broadcast selected image to…

However Aladin will only samp fits-formatted images (since the official MTYPE is image.load.fits); the menu items will be dimmed otherwise


Load a table providing links to images (can be a metadata table from a VESPA result page)
Click "Activation Action" in the main window
In the Set Activation Action window, click View URL as Image and identify the column including the link (access_url or thumbnail_url for an EPN-TAP service); select either All Clients or ImageJ in the Image Viewer menu

The image will be sent to ImageJ on mouse click
   - if this does not work, check the Activation Action value in the main window; if set to (no action) try to open/close it again (by clicking the OK button)

From TOPCAT many image formats (Fits, JPG, GIF, TIFF at least) will be samped to ImageJ (no need to select an image type in the Activation window)

Possible developments

• Autostart the hub connection at launch (like in Aladin, with optional switch)

• Grab the cursor position and send it to / from Aladin via SAMP

• Send back images/results via SAMP - there are use cases for transforms that do not affect image size, but this is difficult for fits images if dimensions are changed (WCS nearly impossible to maintain)

• Better support of compressed files (from CLIMSO)

• Support of VOtable in I/O to store analysis results and load them. The current .xls output files can be loaded in TOPCAT as csv format.

• Check if ImageJ has the ability to compute and return an average of consecutive lines/columns, or averages in the third dimension - this would address many on-line comparison difficulties (e.g., local means of dynamic spectra from APIS, and comparison between MCD and Spicam profiles - the latter would be restricted to cubes however).

• Possible usage in AstroImageJ? Does not work on 3.2.0 (error when launching SAMP)

• Support for geofits, ie complete WCS including planetary frames & Chiara's additional keywords - should in particular return coordinates on the surface of current body (ie: VELN, VELT for Venus) - currently no support at all (and AstroImageJ only support RA/DEC, no planetary coord).

  • No labels