This ChangeLog covers both the Funtools library and the suite of applications. It will be updated as we continue to develop and improve Funtools. The up-to-date version can be found here.
Added a second DS9 init file, funcnts2.ds9, which contains funcnts and radial profile routines that work from the image stored in DS9's memory, rather than the original FITS file. This is useful in cases where no original FITS file exists (e.g., a temp file was created by a program and sent to DS9).
double temp; temp = cur->x; cur->x = cur->y; cur->y = temp;or:
temp = cur->x; cur->x = cur->y; cur->y = temp;When this expression is executed using a command such as:
funcalc -f swap.expr itest.ev otest.evthe resulting file will have values of the x and y columns swapped. Many other features are available in funcalc to make table manipulation easy. See the Funtools program.html documentation.
bincols=([xname[:tlmin[:tlmax:[binsiz]]]],[yname[:tlmin[:tlmax[:binsiz]]]])where the tlmin, tlmax, and binsiz specifiers determine the image binning dimensions:
dim = (tlmax - tlmin)/binsiz (floating point data) dim = (tlmax - tlmin)/binsiz + 1 (integer data)These tlmin, tlmax, and binsiz specifiers can be omitted if TLMIN, TLMAX, and TDBIN header parameters (respectively) are present in the FITS binary table header for the column in question. Note that if only one parameter is specified, it is assumed to be tlmax, and tlmin defaults to 1. If two parameters are specified, they are assumed to be tlmin and tlmax.
funcnts ... | funcnts.gnuplot
funhist snr.ev x | funhist.gnuplot
annulus 512 512 0 100 n=4; -circle 510 510 20or
annulus 512 512 0 25 50 75 100; -circle 510 510 20the excluded region was not being sensed properly. Note that single regions did work properly with exclude regions.
csh> cat fun.sed 1,/---- .*/d /^$/,$d csh> funcnts snr.ev[pha==1] "annulus 512 512 0 200 n=8" | sed -f fun.sed 1 49.000 7.000 0.000 0.000 1941 0.025 0.004 2 91.000 9.539 0.000 0.000 5884 0.015 0.002 3 129.000 11.358 0.000 0.000 9820 0.013 0.001 4 159.000 12.610 0.000 0.000 13752 0.012 0.001 5 176.000 13.266 0.000 0.000 17652 0.010 0.001 6 183.000 13.528 0.000 0.000 21612 0.008 0.001 7 137.000 11.705 0.000 0.000 25528 0.005 0.000 8 198.000 14.071 0.000 0.000 29420 0.007 0.000
on m1: funevents foo.ev m2:1428 on m2: funevents :1428 m3:1428 on m3: funevents :1428 ...etc. Tests indicate that this is faster than pipes on a single machine, once the CPU is saturated on that machine. (But note that it is not faster until the CPU is saturated, due to the efficiency of Unix pipes and the I/O wait time on non-saturated CPUs.) This new facility implements the parallel processing technique called "process decomposition" for pipelines, in which a pipeline process is run on several machines at once, with different machines handling separate parts of the pipeline process.
NB: socket support requires that the libraries:
-lsocket -lnslbe added to the Solaris link line.
funevents "test.ev[row#=3:8]" stdout ... or funevents "test.ev[row#=(3,8)]" stdout ...will only process rows 3 to 8 (inclusive) of the test.ev file. Along with image section specification, use of the row#= keyword implements the parallel processing technique called "data decomposition", in which several copies of a single program operate on different parts of a single data file.
circle 5 5 1 circle 4 4 1then:
funcnts foo.fits @foonow will display the 2 regions in its output, instead of displaying the near useless "@foo". This only works for simple cases where only a file is input, not in odd combinations like:
funcnts foo.fits "@foo,circle 1 1 1"
char *s, *t; n = ((int)s - (int)t);which is invalid on the 64-bit Alpha. Instead use:
char *s, *t; n = (s - t);Also broadened the check for use of dlopen in configure to match Alpha's library configurations (On Alpha, dlopen is in libc).
fundisp foo.ev "time y x"will display columns in that order.
Sorting does not take place if the activate list contains only exclude columns (since there is nothing to sort). Also, you can turn off sorting altogether (mimicking the old behavior) by calling FunColumnActivate() with a "sort=false" in the plist argument:
FunColumnActivate(fun, "y x", "sort=false");or by adding "sort=false" to the activate string itself:
# by default, its sorted fundisp $E "time y x" TIME Y X ---------------- ------- ------- 6.8500 -7 -7 6.8600 -7 -7while:
# turn off sorting ./fundisp $E "time y x sort=false" X Y TIME ------- ------- ---------------- -7 -7 6.8500 -7 -7 6.8600 -7 -7 6.8700
foo.fits,events # event extension foo.fits,pha==1 # filter on default extension foo.fits,1 # first extensionNote that all but simple expressions will need to be quoted because of the shell:
foo.fits,pha==1&&pi==2 # & tells shell to run in bkgd foo.fits,pha==1||pi==2 # similar problems with pipes foo.fits,circle(1,2,3) # parens are grabbed by shell
./configurenow works properly again, so saoconfig should not be used.
FunFlush(fun, "C");is now:
FunFlush(fun, "copy=remaining"); (or FunFlush(fun, "copy=remainder"); )This syntax extension allows FunFlush to support the copy of the extension associated with the reference handle, which allows one to copy any extension from an input file to an output file:
/* open a new input extension */ ifun = FunOpen(...); /* make this new extension the output reference extension */ FunInfoPut(ofun, FUN_IFUN, &ifun, 0); /* copy the current reference extension to output */ FunFlush(ofun, "copy=reference");
Index to the Funtools Help Pages