Proceedings of the 29th Annual International Conference of the IEEE EMBS Cité Internationale, Lyon, France August 23-26, 2007

.

FrA07.1

A Semi-Automatic Feature Detection Algorithm for Hemodynamic Signals using Curvature-Based Feature Extraction
Jonathan P. Mynard, Member, IEEE, Daniel J. Penny, and Joseph J. Smolich

Abstract—Specific features of hemodynamic signals are invaluable for elucidating ventricular and vascular function. A semi-automatic algorithm is presented that enables accurate detection of any feature in any hemodynamic signal, using feature extraction from local maxima and minima in signal curvature. A particular feature is selected manually in the first beat and then detected automatically in subsequent beats.

I. INTRODUCTION NALYSIS of features within hemodynamic signals has become an increasingly important tool in cardiovascular research. Recent advances in time-domain analysis have revealed that detailed evaluation of ventricular or aortic pressure and flow signals, for example, provides a great deal of information about heart function and ventricular-vascular coupling [1-3]. Other derived signals, such as wave intensity [2], require measurements on forward-running and reflected waves, with accurate detection of the start, peak and end of these waves. In general, a ‘feature’ of a hemodynamic signal may refer to a local maximum or minimum, or to a localized bend or ‘corner’ in the signal. Detection of such features can be performed manually by positioning vertical cursors in a graphical user interface (GUI). This method is time consuming, however, since in any given study there may be many features of interest in several signals, and these must be detected in many beats. Another option is to design fully automatic algorithms to detect specific features. The drawback of this approach is that a given feature may appear under certain physiological conditions but not others. In dose response-type studies, for example, features may gradually appear or disappear and thus vary greatly in relative size [4]. Designing unique and robust automatic algorithms for every type of feature of interest is thus quite impractical. The aim of this study was to develop a versatile semiautomatic algorithm where automatic feature extraction is used in conjunction with manual detection of specific
Manuscript accepted June 6, 2007. This work was supported in part by funds from the Australia and New Zealand Children’s Heart Research Centre. J. P. Mynard is with the Heart Research Group, Murdoch Children’s Research Institute, Melbourne, Australia (phone: 61 3 9345 5922; fax: 61 3 9345 4220; e-mail: jonathan.mynard@mcri.edu.au). D. J. Penny, is with the Heart Research Group, Murdoch Children’s Research Institute, Melbourne, Australia (e-mail: dan.penny@rch.org.au) J. J. Smolich is with the Heart Research Group, Murdoch Children’s Research Institute, Melbourne,Australia(e-mail: joe.smolich@mcri.edu.au).

A

features in hemodynamic signals. The benefits of this approach are threefold: 1) a single semi-automatic algorithm can be applied to any feature of any signal; 2) although in part manually driven, this algorithm vastly reduces analysis time; 3) the precise location of features that may be difficult to identify visually can be determined objectively. The algorithm presented in this manuscript employed signal curvature to extract features. Curvature is traditionally used in image-processing to locate corners in an image. It has also been used for feature extraction in time signals such as the electrocardiogram (ECG) [5], but has not previously been applied to hemodynamic signals. II. METHODS AND MATERIALS A. Semi-automatic Algorithm The components of the semi-automatic algorithm, which are displayed in the flow diagram of Fig. 1, are as follows. 1) For the signal being analyzed, a set of features is automatically extracted (see section B) and the time and type (i.e. curvature maximum or minimum) of each feature is stored. The types of features extracted and the sensitivity of the detection can be set or adjusted by the user. 2) Using a custom-designed GUI, the user is presented with a vertical cursor which can be positioned manually. Left- and right-arrow buttons are then used to snap the cursor to the nearest feature or to scroll through the features. Once the desired feature has been identified, the user clicks a ‘Next’ button. 3) The code then estimates the location of the defined feature in the next beat using a two-step process. a) An initial estimate is obtained in one of two ways. If beat onsets have previously been detected, the time of the feature in the next beat is estimated to occur at the same isochrone (relative to beat onset) as the feature in the previous beat. Alternatively, if beat onsets are not known, the next feature is estimated to occur one heart period after the initial feature. Heart period is calculated from the fundamental frequency of the signal, found by performing a Fast Fourier Transform (FFT) of the whole channel and detecting the first significant spectral peak above the respiratory frequency range. However, if several feature detections have already been confirmed, the heart period can also be estimated from the average period between previous detections. b) From this initial estimate, the nearest feature of the correct type is found. If the time between the nearest feature and the initial estimate is greater

1-4244-0788-5/07/$20.00 ©2007 IEEE

1691

an axis transformation was performed from t to a variable x.002. Incorporating (3) and (2) into (1) gives the final equation which was used to generate the curvature signals: Implementation of this equation directly on sampled data results in large spurious curvature peaks associated with small high-frequency fluctuations in the signal (see Fig.e. on average ∆y ≈ ∆x or ∆y/∆x ≈ tan(45°). For a function y = f(t). Flow diagram of the semi-automatic algorithm for feature detection. 2c). but result in an unacceptable loss of accuracy. the features are displayed with one vertical cursor for each beat. the user is prompted to manually position the cursor for this beat and the next.1% of the maximum ∆y (this avoids including data segments that are effectively flat-line in the calculation). Calculation of curvature for a) left-ventricular pressure using b) ∆x = ∆t = 0.Extract Features (store timing and types) User selects a feature (‘snap-to’ GUI) Automatic detection of next feature succeeded Automatically find feature in next beat Automatic detection of next feature failed or <2 beats confirmed End of data reached User views/edits/confirms detected features Fig. curvature is defined [6] as d2y 2 the median of all ∆y’s that are greater than 0. the peaks accurately identify the timing of features and the magnitudes of these peaks are greater for more significant features (see Fig. This was achieved by adjusting the amplitudes of curvature peaks based on the premise that the significance of a given curvature peak is high if the time between it and the next or Here ∆t is the sample time and ∆x is a value that results in an x-axis that is approximately orthogonal to the y-axis. than a set limit. the detection is deemed to have failed. where 2 κ ( ti ) = ∆x 2 m =− n ∑ a2 y i + m 3 n m (4) 2 dy dx = dy ∆t dt ∆x and d y dx 2 2 = d y ∆t dt 2 2 2 2 2   1 n m   1+ ∑ a1 yi + m           ∆x m =− n ∆x (2) A final step in the feature extraction was included to further emphasize significant features and attenuate insignificant features without losing accuracy. B. The user can then confirm the detections visually and make adjustments manually if needed. the k-th time derivative is given by d yi dt k κ (t ) = (1 + ( dy dt ) 2 ) 3 (1) 2 dt m k = k! ∆t k m =− n ∑ a k yi + m n m (3) where n = 2 and ak refers to the m-th coefficient for the k-th derivative. i. Otherwise. If a detection failure occurs (e. Fig. due to an ectopic beat or the absence of that feature). To generate a curvature signal that is less sensitive to small fluctuations. Feature Extraction A feature is defined as the time of a local maximum or minimum in signal curvature (κ). The derivatives were calculated using the standard Savitzky-Golay filter method [7] by using fitting coefficients of 4th order polynomials on 5 points. step 3 is repeated automatically as long as the defined feature is successfully located in subsequent beats. 2d shows that larger values of ∆x emphasize significant features further. Fig. 1. 4) After detection in all beats is complete. In the resulting curvature signal. c) ∆x from the method described and d) a ∆x 50 times greater. where ∆y is the change in the signal over one sample. 2.g. where for the i-th data point. 2b). ∆x is thus calculated as 1692 .

3d) are then used to detect features of the hemodynamic signal (see Fig. Each peak p (with initial curvature amplitude κ p ) was then scaled according to: Fig. κ′p = κ p ( ∆t max ∆t ∆x ) 2 2 + ∆ymax (5) where κ′p is the adjusted peak amplitude and ∆tmax is either tp − tp-1 or tp+1 − tp. in the 1693 . The semiautomatic algorithm was implemented in Spike2 software (v5. C. Both figures show that the feature extraction has accurately identified the times of local maxima.16. 3.Fig. 4a and 5a). Feature extraction in an aortic pressure signal (a). Thus. 3. As in Fig. 3a). A significance threshold is set by the user to control which features will be included in the semi-automatic algorithm. In the lower plots (Figs. Materials The experimental preparation was similar to that previously described [8. minima and other ‘corners’. 3c. Continuous curvature (b) is calculated with extraction of peaks (c) followed by adjustment according to the significance of each peak (d). 4 and 5. 4. where these refer to the values of the hemodynamic signal at the times of the feature peaks. Feature detection in an aortic flow signal.g. The data was sampled at 500 or 1000 Hz and low-pass filtered at 45Hz to remove high frequency noise. 9]. 5. While local maxima and minima in a hemodynamic signal can be easily detected without using curvature. UK). Fig. the feature peaks have been magnified. RESULTS AND DISCUSSION Examples of feature detection are shown in Figs. Such corners are often encountered at the start or end of a wave (e. Feature detection in a time-corrected aortic wave intensity signal. All studies were approved by the institutional Animal Experimentation Ethics Committee and conformed to guidelines of the National Health and Medical Council of Australia. Cambridge. Similarly ∆ymax is either |yp-1| − |yp| or |yp+1| − |yp| (but limited to 10% of the whole signal magnitude). the most significant features are indicated on the signal itself (Figs. The adjusted peaks (shown in Fig. whichever is greater. the curvature peaks were first extracted as in Fig. 4b and 5b). III. which contains a script language for performing customized analysis and design of GUI’s. corners that are not local maxima or minima are more difficult. Cambridge Electronic Design. previous peak is great or the difference in the value of the hemodynamic signal between adjacent feature peaks is great.

pp." J Physiol (Lond). Vetterling. H. the feature was then detected automatically in all subsequent beats. pp. "Wave intensity in the ascending aorta: effects of arterial occlusion. and D. the feature was chosen by the user via the ‘snap-to’ GUI. W. The user selected a different feature each time in the first beat. B. Wilkinson. further research would be required to compare it with other algorithms and to investigate specific clinical applications. "Increased aortic blood pressure contributes to potentiated dobutamine inotropic responses after systemic NO synthase inhibition in sheep. P. 647-55. C. H. Hupperetz. which allows manual detection of any feature in the first beat of a hemodynamic signal. first wave and immediately following smaller negative wave of Fig. It is important to stress that the method described is not intended for noisy data or signals with highly variable heart rates. J. Press. R. and also more gentle corners that are particularly difficult to detect precisely with manual techniques. S. vol. 2001. A. S. Cockcroft." Journal of Biomechanics. with accurate detection of the same feature in subsequent beats. 443. and J. H. 875-878. Fuller.. vol." Cardiovascular Research. W.Fig. 102. 6. REFERENCES [1] J. 1652-1659. R. and R. 1973. Sandor. van Thoor. Flannery. MacCallum. L. vol. followed by automatic detection of this feature in subsequent beats. In the first beat the user-selected feature was a small local minimum. 2nd ed. Smolich. Chen. Lux. pp. Sequential application of the semi-automatic algorithm to four different features in the first beat. MacLeod. 601-608.g. D.and T-waves respectively in the ECG [5]. 1989. C22. J. 2005. O'Rourke. IV. L. Penny and J. P. Johnston. This feature was then detected automatically in the next beat. G." American Journal of Physiology Heart & Circulatory Physiology. 284. After user confirmation in the following beat. Avolio. V. vol. vol." Pflügers Archiv European Journal of Physiology. Rosenfeld and E. Penny. 2002. O'Brien. M." IEEE Transactions on Computers. J. 7. and B. 38. Cambridge. R. J. Khir and K. vol. 40. and confirmed by the user without needing adjustment. Shrive. J. 7 the semi-automatic algorithm was applied 4 times to the same signal. A. has the potential for wide applicability in time-domain analysis of hemodynamics. 6 shows detection of a feature with changing morphology using the semi-automatic algorithm. Fig. Kelly. I. pp. and J. "Noninvasive determination of age-related changes in the human arterial pulse. 80. The feature was then detected automatically in remaining beats without user input. C. "Time-domain representation of ventricular-arterial coupling as a windkessel and wave system." Circulation. In the first beat. on the downward limb of the aortic flow signal in Fig. pp. K. The semi-automatic algorithm applied to changing signal morphology. G. "Divergent effects of NO synthase inhibition on systemic and myocardial O2 delivery and consumption during dobutamine infusion in sheep. H. J. Numerical Recipes in C++: The Art of Scientific Computing. T. pp. This accords with the advantage of using a curvature approach to detect the start and end of the Q. P. A. J. R. W. "Angle detection on digital curves. A. Tyberg. pp. Parker. semi-automatic algorithm enabling extraction of features in hemodynamic signals via local maxima and minima in signal curvature has been presented. 530. Green. vol. A. 2003. 2002. B. The algorithm reliably detected this feature in all beats even though it started as a local minimum and changed into a localized bend in later beats. D. 5) or as inflection points (e. C. Wang. The use of curvature thus enables accurate detection of local maxima and minima. B. 541-550. This algorithm. vol. Punske. Parker. and M. 1998. N. Smolich. Hayward. J." Circulation. Ershler. S. [2] [3] [4] [5] [6] [7] [8] [9] 1694 . In Fig. H. 282-9. B. H1358-H1368. CONCLUSION A versatile. pp. 2000. 685-91. and these were all detected successfully and automatically in the following beats. While we have demonstrated that the algorithm is robust and useful for a wide range of applications. "Changes in the derived central pressure waveform and pulse pressure in response to angiotensin II and noradrenaline in man. Webb. 4). S. Fig. UK: Cambridge University Press. Teukolsky. Taccardi. as additional adjustments to the algorithm would be required for such signals. "Estimates of repolarization dispersion from electrocardiographic measurements.