

The cutout service provides a matrix of FITS image cutouts, organized into a web page that has JPEG views of the cutouts, organized into a table, so that clicking on ther JPEG returns the FITS version. The user provides a list of points on the sky, either as CSV or VOTable file, which is part of the service request; the user also provides a list of surveys and the size of the cutout in pixels. When this information is supplied to the Nesssi cutout service, it retrieves cutout images from each position for each survey.
In order to run the cutout service, a file will be uploaded. If the file suffix is "csv", it is assumed to have the CSV format, where there are three columns, for Right Ascension, Declination, and object Name, for example:
318.719200,6.128300,PG 2112+059 324.934200,2.768100,RXS J21397+0246 325.788700,15.618300,RXS J21431+1537
If the file suffix is "xml", then the file is assumed to a VOTable, and that table must contain RA, Dec and Name data columns, which will be found by their UCD values. Such a file can be easily created from VO applications, for example Vizier. The list of targets can also be passed to the service as an argument (see -table below).
The arguments that are sent to the service can be:
Below is a Python program that can be used to drive the cutout service. First we find the file that contains the list of positions, then build the argument list that contains the desired surveys.
import time
import sys
import nesssi_client as nesssi
# Get list of input locations from command line or just use test.xml
if len(sys.argv) > 1:
inputfile = sys.argv[1]
else:
inputfile = "input/test.xml"
# Create a connection
# This uses a proxy certificate , or a key/cert pair from $HOME/.globus if a
# proxy can't be found
nesssiServer=nesssi.client('https://envoy.cacr.caltech.edu:8443/clarens/',debug=0)
# Initialize the service
sessionID = nesssiServer.cutout.init()
print "Session id is ", sessionID
# Arguments for service, surveys to use and cutout size
args = "-surveys PQ:JR,SDSS:g,SDSS:r,DSS2:R "
args += "-size 64 -table "
args += "\"318.719200,6.128300,PG 2112+059;"
args += "324.934200,2.768100,RXS J21397+0246;"
args += "325.788700,15.618300,RXS J21431+1537\""
# Run service
nesssiServer.cutout.run(sessionID, args)
# Monitor every minute for 5 minutes
for i in range(1,5):
msg = nesssiServer.cutout.monitor(sessionID)
print msg
print "sleeping ............"
time.sleep(60)
The following steps are intended so that users can find and query astronomical catalogs on the Vizier system, and download a VOTable of those sources that is suitable as input for the cutout service.