AIR File Types

The following types of files are utilized in the AIR package:

AIR 5.0 If compiled to allow detection of byte swapped data, AIR will automatically detect data that needs to be byte swapped and will perform byte swapping on-the-fly. This allows all of the AIR file types listed here to be used across platforms. Only computer platforms that use the IEEE Standard for Binary Floating-Point Arithmetic (ISO/IEEE Std 754-1985) will allow proper byte swapping. Initialization (.init), scaling initialization (.inits) and coordinate list (.ucf) files should be transferred across platforms in ASCII mode. All other file types should be transferred in binary mode.


Header (.hdr) files:

The AIR package utilizes separate header and image files. The header file contains all of the information necessary to interpret the data in the image file. At present, the default header format for the AIR package is compatible with the ANALYZE 7.5 format from the Biomedical Imaging Resource at the Mayo Clinic. All default header files must end with the suffix .hdr and a corresponding image file with the suffix .img is expected to exist. The image files contain pixel values without any associated header information. If you can get your data into raw format (i.e., data only, without any header information), the AIR package provides all of the utilities needed to create the corresponding header files.

The following pieces of information are stored in the header files and are used by the AIR package:

The units for the image voxel sizes are not specified in the AIR package (millimeters are recommended), and identical units must be used for all three dimensions.

If voxel sizes have to be rounded-off, the smallest voxel size should be rounded downwards and the other voxel sizes rounded upwards to assure that interpolation to cubic voxels will generate the correct number of planes.

The default header currently contains space to store additional information, but storage and maintenance of such information is not supported by the AIR package.

A C programmer can modify the air package to read and write other data file types, including files that combine header and image information into a single file, but this is a significant undertaking.

You can create a header file using makeaheader, review the information in a header file using scanheader, modify the header voxel sizes with fixheader, and adjust the header global maximum with setheadermax.

When creating a new header, you must provide all of the information that will be contained in the header. In order to properly specify the image matrix dimensions, the voxel dimensions, and the number of bits per pixel, you must know how data is represented in your image file. There are two major considerations:

  1. The x, y, and z dimensions must be defined according to how the data is ordered in the image file. Your image display package may define the dimensions differently.
  2. For 16 bit data, you must know what 16 bit variable type was used to store the data and what 16 bit numerical value is supposed to represent a "black" pixel.

Image (.img) files:

The AIR package utilizes separate header and image files. Image files end with the suffix '.img'. A single image file contains all of the data for the entire three dimensional volume stored row after row, plane after plane. The image file consists of "raw" voxel intensity values (8 bit and 16 bit images are supported) that are stored sequentially. No other information is contained in the .img file.

The image file's voxel order is defined as follows:

The file x-dimension
is defined as the dimension that changes most rapidly (i.e., each sequential voxel will fall in a different column and will therefore have a different x coordinate).
The file y-dimension
changes more slowly than the x-dimension and more quickly than the z-dimension.
The file z-dimension
is defined as the dimension that changes most slowly (e.g., all of the voxels for a given z-plane are stored before any of the voxels of the next z-plane).

Please note that your image display package may define the dimensions differently. In addition, note that the internal coordinate system used for indexing the voxels once they are loaded into the AIR package may differ substantially from the coordinate system used by your image display package.

Many programs in the AIR package will generate new image files.


Registration parameter .air files

Linear spatial transformations in AIR are stored in the form of .air files.

.air files are created and used by the AIR package and contain the following pieces of information:

The "reslice" file
the name of the image file to be spatially transformed by the .air file
Definition of a "standard" space
the matrix size and voxel dimensions that will result after transforming the reslice file.
A transformation matrix
a description, in linear algebraic terms, of the spatial transformation to be applied
Additional, nonessential information
information about how the .air file was generated.

The contents of a .air file can be display using scanair.

A number of programs in the AIR package will create or modify .air files.


Registration parameter .vector files AIR 5.0

Nonlinear spatial transformations represented by vector fields in AIR are stored in the form of .vector files.

.vector files can be used by the AIR package and contain the following pieces of information:

The "reslice" file
the name of the image file to be spatially transformed by the .vector file
Definition of a "standard" space
the matrix size and voxel dimensions that will result after transforming the reslice file.
A vector field
a vector of floats for every voxel in the standard file that describes the location of the corresponding voxel in the reslice file using voxel coordinates from the AIR internal coordinate system.
Additional, nonessential information
information about how the .vector file was generated.

The contents of a .vector file can be displayed using scan_vector

The current AIR distribution does not include programs to create or modify .vector files. Such files are supported as a potential bridge between AIR and other warping programs.


Registration parameter .warp files

Nonlinear spatial transformations in AIR are stored in the form of .warp files.

.warp files are created and used by the AIR package and contain the following pieces of information:

The "reslice" file
the name of the image file to be spatially transformed by the .air file
Definition of a "standard" space
the matrix size and voxel dimensions that will result after transforming the reslice file.
A set of transformation parameters.
a set of equations that describe the spatial transformation to be applied
Additional, nonessential information
information about how the .warp file was generated.

The contents of a .warp file can be displayed using scan_warp

A number of programs in the AIR package will create or modify .warp files.


Initialization (.init) files:

Initialization files are used to override the default center-of-file to center-of-file, no rotation or rescaling initialization used by the automated alignment programs. These are plain text ASCII files and their contents may vary for different automated alignment programs. For rigid-body, global rescaling, and traditional 9 parameter Talairach models, initialization files can be created by manualreslice. The format of initialization files for other models are described with each model.


Scaling Initialization (.inits) files:

Scaling initialization files are used to override the default scaling of 1.0 that is used by the automated alignment programs. These are plain text ASCII files with a single scaling parameter.


Coordinate list (.ucf) files: AIR 5.0

Two types of coordinate list files are supported:

  1. Raw coordinate lists
    These consist of x, y and z coordinates for each point. Coordinates must be expressed in the AIR internal coordinate system, but in real world units (usually millimeters), not voxels. Coordinates within a point should be separated by spaces and each point should appear on a new line. The file should be plain text ASCII format
  2. Formal UCLA Laboratory of Neuroimaging UCF files originally digitized by Tracer
    These are plain text ASCII files derived from UCF files that were originally digitized by a Java program called Tracer that is specifically designed to generate coordinates using millimeters in the AIR internal coordinate system. Formal UCF files derived from UCF's originally digitized by other programs should not be used unless it is known that the coordinate sytem used by the other programs is AIR compatible.

When AIR programs transform one .ucf format file into another, the type of the input coordinate list will determine the type of the output coordinate list.


Modified: December 24, 2001

© 1995-2001 Roger P. Woods, M.D.(rwoods@ucla.edu)