Package pyraf :: Module irafexecute
[hide private]
[frames] | no frames]

Module irafexecute

source code

irafexecute.py: Functions to execute IRAF connected subprocesses

$Id: irafexecute.py 806 2007-11-07 19:21:39Z sontag $

Classes [hide private]
  IrafProcessError
  _ProcessProxy
Proxy for a single process that restarts it if needed
  _ProcessCache
Cache of active processes indexed by executable path
  IrafProcess
IRAF process class
Functions [hide private]
 
_getExecutable(arg)
Get executable pathname.
source code
 
IrafExecute(task, envdict, stdin=None, stdout=None, stderr=None, stdgraph=None)
Execute IRAF task (defined by the IrafTask object task) using the provided envionmental variables.
source code
 
Asc2IrafString(ascii_string)
translate ascii to IRAF 16-bit string format
source code
 
Iraf2AscString(iraf_string)
translate 16-bit IRAF characters to ascii
source code
Variables [hide private]
  IPC_PREFIX = numpy.array([01120], numpy.int16).tostring()
  IPCOUT = "IPC$IPCIO-OUT"
  IPCDONEMSG = "# IPC$IPCIO-FINISHED\n"
  isBigEndian = 0
  stdimagekernel = gki.GkiController()
  processCache = _ProcessCache()
  _p_par_get = r'\s*=\s*(?P<gname>[a-zA-Z_$][\w.]*(?:\[\d+\])?)\...
  _p_par_set = r'(?P<sname>[a-zA-Z_][\w.]*(?:\[\d+\])?)\s*=\s*(?...
  _re_msg = re.compile(r'(?P<par_get>'+ _p_par_get+ ')|'+ r'(?P<...
  _p_curpack = r'_curpack(?:\s.*|)\n'
  _p_stty = r'stty.*\n'
  _p_sysescape = r'!(?P<sys_cmd>.*)\n'
  _re_clcmd = re.compile(r'(?P<curpack>'+ _p_curpack+ ')|'+ r'(?...

Imports: os, re, signal, string, struct, sys, time, types, numpy, cStringIO, subproc, filecache, wutil, iraf, gki, irafutils, irafukey, IrafTask, irafgwcs


Function Details [hide private]

_getExecutable(arg)

source code 

Get executable pathname.

Arg may be a string with the path, an IrafProcess, an IrafTask, or a string with the name of an IrafTask.


Variables Details [hide private]

_p_par_get

Value:
r'\s*=\s*(?P<gname>[a-zA-Z_$][\w.]*(?:\[\d+\])?)\s*\n'

_p_par_set

Value:
r'(?P<sname>[a-zA-Z_][\w.]*(?:\[\d+\])?)\s*=\s*(?P<svalue>.*)\n'

_re_msg

Value:
re.compile(r'(?P<par_get>'+ _p_par_get+ ')|'+ r'(?P<par_set>'+ _p_par_\
set+ ')')

_re_clcmd

Value:
re.compile(r'(?P<curpack>'+ _p_curpack+ ')|'+ r'(?P<stty>'+ _p_stty+ '\
)|'+ r'(?P<sysescape>'+ _p_sysescape+ ')')