Wolfram Language & System 10.3 (2015)|Legacy Documentation

This is documentation for an earlier version of the Wolfram Language.View current documentation (Version 11.2)


applies the function f to the range r neighborhood of each pixel in each channel of the image stored in and stores the result in .

Details and OptionsDetails and Options

  • ImageFileFilter can be used to read, process, and write successive blocks of data from a very large image file whose size could exceed available memory.
  • ImageFileFilter[f,"inputfile",r] stores the result of an image file in the working directory where the output file name is the concatenation of and the result of DateString[].
  • ImageFileFilter works with TIFF, JPEG, and PNG files. The created always has the same file format, data type, and dimensions as the .
  • ImageFileFilter works on images with any number of channels.
  • ImageFileFilter[f,"inputfile",r] replaces the value of each pixel by the result of applying the function f to the × array of values around that pixel.
  • ImageFileFilter[f,"inputfile",{rrow,rcol}] uses range in the row direction, and in the column direction.
  • In ImageFileFilter[f,], the function f can return a number or a list of any length.
  • The channel values supplied to f are normally in the range 0 to 1, regardless of the underlying type used in the Image object. The function f is assumed to return channel values that are normally in the range 0 to 1.
  • ImageFileFilter operates separately on each channel in an image.
  • The following options can be given:
  • InterleavingTruewhether to supply f lists of channel values
    Padding"Fixed"what values to assume beyond the image
    MethodAutomaticmethod to use
  • The following suboptions can be given to Method:
  • "ImageList"Allframes to process from a multi-frame file
    "MaxBlockSize"8000000maximal size of image blocks in pixels loaded into the memory
  • With the default setting Interleaving->False, the elements in the arrays to which f is applied are individual channel values for the pixels.
  • For the most efficient file processing, stripes or tiles of the image may be accessed in a specific order.
  • The value of the option may be exceeded if it is smaller than the smallest block supported for the input file.
  • With , the output image only contains the processed frames.
  • Padding->None is not supported by ImageFileFilter.

ExamplesExamplesopen allclose all

Basic Examples  (2)Basic Examples  (2)

Out-of-core processing of an image:

Click for copyable input

Import the resulting image:

Click for copyable input

Specify the output file name:

Click for copyable input
Introduced in 2012
| Updated in 2015