Online Speckle Tracking in Ultrasound Images for Prosthetic Hand Control
Ultrasound Image generation
Ultrasound imaging provides a non-invasive and cost effective way to obtain internal images for medical applications and diagnosis of human health. Image generation from ultrasound waves consists of three steps- production of sound waves by piezoelectric transducer, receiving echoes, and formation of image. Strong, short electrical pulses from ultrasound machine make the transducer ring at a desired frequency, which can be anywhere between 2-18 MHz. Then, focussing of sound is done by either the shape of the transducer, lens in front of transducer or a complex set of control pulses from ultrasound machine (also called beamforming), which produces the arc-shaped sound wave from the face of the transducer. Wave enters the body and focuses at a desired depth. The partially reflected sound waves vibrate the transducer; transducer then turns the vibrations into electrical pulses that travel to ultrasound machine where they are processed and transformed into digital image. The ultrasound scanner first determines how long it takes the echo to be received from when the sound is transmitted and then how strong the echo is. Sound wave is not a click, but a pulse of specific carrier frequency. Moving objects change this frequency on reflection, so that it is only a matter of electronics to have simultaneous Doppler sonography. Once the ultrasound
scanner determines these three things, it can locate which pixel in the image to light up and to what intensity, and at what hue if frequency is processed.
Why Ultrasound for prosthetic control?
When the limbs become injured or amputated, the body’s biological signals remain intact to various degrees (Stegman, Djurickovic, & Dechev). Researchers have procured and utilised these biological signals in various ways in order to control prosthetic limb devices. However, many electric prosthesis techniques such as those controlled by surface electromyography
(EMG) signals have a limited functionality in procuring independent signals due to sensor crosstalk and spatial resolution (Stegman, Djurickovic, & Dechev). Hence such conventional electric hand prosthesis have limited motorized degrees of freedom. A new and better nonelectric method to collect bio-signals from an injured person or amputee is to measure the tendon displacement, proximal to the wrist, from the ultrasound image sequences of the FDS tendon in wrist area (Stegman, Djurickovic, & Dechev). “Tendon motion measurement presents a solution to measure a person’s intention/desire to move the fingers in their hands, since the tendons are attached to individual interphalangeal and metacarpophalangeal joints in the fingers. Thus, measurement of displacements of multiple tendons in ultrasound images gives us multiple independent signals to control multi-degree-of-freedom hand prostheses (Stegman, Djurickovic, & Dechev).” Also, compared to other imaging modalities, ultrasound is cost-efficient, safer and very portable to use.
B-Scan Ultrasound Imaging and Speckle Tracking
B-Scan ultrasound images are produced as two dimensional, cross sectional view of internal body organs. The reflected soundwave, in generation of B-Scan ultrasound images, undergoes constructive and destructive interference and speckled texture is obtained on the images which contains information about the substructure of the underlying tissue (Stegman, Djurickovic, & Dechev). Although speckle is often considered as an artifact or noise in
conventional ultrasound imaging, it provides a signature for precise motion tracking. The acoustic scatterers producing speckle patterns displace with the moving tissue, and hence lead to moving speckle patterns that can be tracked. This property has already been exploited to estimate motion in a wide range of applications including echocardiography and elasticity imaging (Jacob, Lehnert-LeHouillier, Bora, McAleavey, Dalecki, & McDonough, 2008).
“Ultrasonic speckle tracking employs the use of block matching techniques where an area of a template image (kernel) is compared to subsequent images by the use of a similarity measure. Examples of similarity measures include the sum of absolute differences (SAD) and Bayesian technique like Rayleigh (or Fisher-Tippett). The success of speckle tracking is however highly dependent on parameters such as the ultrasound system’s frame rate, the frequency of the transducer, the similarity measure chosen, the tissue velocity, and the template (kernel) size and search region, etc (Stegman, Djurickovic, & Dechev).”
The program’s block diagram and front panel, shown in Figure 3, tracks the tendon motion through image sequences, and computes and displays the delta x and delta z displacements (in each coordinate) of tendon for all consecutive image frame sequences. This program translates existing Matlab tendon tracking code into a LabView platform for implementation on FPGA. This program makes use of Functions from NI LabVIEW Vision Development Module such as ‘IMAQ AVI Open’, ‘IMAQ AVI Read Frame’, ‘IMAQ Create’ and ‘IMAQ Dispose’ and ‘IMAQ Image to Array’ functions for opening and reading frames from the video recording, creating temporary memory location for each image frame and destroying the image after it has been analysed in order to free the occupied space for the next image to be read and analysed, and extracting the pixel values related to ‘template’ and ‘tempboxes’ from the image sequences into 2D arrays which are then compared for matching. In each while loop iteration, two consecutive frames are read and template-tempbox matching is performed. This process is repeated for all frames sequentially. The program uses SAD (Sum of Absolute Differences) method as similarity measure for matching tempbox with template where firstly every tempbox array in ROI in 2nd frame of each loop’s iteration is subtracted from the template in 1st frame of same loop’s iteration, then sum of absolutes of the pixel values from the subtraction result for each tempbox is computed (each resulting value is the SAD value for each tempbox and is collected, using auto-indexing, into array named ‘SAD’) and then the tempbox with the minimum ‘SAD’ value is computed (using ‘Array Max and Min’ function) in each frames’
comparisons, which is basically the best matched tempbox for the corresponding template in earlier frame. The coordinates of the matched tempbox with minimum SAD value are obtained as well using ‘Array Max and Min’ function in every loop iteration and compared with the coordinates of template to acquire delta x and delta z displacements of tendon through all consecutive frame comparisons. This information is then saved into Excel as a
.csv file using ‘Write to Spreadsheet File.vi’.
Right Portion of Block Diagram
Left Portion of Block Diagram
Right portion of Front Panel
Left Portion of Front Panel
Tendon Displacements (delta x and delta z) among Frames ranging from 150th to 160th:
Thank you for interest in the blog. Please leave comments, feedback and suggestions if you feel any.
Full code on my GitHub repo here.