Using Workbench Command

Workbench Command is a set of command-line tools that can be used to perform simple and complex operations within Connectome Workbench.

Full Documentation:

Documentation Home
RESAMPLE A CIFTI FILE TO A NEW CIFTI SPACE
   wb_command -cifti-resample
      <cifti-in> - the cifti file to resample
      <direction> - the direction of the input that should be resampled, ROW or
         COLUMN
      <cifti-template> - a cifti file containing the cifti space to resample to
      <template-direction> - the direction of the template to use as the
         resampling space, ROW or COLUMN
      <surface-method> - specify a surface resampling method
      <volume-method> - specify a volume interpolation method
      <cifti-out> - output - the output cifti file

      [-smooth-edges] - smooth the probability maps before the popularity step,
         to reduce jaggedness at the cost of fidelity
         <kernel-size> - the smoothing amount to use, gaussian sigma in mm

         [-fwhm] - use specified kernel size as full width at half maximum,
            rather than sigma

      [-surface-largest] - use largest weight instead of weighted average or
         popularity when doing surface resampling

      [-volume-predilate] - dilate the volume components before resampling
         <dilate-mm> - distance, in mm, to dilate

         [-nearest] - use nearest value dilation

         [-weighted] - use weighted dilation (default)

            [-exponent] - specify exponent in weighting function
               <exponent> - exponent 'n' to use in (1 / (distance ^ n)) as the
                  weighting function (default 7)

            [-legacy-cutoff] - use v1.3.2 logic for the kernel cutoff

      [-surface-postdilate] - dilate the surface components after resampling
         <dilate-mm> - distance, in mm, to dilate

         [-nearest] - use nearest value dilation

         [-linear] - use linear dilation

         [-weighted] - use weighted dilation (default for non-label data)

            [-exponent] - specify exponent in weighting function
               <exponent> - exponent 'n' to use in (area / (distance ^ n)) as
                  the weighting function (default 6)

            [-legacy-cutoff] - use v1.3.2 logic for the kernel cutoff

      [-left-spheres] - specify spheres for left surface resampling
         <current-sphere> - a sphere with the same mesh as the current left
            surface
         <new-sphere> - a sphere with the new left mesh that is in register
            with the current sphere

         [-left-area-surfs] - specify left surfaces to do vertex area
            correction based on
            <current-area> - a relevant left anatomical surface with current
               mesh
            <new-area> - a relevant left anatomical surface with new mesh

         [-left-area-metrics] - specify left vertex area metrics to do area
            correction based on
            <current-area> - a metric file with vertex areas for the current
               mesh
            <new-area> - a metric file with vertex areas for the new mesh

      [-right-spheres] - specify spheres for right surface resampling
         <current-sphere> - a sphere with the same mesh as the current right
            surface
         <new-sphere> - a sphere with the new right mesh that is in register
            with the current sphere

         [-right-area-surfs] - specify right surfaces to do vertex area
            correction based on
            <current-area> - a relevant right anatomical surface with current
               mesh
            <new-area> - a relevant right anatomical surface with new mesh

         [-right-area-metrics] - specify right vertex area metrics to do area
            correction based on
            <current-area> - a metric file with vertex areas for the current
               mesh
            <new-area> - a metric file with vertex areas for the new mesh

      [-cerebellum-spheres] - specify spheres for cerebellum surface resampling
         <current-sphere> - a sphere with the same mesh as the current
            cerebellum surface
         <new-sphere> - a sphere with the new cerebellum mesh that is in
            register with the current sphere

         [-cerebellum-area-surfs] - specify cerebellum surfaces to do vertex
            area correction based on
            <current-area> - a relevant cerebellum anatomical surface with
               current mesh
            <new-area> - a relevant cerebellum anatomical surface with new mesh

         [-cerebellum-area-metrics] - specify cerebellum vertex area metrics to
            do area correction based on
            <current-area> - a metric file with vertex areas for the current
               mesh
            <new-area> - a metric file with vertex areas for the new mesh

      [-affine] - repeatable - add an affine transformation for the volume
         components
         <affine-file> - the affine file to use

         [-flirt] - MUST be used if affine is a flirt affine
            <source-volume> - the source volume used when generating the affine
            <target-volume> - the target volume used when generating the affine

      [-affine-series] - repeatable - add an independent affine per-map for the
         volume components
         <affine-series> - text file containing 12 or 16 numbers per line, each
            being a row-major flattened affine

         [-flirt] - MUST be used if the affines are flirt affines
            <source-volume> - the source volume used when generating the affine
            <target-volume> - the target volume used when generating the affine

      [-warpfield] - repeatable - add a warpfield for the volume components
         <warpfield> - the warpfield to use

         [-fnirt] - MUST be used if using a fnirt warpfield
            <source-volume> - the source volume used when generating the
               warpfield

      Resample cifti data to a different brainordinate space.  Use COLUMN for
      the direction to resample dscalar, dlabel, or dtseries.  Resampling both
      dimensions of a dconn requires running this command twice, once with
      COLUMN and once with ROW.  If you are resampling a dconn and your machine
      has a large amount of memory, you might consider using
      -cifti-resample-dconn-memory to avoid writing and rereading an
      intermediate file.  The <template-direction> argument should usually be
      COLUMN, as dtseries, dscalar, and dlabel all have brainordinates on that
      direction.  If spheres are not specified for a surface structure which
      exists in the cifti files, its data is copied without resampling or
      dilation.  Dilation is done with the 'weighted' method by default (except
      for label data on the surface - volume label data uses weighted
      popularity logic by default), and is done on <new-sphere> for surface
      data.  Volume components are padded before dilation so that dilation
      doesn't run into the edge of the component bounding box.  If neither
      -affine nor -warpfield are specified, the identity transform is assumed
      for the volume data.

      The recommended resampling methods are ADAP_BARY_AREA and CUBIC (cubic
      spline), except for label data which should use ADAP_BARY_AREA and LABEL.
      Using ADAP_BARY_AREA requires specifying an area option to each used
      -*-spheres option.

      The <volume-method> argument must be one of the following:

      CUBIC
      ENCLOSING_VOXEL
      TRILINEAR
      LABEL

      The <surface-method> argument must be one of the following:

      ADAP_BARY_AREA
      BARYCENTRIC