Search
Text Size:
Smaller Text Normal Text Larger Text

Facebook

ALFOSC Sequencer Command Documentation

Go to the SEQUENCER Reference Manual Main Page.

Instrument : ALFOSC
Observing Mode: ANY IMA SPEC POL
Command Type: ANY DATA DET DISP INST TEL
Usage: BASIC GENERAL STAFF
Description: SHORT LONG

SystemCommandArgumentsDescriptionType
alfosc abort [-d] Aborts an ongoing exposure (see also expose). DET
alfosc acquisition [-c] [-q] [-nofo] <slit> <tt>

Script for ALFOSC-spectroscopy target acquisition. Supported modes:
  - single-star long-slit
  - echelle
  - spectropolarimetry

  • -c   make a check image of the star and the slit.
  • -q   query the user for another iteration.
  • -nofo   do not execute alfosc.focus-offset
  • <slit-specifier>   unambiguous string to specify slit.
  • <exptime>   exposure time for target acquisition images.
Will first do a binned full-frame image and then another iteration on a 800x800 windowed image. The binned image is taken with 1/4 of the requested exposure time. The acquisition images are analysed interactively using slitoff, which will move the telescope and guide probe to get the star on the requested slit.
The user may request a check of the positioning by making an additional test image with the slit in the beam. In this case the slit will be left in the beam at exit of the script. The user may request an interactive query, which allows to do additional slitoff iterations, and in case a slit image is requested to do aditional slit images.
If a polarimetry slitlet is specified, the script will setup for spectropolarimetry. This script makes sure that the aperture and grism wheels are correctly positioned, and does not move any of the filter wheels for in case a (blocking-)filter has to be in the beam (which should be put in the beam before starting alfosc.acquisition). Exception: if a filter-wheel (cross-disperser) grism is in the beam, the filter wheel will be put to OPEN. Moves the calibration mirror out of the beam. Moves the FAPOL carriage in/out when necesary. Moves to the default internal focus for normal and specpol setups. Executes alfosc.focus-offset before the first acquisition image is taken, unless command-line flag -nofo is given. Exits with full-frame unbinned CCD settings, and autosave_on. Note: the slit specifier should be a unique string. A list of optical elements can be found here.
Usage example:
  alfosc.acquisition -c -q Slit_1.0 2   Makes acquisition with 2s exposure time, using horizontal 1.0" slit, shows check-image of the star and the slit and queries user for another iteration.
TEL
alfosc allopen [-e] Will move all ALFOSC/FASU optical wheels to the OPEN position. Only wheels that according to the ALFOSC status are not already OPEN will be commanded to move. FASU wheels will always be commanded to move. INST
alfosc autoshow_off [-d] Turns off the automatic image display while reading out. If DS9 is running it will be terminated. DISP
alfosc autoshow_on [-d] Turns on the automatic image display while reading out. If no DS9 is running one will automatically be started. DISP
alfosc calibexp [-e] [-f] [-n <nn>] [-o <ObjName>] [-lmi] <lampID> <tt> Script for making a calibration spectrum with ALFOSC. Possible arguments are:
  • -e      echo mode: do not execute commands, only echo them
  • -f      fast mode: script will return during the readout of the last exposure
  • -n <Nexp>   optional number of exposures (default=1)
  • -o <ObjectName>   optional ObjectName
  • -lmi   if set the mirror will stay in the beam at exit
  • <lampID>       with <lampID>=He/Ne/HeNe/ThAr/Halogen
  • <exptime>   exposure time
Sets the ALFOSC calibration items (mirror & lamps) up for a calibration spectrum, takes the calibration image(s) of which the last one in the background, switches off lamps, and per default takes calibration mirror out at exit. Switches autosave_on, and leaves it on. Moves FAPOL out if necesary. Sets header IMTYPE to FLAT/WAVE . If an <ObjectName> is given (double quoted if containing spaces), then the string will be added to the already present lamp specifier in the OBJECT FITS keyword. If CNTR-C is pressed the ongoing exposure will be aborted, and the calibration mirror will be moved out of the beam. NOTE: the last exposure will be taken in the background, so that instrument setup can be done during readout.
Usage example:
  alfosc.calibexp -n 2 Halogen 15   Makes 2 halogen flatfield images with individual exposure time of 15s.
DET
alfosc carriage [-d] [pos] [ready] [action] Moves FAPOL carriage in or out with the [action] keyword. [action] can be 'in', 'IN', 'out' or 'OUT'. [pos] returns '1' if the carriage is in the lightpath, '0' if it is out. [ready] returns '0' if the element is moving, '1' if it is ready. INST
alfosc cirpolexpose [-e] <Nang> <ObjName> <tt> <Ncyc> [-nowindow] Sets up and executes a set of circular polarimetry imaging exposures with <Nang> angles, exposure time <tt> and <Ncyc> cycles. If optional argument -nowindow is used, no windowing is applied. Available number of angles: 2 (0°, 90°) and 4 (0°, 90°, 180°, 270°). DET
alfosc cirpolspec [-e] <Nang> <ObjName> <tt> <Ncyc> Sets up and executes a set of circular polarimetry spectroscopy exposures with <Nang> angles, exposure time <tt> and <Ncyc> cycles. Available number of angles: 2 (0°, 90°) and 4 (0°, 90°, 180°, 270°). DET
alfosc dark [-d] [-t] [-f] <tt> Makes a dark exposure of <tt> seconds. To abort the exposure press "Control-C". If the option [-f] (fast mode) is used, the prompt will be returned when the exposure time is over and before the readout begins. DET
alfosc display [<file>] Loads an image into the ALFOSC DS9 display. If no <file> is specified, the last image obtained will be loaded. If no DS9 display exists, one will be started. DISP
alfosc dither [-e] [-t] [-nowakeup] <pattern> <offset_size> <tt> Takes single exposures at each pointing of a dither pattern. The pointings in a dither pattern are symmetrical around the initial pointing, except for the ABBA scripts, which starts with an exposure on initial pointing. It is possible to specify a negative offset size, in which case the offsets are performed in the opposite direction.
  • [-e]: Echo script on stdout, do not execute
  • [-t]: Simulate exposure only
  • [-nowakeup]: no astrowakeup at the end of script
  • <pattern> predefined dither pattern.
  • <offset_size> telescope offset in arcsec between each exposure.
  • <exptime> exposure time at each pointing.
The dither pattern can be one of the following listed below:
  • 2X : 2-point (X)
  • 3X : 3-point (X)
  • 5X : 5-point (X)
  • 2Y : 2-point (Y)
  • 3Y : 3-point (Y)
  • 5Y : 5-point (Y)
  • 5D : 5-point (dice 5)
  • 4G : 2x2 grid
  • 9G : 3x3 grid
  • 16G : 4x4 grid
  • ABBAX : A-B-B-A (X)
  • ABBAY : A-B-B-A (Y)
Usage example:
  alfosc.dither 3X 20 15   Makes a 3-point X dither pattern with a 15s exposure at each dither point and a 20" offset between each exposure.
DET
alfosc easyflat [-f] [<N>] A script to do <N> imaging skyflats. If the argument is not given, it will only do one skyflat. Takes a small unbinned Y-windowed flat image, finds median value and bias level (using qc-user@elena:alfosc/skyflats/alfoscskycounts.py), sets back the original window/binning and fires off an exposure aiming for 100 kADU. If the test-image count rate is too high or too low, then the script either retries the test image after 20 seconds, or exits (depending on morning or evening). Once a real flat-field image is taken, this and any subsequent flat-field images are also analysed, and the next exposure time is computed accordingly. The exposure-time algorithm is based on the requirements
  • the minimum exposure time is 1 second
  • the maximal exposure time is 300 seconds
  • the minimum count level is 30 kADU
  • the maximal count level is 250 kADU
  • the aim is 100 kADU
When the sky is dark, and the counts aimed-for cannot be reached within 300 seconds, the script will still take a 300s flat if the expected counts are above the minimum acceptable count level (30 kADU). Similarly, for bright sky, a 1-second flat will be taken if the counts will be below the maximal count level of 250 kADU. Does a teloffset after each flat during readout, in a spiraling sequence, with a grid spacing of 15 arcsec. Does not do any instrument setup. Switches on autosave, and leaves it on. Switches on remsave (to /data/service/calib/), and switches it off at exit. Does not alter amplifier settings. Note: polarimetry flats will only work with polwin.

If the -f flag is given, for fast mode, the prompt will be returned to the shell during the last readout.

DET
alfosc expose [-d] [-t] [-f] <tt> Makes an exposure of <tt> seconds. To abort the exposure press "Control-C". This command checks if ALFOSC, FASU and FAPOL are ready before beginning the exposure. If 90 seconds occurs and it is not ready this command will time out. If the option [-f] (fast mode) is used, the prompt will be returned when the exposure time is over and before the readout begins. If [-f] is used, make sure that "alfosc.wait-camera-state idle"-command is given before any "alfosc_camera_commands". If the exposure time is larger than 300 seconds, the time left until the rotator reaches its limit will be checked. If there is not time enough to complete the exposure, an error will be generated and the exposure will not start. DET
alfosc focus [-e] [-n <N>] [-nodefault] [-t <nn>] [-a <mode>] Fully automated focus script for ALFOSC.
[-n <N>]: Number, <N>, of maximal loops, default is 3.
[-t <nn>] Expose <nn> seconds. Default is 10.
[-nodefault]: Start from actual focus rather than default focus.
[-a <mode>]: Acquisition mode. <mode> can be:
  • noacq: Use current pointing for focusing.
  • nearest: Use nearest focus field from current pointing.
  • optimal: Use nearest focus field between 60-70 degrees altitude (default)
Focus is determined without any filter in the beam. Filter and any other ALFOSC instrument & detector settings will be saved before running the focus script and restored at the end.
The 'focus' command is the recommended way of focusing the telescope. In case the command fails, for instance if too few stars are detected in the image, the focus can be determined in a more interactive mode by using the commands focuspyr-setup, expose, focuspyr, focus-position (see documentation on these commands for further information).

Usage example:
  alfosc.focus -n 4 -t 15 -a nearest   Focuses the telescope using the nearest focusfield, doing 4 loops with individual exposures of 15s.

TEL
alfosc focus-offset [-e] Optics in the beam introduces a telescope focus offset (see table). The 'focus-offset' command checks what is currently in the FASU and ALFOSC filter wheels and applies the corresponding focus offset (using foc-del) when possible. The focus offset introduced by a retarder plate in polarimetry mode is also accounted for. Be very careful when using this command. Focus offset for many optical elements are not known and as a consequence the telescope may in fact not be in focus even after using this command. If the focus offset is not known, 0 will be assumed. If this occurs, a warning message will appear both in the talker window and in the sequencer window. Several warning messages may appear if several optical elements in the beam have unknown focus offsets. The final telescope focus offset applied is the sum of the offsets for the element in each wheel, and may therefore be wrong if any offset is unknown. Do not use this command in scripts unless you are absolutely sure that the focus offset are known for all optical elements to be used. TEL
alfosc imexam Initiates an IRAF imexam session on the image currently loaded into the ALFOSC DS9. While active in the imexam session, no further commands can be issued from the sequencer window. To kill the imexam session type q on the image in the postprocessing display.

CURSOR KEY COMMANDS:

?       Print help
a       Aperture radial photometry measurement (see above for output)
c       Column plot
e       Contour plot
f       Redraw the last graph
j       Fit 1D gaussian to image lines
k       Fit 1D gaussian to image columns
l       Line plot
m       Statistics
            image[section] npixels mean median stddev min max
q       Quit
r       Radial profile plot (see above for output)
s       Surface plot
x       Print coordinates
            col line pixval [xorign yorigin dx dy r theta]
DATA
alfosc lamp [-d] [position] <n> <m> Turn on/off lamp no. <n>, where <n> is [1-4] and <m>='1' to turn on and <m>='0' to turn off. Current (29/10-2007) lamp setup: Lamp 1 is "He" Lamp 2 is "Ne" Lamp 3 is "Halogen" Lamp 4 is "ThAr Hollow Cathode". A timer will turn off any lamp after 1200 sec. Subsequent commands to turn on a lamp will result in the timer being reset to 1200 seconds. [position] returns a 4 bit pattern corresponding to the state of the 4 lamps: If bit no. 1 is set, lamp no. 1 is on, else off If bit no. 2 is set, lamp no. 2 is on, else off If bit no. 3 is set, lamp no. 3 is on, else off If bit no. 4 is set, lamp no. 4 is on, else off INST
alfosc linpolexpose [-e] <Nang> <ObjName> <tt> <Ncyc> [-nowindow] Checks if polarizer and Calcite are in and moves them in if necessary and does cycles of exposures. The object name is set to <myobject> and the current polarizer angle is added (e.g. "<myobject> 0deg"), object name is cleared when script ends. By default, the script windows the read-out using alfosc.polwin, with option -nowindow, no windowing is applied! Available number of angles: 4 (0°, 22.5°, 45°, and 67.5°) 8 (0° to 157.5° in steps of 22.5°) 16 (0° to 337.5° in steps of 22.5°) DET
alfosc linpolspec [-e] <Nang> <ObjName> <tt> <Ncyc> Checks if polarizer and polarimetry slitlet are in and moves them in if necessary and does cycles of exposures. The object name is set to <myobject> and the current polarizer angle is added (e.g. "<myobject> 0deg"), object name is cleared when script ends. Does NOT window the read-out! Available number of angles: 4 (0°, 22.5°, 45°, and 67.5°) 8 (0° to 157.5° in steps of 22.5°) 16 (0° to 337.5° in steps of 22.5°) DET
alfosc log-comment "Comment in quotes" [file1 file2 ...] When invoked with just the comment, it will be applied to the latest available image with a prefix for the current night (which starts at noon) and the sequencer's instrument.

If image names are provided, the program will test the existence of ALL them before applying the change.

Eg.

        $ alfosc.log-comment "This is a comment"
        $ alfosc.log-comment "Comment for two" ALug170154 ALug170155
Notice that there's no need to add the ".fits" after each image's name

If no arguments are provided, a usage message is displayed

DATA
alfosc mdark [-t] <tt> <nn> Makes <nn> dark exposure of <tt> seconds. To abort the exposures press "Control-C". The image type (IMTYPE keyword) will be set to "DARK" if the exposure time is non-zero and "BIAS" if it is zero. DET
alfosc mexpose [-t] <tt> <nn> [<imtype>] Makes <nn> exposures of <tt> seconds. To abort the exposures press "Control-C". The <imtype> option (IMTYPE keyword) is optional and must be a text string without spaces. There are reported problems with this command that have not yet been solved. If you experience this, please use the alternative command single-mexpose. If the exposure time is larger than 300 seconds, the time left until the rotator reaches its limit will be checked. If there is not time enough to complete the exposure, an error will be generated and the exposure will not start. DET
alfosc object [-d] <text> Sets the FITS keyword OBJECT to <text>. DATA
alfosc polarizer [-d] [pos] [ready] <n> Moves the polarizer to angle <n>, where <n> is any multiple of 22.5 between '0' and '337.5'. [pos] returns the current polarizer position. [ready] returns '0' if the element is moving, '1' if it is ready. INST
alfosc polwin Windows the readout, optimized for imaging polarimetry. DET
alfosc qicpol [<2ndfile>] Circular polarimetry quick-look tool (FAPOL+ calcite) which calculates the circular polarization from a set of two images (retarder plate positions 0 and 90.0 degrees). The flux of each image is measured with fixed aperture using iraf/apphot from raw images. See more detailed description of the script from here DATA
alfosc qilpol [<4thfile>] Linear polarimetry quick-look tool (FAPOL+ calcite) which calculates the linear polarization from a set of four images (retarder plate positions 0, 22.5 45 and 67.5 degrees). The flux of each image is measured with fixed aperture using iraf/apphot from raw images. See more detailed description of the script from here. DATA
alfosc quickspec [<file>] Extracts spectra and applies an approximate wavelength calibration on an ALFOSC spectroscopic image using the iraf tasks apall and dispcor. If no file is specified, spectral extraction from the last image written to disk will be attempted. Extracted spectra are kept in the directory /data/reduced/alfosc/ on the instrument computer. Existing spectra will be overwritten if the task is re-run on the same file. The wavelength calibration is done using standard wavelength settings for the standard horizontally oriented central slits. The wavelength calibration is only approximate, and is most likely based on a slit that you are not currently using. Note that the slits have different Y-positions and hence different wavelength zeropoints, and that hence zeropoint offsets of for instance 200 Ångström are normal. The quickspec will leave the user in an IRAF splot session. To kill the session type q in the postprocessing graphics window. There are 2 ways of initiating quickspec. Automatic (see command quickspec-config auto=yes below), and from the sequencer command line. * When called from the sequencer command line, all input and output will go through that sequencer terminal. * When automatic, the input and output goes through the BIAS 'command' window. DATA
alfosc quickspec-config [<options>] Use this command to set the IRAF apall task parameters used in the quickspec script.
   auto=[yes|no] : Automatically run quickspec on incoming images
   kill=[yes|no] : Automatically remove previous quickspec windows
   default : loads default values.
Below parameters are specific for the apal iraf task:
   background=[none|average|median|minimum|fit]
   weights=[none|variance]
   clean=[yes|no]
   edit=[yes|no]
   nfind=[1-10] (useful for Echelle spectra, MOS spectra, spectropolarimetry, and longslit spectra with more than one object on the slit)

If the command is issued without any options, current parameter settings will be listed.

DATA
alfosc readout [-d] Closes the shutter and reads out the ccd. You have to put the exposure in the background first. This is achieved by pressing Ctrl+Z in the sequencer where the expose command is running, followed by running the command bg. Note that this command does not work correctly when using a window in Y direction: data from a wrong window will be saved to file. DET
alfosc readspeed [-d] <readout_speed> Sets the CCD readout speed to <readout_speed> kpix/second. Valid values for <readout_speed> are 100, 200, 400 or 800. DET
alfosc rempath [-d] <nn> Sets the remote saving path to <nn>. DATA
alfosc remsave_off [-d] Turns off remote saving. DATA
alfosc remsave_on [-d] Turns on remote saving. DATA
alfosc reset-log The script will use infosys.kill to reset the monitoring system, then it will wait for a set number of seconds, and at last it will instruct the obslog to show the listing for alfosc, all the while informing the user about what is happening

If there's any error, the script will notify the user and suggest further actions.
DATA
alfosc resetxy [-d] Resets the ccd binning to 1, the X and Y size to maximum and the X and Y beginning to 1. DET
alfosc slitoff [slit=<nn> | xref=<x> yref=<y>] Calculates the telescope offset required to bring a target onto a given slit and performs the required telescope offset. The slit number <slitno> refers to the position of the requested slit in the ALFOSC slit wheel. Alternatively, an (<x>,<y>) pixel position can be given as reference. The script uses the currently loaded DS9 image and assumes this corresponds to an acquisition image of the field the telescope currently is pointed at. The target is identified interactively by the user through an imexam session. TEL
alfosc slitrot Uses the currently loaded DS9 image to compute the TCS field rotation angle required to align two objects along a slit. The targets are identified interactively by the user through an imexam session. DATA
alfosc teloffset <n> <m> Offsets an object on the CCD <n> arcseconds in X direction, <m> arcseconds in Y direction. TEL
alfosc wheels [-e] [-s <slit>] [-g <grism>] [-c <crossdisp>] [-f <filter>] [-nowait] [-forceFASU] Script to setup all 5 ALFOSC wheels, in quickest possible way. Possible arguments are:
  • -s <slit>   aperture-wheel item string
  • -g <grism>   grism string
  • -c <crossdisperser>   crossdisp grism string
  • -f <filterID>   filter number
  • -nowait   exit while wheels are moving
  • -forceFASU   force the FASU wheels to move even when at required position
Each wheel defaults to the OPEN position, unless it needs to be put to a different position as requested through the command-line arguments. Consequently, without any arguments alfosc.wheels puts all wheels to open. The script uses alfosc.optics to check the feasibility of the requested setup. If feasible, the wheels will be moved to put the requested items in the beam. If wheels are already in the correct position they will not be exercised, except for the FASU wheels when flag -forceFASU is given. If a requested setup is not possible, an error will result, and no wheels will be moved. Note: grism/slit strings should be unique. A list of optical items can be found here. Note: filter ID numbers can be found here. Note: the Focus_Pyr is considered a grism!! Note: for spectroscopy the horizontal/vertical requirements for the optical elements are tested.
Usage examples:
  • alfosc.wheels -f 74   sets up for imaging with filter #74
  • alfosc.wheels -g Focus_Pyr   sets up for focusing without filters
  • alfosc.wheels -s Slit_1.0 -g "#4"   sets up for spectroscopy with slit 1.0" and Gr#4
  • alfosc.wheels -s Slit_1.0 -g "#4" -f 93   sets up for spectroscopy with slit 1.0" and Gr#4 and blocking filter #93
  • alfosc.wheels -s Ech_0.8 -g "#9" -c "#10"   sets up for Echelle spectroscopy with slit 0.8" and Echelle Gr#9 and cross disperser Gr#10
INST
alfosc xbeg [-d] <nn> Sets the X beginning to <nn>. DET
alfosc xbin [-d] <n> Sets the binning factor in the X direction to <n>. DET
alfosc xsize [-d] <nn> Sets the X size to <nn>. DET
alfosc ybeg [-d] <nn> Sets the Y beginning to <nn>. DET
alfosc ybin [-d] <nn> Sets the binning factor in the Y direction to <n>. DET
alfosc ysize [-d] <nn> Sets the Y size to <nn>. DET

In scripts, the syntax alfosc.<command> should be used.
If a part of a command is written in <angle brackets>, this is an argument that should be replaced with a value.
If a part of a command is written in [square brackets], this is an optional argument or flag.
When available, the optional flag -d will write extended debugging information to the log.
When available, the optional flag -e will show the script on standard output instead of executing the commands.
When available, the optional flag -t will only make a simulated exposure. Useful for testing scripts.

Type definitions:
DATA: All commands related to handling/modifying data (editing fits-headers, post-processing etc.).
DET: Commands related to operations with the detector.
DISP: Commands related to displaying images on the instrument computer.
INST: Commands related to operations with the instrument.
TEL: Commands related to operations with the telescope.

Back to top Last modified: November 23 2011