Estimation of LV Deformation
This document describes the commands that implement the cardiac strain computation methodology described in Papademetris et al 2002. The Surface Editor is used to generate the initial Surfaces in ".sur" format.

Caveat: One of the prrocessing modules below (Step 5) requires the presence of the Abaqus Finite Element package and the local yale extensions for this. Unfortunately these are not available for download at this point.

Step 1: The Input Surfaces

Figure 1. Outline of the complete process. The numbers in parenthesis (e.g. Mesh Generation (4)) refer to the section Papademetris et al 2002 where this component is described, i.e. mesh generation is described in section 4

The output of the tracing process consists of endo and epi cardial surfaces sometimes named endo.01.sur ... endo.02.sur ... endo.16.sur and epi.01.sur etc. Alternatively the study name is used in which case the files called *N.01.sur are the endocardial surfaces and the files called *P.01.sur are the epi-cardial surfaces.

NEVER run the analysis in the same directory as the original files.

The first step is to determine the End-Diastole (ED) and the End-Systole(ES). We only run the analysis for these frames. In this case assume that ED is frame 2 and ES is frame 8. So long as ES ED things are ok. If not use the program pxabrenameframes to reorder the frames. (see step 2b)

Step 2: Creating Triangulated Surfaces

The input surface .sur are in a complex b-spline stack format, and they need to be sampled to triangulated surfaces before they can be used for the analysis. (This effectively is step 2 of figure 1).

MRI:

The command to do this is pxsur2tstack

pxsur2tstack is surface to tstack converter
  Usage : pxsur2tstack [ -IP 1.0 ] [-OP 1.0] [-CM 1] [-DM=0] [-PM] 
                [-BZ -1] [-TZ 10000.0 ] [-IT 0 ] [-SC 0 ] [-IV 0 ]filename1 filename2 ..
        IP = Inplane spacing, OP = Out-of-plane spacing
        PM=Polar Middle
        BZ=bottomz=-1 TZ=topz=10000.0, IT=Smoothing Iterations=0, SC=Curvature Scale=0
        CM=Mode (1=Linear,3=Cat-Spline) DM=draw mode(-1=polar 0=open,1=closedbottom etc.)
        IV=Save Inventor file also

Typically this would be run as

pxsur2tstack -IP 1.0 -OP 1.0 -IT 100 -SC 3 -IV 1 endo.*.sur epi*sur

Sometimes the -BZ and -TZ flags are needed to crop the surfaces to a certain z-coordinate range. In this case if we wanted to crop the surfaces between 9.0 and 15.0 we could type:

pxsur2tstack -IP 1.0 -OP 1.0 -IT 100 -SC 3 -IV 1 -BZ 9.0 -TZ 15.0 endo.*.sur epi*sur

The output flag -IV 1 also produces inventor movie files. These can be viewed using ivview

ivview endo.01.iv

Polar Ultrasound:

The command to do this is pxpolarsur2tstack

pxpolarsur2tstack is surface to tstack converter
  Usage : pxpolarsur2tstack [ -IP 1.0 ] [-OP 1.0] [-CM 1] [-DM=0] [-PM] 
                [-BZ -1] [-TZ 10000.0 ] [-IT 0 ] [-SC 0 ] [-IV 0 ]filename1 filename2 ..
        IP = Inplane spacing, OP = Out-of-plane spacing
        PM=Polar Middle
        BZ=bottomz=-1 TZ=topz=10000.0, IT=Smoothing Iterations=0, SC=Curvature Scale=0
        CM=Mode (1=Linear,3=Cat-Spline) DM=draw mode(-1=polar 0=open,1=closedbottom etc.)
        IV=Save Inventor file also

Typically this would be run as

pxpolarsur2tstack -IP 1.0 -OP 1.0 -IT 100 -SC 3 -IV 1 -BZ 80 -TZ 180 endo.*.sur epi*sur

Sometimes the -BZ and -TZ flags are needed to crop the surfaces to a certain z-coordinate range. In this case if we wanted to crop the surfaces between 90.0 and 175.0 we could type:

pxsur2tstack -IP 1.0 -OP 1.0 -IT 100 -SC 3 -IV 1 -BZ 90.0 -TZ 175.0 endo.*.sur epi*sur

The output flag -IV 1 also produces inventor movie files. These can be viewed using ivview

ivview endo.01.iv

Step 2b: Renaming the frames

If ED ES use the program pxabrenameframes to reorder the frames.

Usage: pxabrenameframes first last period newfirst endostem epistem

To go from ED = 10 and ES=2 with a total of 16 frames we can type (assume endo epi name convention)

Usage: pxabrenameframes 10 2 16 1 endo epi

Step 3: Running the Shape-Tracking Algorithm

This is the first real step in the analysis which generates the initial displacement estimates using the shape-tracking algorithm. This is done using pxabshapetracking. (This effectively is step 3 of figure 1.)

Usage : pxabshapetracking [-O outputstem] [ -F 1 ] [-L 16] [-LM 16] [-S 1]
         [-IN 1] [-IT 5 ] [-SM 5] [-SW 3] [-CS 0] [-LA 0.5 ] [-G 0 ] 
         inputname1 [inputname2] [inputname3] ... 

        1. Output Filename (same as input if not specified)
                O=name stem
        2. Temporal Extent of Study default 16 frames,
                F=FirstFrame, L=LastFrame LM=Last Periodic Frame=16
        3. Surface 2 Subdivision,
                S=Pixels
        4. Shape Tracking Parameters
                 IN - init mode, IT=init iterations SM=init smoothing iterations
                 SW - search window, CS=shape-tracking smooth iterations -LA smoothing weight
                 G  - Global Alignment
        5. Input filename: input name stem as is

To run the shape tracking algorithm for frames 2-8, endo and epi we type:

pxabshapetracking -F 2 -L 8  -SW 3 endo epi

Step 4: Generating the initial solid

To do this we need first two .tstack files with the same z-extent. First copy the ED surfaces i.e. in this case endo.02.sur and epi.02.sur to a new directory and look at the files to find their extent. If say endo.02.sur extends from 6.0 to 30.0 and epi.02.sur from 3.0 to 27.0 we have to use the common extent as:

pxsur2tstack -IP 1.0 -OP 1.0 -IT 100 -SC 3 -IV 1 -BZ 6.0 -TZ 30.0 endo.02.sur epi.03.sur

The solid can then be generated using the pxabcreatesolid command

pxabcreatesolid fname1 fname2 numstacks numnodes bias skipslices springs output

Typically we run this command as

pxabcreatesolid endo.02.tstack epi.02.tstack 4 35 1 2 0 solid.sld

A file called solid.iv will also be produced we can view this using ivview. (This effectively is step 4 of figure 1.)

Step 5: Running the Finite Element Process

This is initiated using the pxabcreatejobmulti command.

Usage: pxabcreatejobmulti solidname endostem epistem enfMode springstiffness
          beginframe endframe resout materialmode incompress [orient=0 ]
          [run=1] [jobname][framename]

In this case we would type

pxabcreatejobmulti solid/solid.sld endo epi 2 4.0 2 8 0 1 0.4 2 2 outputFibers

This will generate the output data sets (after an hour or two) in the fiber specific directions. These need to be rotated in the cardiac coordinate frame using:

pxabcreatejobmulti solid/solid.sld endo epi 2 4.0 2 8 0 1 0.4 1 -2 outputRad outputFibersT

This should not take too long. (1-3 minutes).

The final results can be viewed using pxivabaqusmovie. This requires no parameters. The study can be loaded (this is the .stat file) in this case the important files will be called outputRad.stat and outputFibers.stat. (This effectively is step 6 of figure 1.)

Step 6: Generating Average Strain Values (Pies) for analysis

This is done using pxmakepies.

usage pxmakepies studyname refpoint [numframes=12]
    [direction=1] [numslices=3] [numsectors=8] [numwedges=1] [ principal=0
    ] [outputname]

To do this we also need a file usually ending in .ref which defines the reference point. This file is one line long (any other lines are ignored) consisting of the (x,y,z) coordinates of the reference point.

Typical usage for our case:

pxmakepies outputRad output.ref 20 1 3 8 1 0 cardiacpies

The important parameters are which produce a division in 3 slices x 8 sectors x 1 transmural.

Additional Visualization Tools

You may use pxitclvolumeviewer to view the results. You will need the original images as a base. Further the image header has to have to correct information with respect to frames etc.

Bibliography

X. Papademetris, A. J. Sinusas, D. P. Dione, R. T. Constable, and J. S. Duncan.
Estimation of 3D left ventricular deformation from medical images using biomechanical models.
IEEE Trans. Med. Imag., 21(7), July 2002.


About this manual.