Navigation(children) Index TableOfContents

Name

mri_convert - converts MRI data format/file type

Synopsis

mri_convert [<options>] involume outvolume

Arguments

Positional Arguments

involume

input volume

outvolume

output volume

Required Flagged Arguments

None

Optional Flagged Arguments

-ro, --read_only

-nw, --no_write

-ii, --in_info

-oi, --out_info

-is, --in_stats

-os, --out_stats

-im, --in_matrix

-om, --out_matrix

-iis, --in_i_size <size>

-ijs, --in_j_size <size>

-iks, --in_k_size <size>

--force_ras_good

use default when orientation info absent

-iid, --in_i_direction <R direction> <A direction> <S direction>

-ijd, --in_j_direction <R direction> <A direction> <S direction>

-ikd, --in_k_direction <R direction> <A direction> <S direction>

-ic, --in_center <R coordinate> <A coordinate> <S coordinate>

-oni, -oic, --out_i_count <count>

-onj, -ojc, --out_j_count <count>

-onk, -okc, --out_k_count <count>

-ois, --out_i_size <size>

-ojs, --out_j_size <size>

-oks, --out_k_size <size>

--nskip n : skip the first n frames

-oid, --out_i_direction <R direction> <A direction> <S direction>

-ojd, --out_j_direction <R direction> <A direction> <S direction>

-okd, --out_k_direction <R direction> <A direction> <S direction>

-oc, --out_center <R coordinate> <A coordinate> <S coordinate>

-odt, --out_data_type <uchar|short|int|float>

-rt, --resample_type <interpolate|weighted|nearest|sinc|cubic> (default is interpolate)

--no_scale flag <-ns>: 1 = dont rescale values for COR

-nc --nochange - don't change type of input to that of template

-tr TR : TR in seconds

--unwarp_gradient_nonlinearity

Expected "=" to follow "sonata"

<fullUnwarp | through-plane> <JacobianCorrection | noJacobianCorrection> <linear | sinc> <sincInterpHW>

Outputs

outvolume

output volume

Description

mri_convert is a general purpose utility for convertin between different file formats. The file type can be specified in two ways. First, mri_convert will try to figure it out on its own from the format of the file name (eg, files thatend in .img are assumed to be in spm analyze format). Second, the user canexplicity set the type of file using --in_type and/or --out_type. Legal values for --in_type (-it) and --out_type (-ot) are:

Examples

Example 1

APPLYING TRANSFORMS (INCLUDING TALAIRACH)

Example 2

CONVERTING TO SPM-ANALYZE FORMAT

Converting to SPM-Analyze format can be done in two ways, depeding uponwhether a single frame or multiple frames are desired. For a single frame,simply specify the output file name with a .img extension, and mri_convert will save the first frame into the file. For multiple frames, specify the base as the output file name and add --out_type spm. This will save each frame as baseXXX.img where XXX is the three-digit, zero-padded frame number. Frame numbers begin at one. By default, the width the of zero padding is 3.This can be controlled with --in_nspmzeropad N where N is the new width.

Bugs

None

Other Available Options

-r, --reorder olddim1 olddim2 olddim3

Notes:

If the user specifies any of the direction cosines, the ras_good_flag is set.

See Also

["mris_convert"]

Links

FreeSurfer, FsFast

Methods Description

description
description

References

Reporting Bugs

Report bugs to <analysis-bugs@nmr.mgh.harvard.edu>

Author/s

YasunariTosa, DougGreve, BruceFischl