The batch menu
The batch menu provides a way of applying the same processing to a sequence of images. GRIP sets no particular limit to the number of images which may be processed (though a limit may be imposed by the system's standard file selection dialogue). The images are not displayed in most of these processes (except for the slide show), to save time, but a progress message is shown while the processing takes place. If the processing results in new saved images they are always given modified names, so the original files are not overwritten.
GRIP only loads one image into memory at a time so there is no limitation on the sequence due to memory size. For some operations GRIP does create in memory a 32-bit-per-channel accumulator image with the same width and height as the images being processed. The accumulator needs twice the amount of memory as a normal 16-bit image (for the 21-megapixel images from my Canon camera the accumulator occupies 254 Mbytes).
- collects metadata from the selected image files and puts them together to save as an XML file. As much information is included in the XML as GRIP can possibly find in each image, so the XML file is quite large. You may wish to process the XML further (eg, with some XSLT), to make a more convenient version containing only what you need.
- displays a series of images as a full-screen slide show. The following key-presses are active during the show. Left arrow reverses, to go backwards through the series of images. Right arrow goes forward. Up arrow speeds up by 2 (halving the interval). Down arrow slows down by 2. The space bar pauses and resumes the show. While paused, the left and right arrow keys can be used to step to the next or previous slide. Any other key ends the show and clears the window.
- takes a set of images assumed to be of stars on a dark background. It detects the stars in each image and analyses the patterns of the 24 brightest ones (the number 24 is modifiable). It determines where each of those stars is in each of the images and then distorts (warps) each image so that the stars are in the same position as in the middle image of the sequence. It adds the warped images together in a 32-bit-per-channel accumulator (32 bits ensures the added brightness levels do not hit a ceiling). The accumulator itself can be saved in a file, in a format that GRIP can reload again (but other applications would not recognise). The accumulator is read out into a normal 16-bit-per-channel image for saving in the widely used TIFF format. The read-out from the accumulator can either be simply by dividing by the number of images, so the warped images are averaged, or the user can use a curves dialogue to get the most contrast in the result. The second method should NOT be used if magnitudes are to be measured in the image but it is very useful for making a good photograph. The main aim in combining photos in this way is to reduce noise and improve contrast, as discussed elsewhere.
This star-image combination process is often referred to in these pages as the "batch astro-process" and more details can be found here: click for further details. - is quite similar to the previous option except that instead of accumulating the warped images they are each saved as a TIFF file (the orginal names modified to end with _warp.tif). The idea of this is to be able to analyse and measure stars in sets of photos taken over a long period, not a series taken in quick succession for noise reduction. More facilities will be added to GRIP for doing that analysis (not available yet, Jan 2010).
- first asks for a width and height. The selected images are then scaled to fit within those dimensions and resaved. The width/height proportions of the original images are preserved (pixels remain square) so one of either the resulting width or height may be less than the selected limits. The new files have the actual resulting size appended to their name. Eg, the scaled version of file xyz.tif might be saved as xyz_400x300.tif. NB: This operation can make images larger as well as smaller, if the selected width and height are both larger than that of the original image. Linear interpolation between pixels smooths the resulting image in such cases. This is not a good way of enlarging images, the process is really intended for scaling down.
- enables cropping to the same rectangular area on a series of images. The cropping area is set interactively on the first image, by using the mouse to define two opposite corners of the rectangle. The resaved image file names have _crop added.
- mirror reverses images from left to right and resaves them with _flh in their names.
- mirror reverses images from top to bottom and resaves them with _flv in their names. Doing a horizontal flip and a vertical flip (in either order) is a way of turning images through exactly 180 degrees, without any pixel interpolation.
- asks for a scale factor then scales all selected images by that factor and resaves them with _scl in their names.
- asks for an angle in degrees then rotates the images by that amount. Positive angles are measured anticlockwise. Pixel interpolation is done. The size of the resulting image is generally larger than the original image. The frame expands so that nothing is clipped off. Resaved image files have _rot in their names.
- asks for the horizontal half-angle of the camera field of view and then maps plane photographs onto a sphere so that they may be merged accurately with other photos. Resaved image files have _ignm in their names. Doing this as a batch operation assumes that the camera/lens configuration is the same for all the images. See full details.
- asks for the horizontal half-angle of the camera field of view and then maps photographs from sphere to plane, typically after merging. Resaved image files have _gnm in their names. Doing this as a batch operation assumes that the camera/lens configuration is the same for all the images. See full details.
- reverses black and white (for each channel), producing a negative. This is a true negative, without the orange cast that a colour film negative has. Resaved image files have _inv in their names.
- finds, for each image, the minimum and maximum value occurring in each channel, then does a linear stretch so that the minimum becomes level 0 and the maximum becomes the maximum possible for the number of bits available (255 for an 8-bit channel, 65535 for a 16-bit one). There is first a question asked: are all channels to be scaled the same? If the answer to this is "no", the stretching is calculated completely independently for each channel. That means that colour balance will not generally be preserved. On the other hand if the answer is "yes" the scaling is based on the global minima and maxima, of all channels, so colour balance is kept. Resaved image files have _stretch in their names.
- . For every pixel in each image the value of each channel is replaced by 37.5% of the red value + 50% of the green + 22.5% of the blue. All three channels then have the same value, so the pixel is displayed as a shade of grey. The percentages used here are rather arbitrary. Programmers can easily change them in class ImProcess. Resaved image files have _mono in their names.
- does what it says, for any images which have more than 8 bits per channel. The resulting files have _8bit in their names.
- first asks for another image to be selected and then subtracts this image from each of the others, pixel by pixel. Resaved image files have _sub in their names. An important use of this is for removing defective pixels. A dark image (an image taken with the camera lens completely covered) is subtracted. This can be useful for long exposures. The dark image is exposed for the same length of time as the real images. Defective pixels build up a value during this time, which they should not do if perfect. The astro-process (see below) can do subtract dark frames automatically, so it is not necessary to do it as a separate batch process first.
- first asks for another image to be selected and then multiplies each of the images by this one, pixel by pixel. If M is the maximum level which can occur in each channel of the target image and N is the maximum level in any channel of the other image being multiplied, the result for each pixel is scaled from M * N to M. Resaved image files have _mpy in their names.
- first asks for another image to be selected and then divides each of the images by this one. Resaved image files have _div in their names. The astro-process (see below) can divide by flat fields automatically, so it is not necessary to do it as a separate batch process first. More about the use of flat fields and how to make them is given here.
- is sometimes a useful way of increasing contrast. Saved result images have _squ in their file names.
- . For every channel, for every pixel, add the values in every image and then divide by the number of images. One saved image file is created. Its name is that of the first averaged image, with _ave inserted before the type extension. An important use of averaging is when all the images are successive shots of the same scene, to reduce the effects of camera noise, especially for long exposures. The camera/lens setting and the exposure time should be the same for all of the images being averaged and in astrophotography the camera should be guided so that the subject has not moved due to the earth's rotation. There are other uses for image averaging however, including to produce unusual effects for artistic purposes, in which case camera settings, etc, need not be constant.
- is very similar to the previous option except that when all the images have been added the user is presented with a histogram of the accumulator and a curves dialogue, enabling the 32-bit-per-channel accumulator to be read out through a look-up curve into a 16-bit image for saving. In this way contrast can be modified or enhanced with a greater dynamic range than can be achieved in a 16-bit image.
- . Details of the processing applied to each image in this case are here. Resaved image files have _bkgr in their names.
- will show a dialogue for the first image in the batch sequence, to enable a saturation level to be set by means of a slider. Dragging the slider to the left decreases colour saturation in the image until, at the left end of the scale, it becomes monochrome. Sliding to the right increases saturation until at the right end of the scale the image only contains fully saturated colours. The setting is then applied automatically to the remaining images in the sequence. Saved result images have _sat in their file names.
- works if you have a suitable javax.imagio plug-in that can read your camera's RAW format files. GRIP is supplied with jrawio, from Tidal Wave. That can handle many types of RAW file but may not be up to date for the latest formats. In this process the file extension for each image changes to .tif so no other name change is needed.
- . A dialogue enables a sequence of processes to be built which can then be applied to a set of image files. Each file will be opened, have the sequence applied to it, and then saved with a name including "_seq" so the original file is not overwritten.
- displays the present page if you have installed files as described here.

