91643 v00 Digest Mar09 EquuSys FINAL
Transcript of 91643 v00 Digest Mar09 EquuSys FINAL
-
7/30/2019 91643 v00 Digest Mar09 EquuSys FINAL
1/4
1 MATLAB Digest www.mathworks.com
At EquuSys, we used MALAB to develop
an easy-to-use, noninvasive system that en-ables equine proessionals to identiy and
diagnose lameness that would otherwise be
undetectable, even or the well-trained eye.
EquuSense technology sits at the conjunc-
tion o several dierent disciplines, includ-
ing telemetry, biomechanics, and veterinary
medicine. Despite the complex, multidis-
ciplinary challenge, a small team o devel-
opers with little MALAB experience was
able to move rapidly rom the initial idea to
a production system. Te EquuSense system
(Figure 1) provides real-time quantitative
data on horses trotting in-hand, being rid-
den on the at, or jumping. Its 18 wireless
sensor nodes measure position, velocity, ac-
celeration, orientation and rotation, relative
to the horse or a global rame o reerence,
to an accuracy o a ew millimeters or a
ew degrees. EquuSense soware processes
this telemetry data to provide objectivedata on equine biomechanics in the orm o
charts, 3-D plots, and animation.
Developing Algorithms
o provide meaningul inormation on
equine biomechanics, we must translate and
aggregate raw data obtained rom localized
sensors on the horses body to produce a six-
degrees-o-reedom representation o the
horses motion. Te EquuSense nodes use
accelerometers and gyroscopes to measure
acceleration and angular rotation. Magne-
tometers measure orientation with respect
to the earth s magnetic eld. Our rst objec-
tive was to convert the acceleration and an-
gular rotation data rom a local to a global
rame o reerence.
By Michael Davies, EquuSys
Horses are very valuable, but also very fragile; at any given time, one in six
top equine athletes are lame in some way. Because horses are fight animals,
a lame horse will go to extraordinary lengths to hide its injury. Wild horsesevolved this trait to help prevent an injured animal rom being singled out rom
the herd as easy prey. This behavior can have disastrous consequences or do-
mesticated horses and their riders: Because horses are so adept at masking inju-
ries, it is challenging even or experts with decades o experience to recognize
subtle lameness, while diagnosing the precise cause o the injury is harder still.
Using MATLAB to Process Large Telemetry DataSets for Biomechanical Performance Analysis
MATLAB Digest
With multiple sensor nodes measur-
ing at up to 1000 times per second, it was
immediately clear that each session would
generate gigabytes o data. With MALAB,
we transormed the millions o rows o
data rom comma-separated value les
into matrices that we could then lter,process, and convert into meaningul
inormation.
Products Used
MATLAB
Aerospace Toolbox
Instrument Control Toolbox
Figure 1. A horse with EquuSense sensors fttedto the ront hooves.
-
7/30/2019 91643 v00 Digest Mar09 EquuSys FINAL
2/4
2 MATLAB Digest www.mathworks.com
We used Aerospace oolbox to trans-
orm rames o reerence by converting
direction cosine matrices to Euler angles.
Because our sensors provided accelerationin meters-per-second squared, we needed to
integrate acceleration over time to nd sen-
sor velocity. We then used that measurement
to determine the position o each sensor.
During the early, exploratory phases o
development, we moved between scripts
and interactive mode in MALAB to exam-
ine variables and try out new ideas quickly.
We could visualize the data using MALAB
plotting capabilities without writing our
own custom routines. We could process
large data sets very efciently by using arrays,
matrices, and vectorized unctions. I we
had used C or C++ instead o MALAB,
these tasks would have taken much longer.
One o our inertial navigation experts
had written an extensive signal processing
library in C++ that we initially called rom
MALAB. Eventually, we recoded the en-
tire library in MALAB because we ound
that MALAB scripts or signal processing,
manipulating matrices, and perorming
rame-o-reerence calculations are easier to
understand and more transparent than an
equivalent set o C++ routines.
Testing the First-GenerationPrototype
As a proo o concept, we tested the rst
generation o the EquuSense system with
help rom an expert veterinarian who useda technique called blocking. Commonly
used to pinpoint the location o an injury,
blocking involves anesthetizing an area o
the lame leg and then examining the horses
gait. I the horse begins to walk normally,
the injury can be assumed to be in the anes-
thetized area.
During tests o our rst-generation pro-
totype system, a veterinarian anesthetized
the leg o an injured horse so that the horse
was no longer visibly lame. Even to the vet-erinarians expert eye, the horse appeared
sound. However, the MALAB plots gen-
erated by our analysis revealed that the
horse was transmitting less power to the
right ront leg (RF) and more power to the
le rear leg (LR)he was leaning back to
put less pressure on the hurt leg (Figure 2).
Te data demonstrated that the horse
put much more pressure on LR than
on RF. Te plot on the right in Figure 2
shows the data or the anesthetized hoo.
Although the injury was no longer evident
rom a visual inspection, the plot clearly
shows that the animal is avoring the right
ront leg.
Tis test demonstrated that transmitted
power, a metric that we had calculated rom
the raw sensor data, provided a reliable in-
dication o the gait asymmetries associatedwith lameness.
We learned another important lesson
rom this test: Te EquuSense interace le
the vet unable to interpret the plots o trans-
mitted power without our help. Clearly, we
would have to improve all aspects o the
system in parallel. As we moved to more
advanced sensors with more sophisticated
signal processing algorithms, we would
also need to develop an interace that gave
users a more intuitive view o how the horse
was moving.
Figure 2. Plots showing power distribution o hooves or a horse with an injured right ront hoo.Each line represents a stride. Let: Transmitted power distribution beore blocking, indicating lesspower transmitted to RF than to LR. Right: Transmitted power distribution ater blocking, showingthat the horse still avors LR, indicating lameness that was undetectable in visual examination othe animals gait.
-
7/30/2019 91643 v00 Digest Mar09 EquuSys FINAL
3/4
3 MATLAB Digest www.mathworks.com
Common Lameness Diagnosis Methods
At present, professionals rely primarily on the unaided human eye to observe the motion of
horses and use palpation and blocking of the lame limb to diagnose lameness.
Most quantitative approaches to diagnosing lameness, including high-speed cameras,
treadmills, and pressure pads, have met with limited success. A typical video motion-capture
system is designed for human athletes. It is not scalable to the speed and size of a horse;
its capture volume is typically limited to analyzing one or two steps at full gallop. On the
other hand, treadmills distort the gait of the horse, and attaching the approximately 75
video markers needed for analysis can take hours. Pressure pads simply do not produce
accurate results.
Second-GenerationEnhancements
Te second-generation prototype and sub-
sequent trials o EquuSense provided more
data on equine motion, including more pre-
cise measurements o acceleration and an-
gular rotation. It also included an enhanced
user interace, which we developed with
MALAB GUI-building tools.
When analyzing a horse, veterinarians
and equine proessionals use this soware
to dene sessions rom the trial data. A ses-
sion includes all the data or a particular
gait (trot, canter, and so on) or a specic
episode in the motion o the horse. Te ses-
sion is then processed using the MALAB
algorithms that we have been improving it-
eratively since the initial exploration phases
o development. Te algorithms recognize
gaits and calculate the 3-D hoo trajectory
(Figure 3) and the Euler angles or the ori-
entation o each hoo.
Users can annotate the data to markspecic events, such as a phased transition
rom the hoo landing on the ground to the
hoo taking o, and then replicate that event
throughout the data set o interest.
We achieved another critical break-
through in the second-generation
EquuSense: We developed MALAB al-
gorithms to create an animated repre-
sentation o the hoo ight path shown in
Figure 3. When we showed some o our
early users this animation together with
a video replay o the event, they reported
that this eature helped them visualize
vital aspects o the data and understand
it intuitively.
Figure 3. Three-dimensional plot o hoo flight path.
-
7/30/2019 91643 v00 Digest Mar09 EquuSys FINAL
4/4
www.mathworks.com
Resources
visit
www.mathworks.com
technical support
www.mathworks.com/support
online user community
www.mathworks.com/matlabcentral
Demos
www.mathworks.com/demos
training serviceswww.mathworks.com/training
thirD-party proDucts
anD services
www.mathworks.com/connections
Wdwd contacts
www.mathworks.com/contact
91643v00 03/09
2009 The MathWorks, Inc. MATLAB and Simulinkare registered trademarks o The MathWorks, Inc. Seewww.mathworks.com/trademarks or a list o additionaltrademarks. Other product or brand names may be trade-marks or registered trademarks o their respective holders.
Into Production and Beyond
Production EquuSense systems are already
being used in clinical research, and we
continue to improve the system. Wehave started to use Instrument Control
oolbox to stream data directly rom the
sensors into MALAB, and we plan to cre-
ate a standalone version o the EquuSense
soware with MALAB Compiler. We
are also exploring other applications or
the technology, including biomechanical
studies o human athletes.
For More Information EquuSys
www.equusys.com
Webinar: Technical computing withMATLABwww.mathworks.com/applications/
tech_computing
4 MATLAB Digest