Last modified: December 2022

AHELP for CIAO 4.16


Context: Tools::Image


Replicates table value along axis of image


dmimgreproject  infile imgfile outfile [method] [clobber] [verbose]


`dmimgreproject' takes an input image and a table with two columns. The first column in the table must match the name of either of the axes of the input image (usually "x" or "y"). The coordinates along this image axis are interpolated with the chosen method to match the data in the table.


Example 1

dmimgreproject infile="table.fits[cols x,sum]" imgfile=img.fits
outfile=out.fits method=weight

Since the input file table.fits has an "X" column, the X-coordinates in the image are used to lookup values in the table. For each X value, the SUM (2nd) column is looked up. A linear interpolation/extrapolation (weight) is used to find the values. The SUM value that is found in the table is replicated for all Y values in the output image.

Example 2

dmimgreproject infile="table.fits[cols y=delta,mean]" imgfile=img.fits
outfile=out.fits method=closest

Using the DM filtering syntax we have renamed the 'delta' column 'y'. So similar to above, the 'y' values are now polled from the input image, the corresponding values looked-up in the table, this time the value closest to the requested Y position is used, and then that value is replicated for all X values in the output image.


name type ftype def min max reqd
infile file input       yes
imgfile file input       yes
outfile file output       yes
method string   weight      
clobber boolean   no      
verbose integer   0 0 5  

Detailed Parameter Descriptions

Parameter=infile (file required filetype=input)

The input table

The input table must have 2 columns. A DM filter should be used to select desired columns, if necessary. The table should be sorted such that the first column is increasing (use dmsort to pre-sort file if necessary).

Parameter=imgfile (file required filetype=input)

The input image

The image used to a) get the coordinates to lookup in the table and b) determines the output image size.

Parameter=outfile (file required filetype=output)

The output file name

The output image which will match the input image w/ data along one axis repliated from input table

Parameter=method (string default=weight)

Interpolation method

There are several interpolation methods available

Parameter=clobber (boolean default=no)

Remove output if it exists?

Used to specify whether or not to clobber existing file that has the same name as the specified output file

Parameter=verbose (integer default=0 min=0 max=5)

The tool chatter level

Verbose can be from 0 to 5, generating different amounts of debugging output.


There are no known bugs for this tool.

See Also

centroid_map, dmfilth, dmimg2jpg, dmimgadapt, dmimgblob, dmimgcalc, dmimgdist, dmimgfilt, dmimghist, dmimgpick, dmimgpm, dmimgproject, dmimgthresh, dmmaskbin, dmmaskfill, dmnautilus, dmradar, dmregrid, dmregrid2, energy_hue_map, evalpos, hexgrid, map2reg, merge_too_small, mkregmap, pathfinder, vtbin
dmcontour, dmellipse, dmimghull, dmimglasso
mean_energy_map, pileup_map
dmstat, imgmoment, statmap