Low-cost electromyograph combined with markerless pose detection
←
→
Page content transcription
If your browser does not render page correctly, please read the page content below
tm – Technisches Messen 2021; 88(S1): S71–S76 Florian Scheible*, Raphael Lamprecht*, Marc Rives, and Alexander Sutor Low-cost electromyograph combined with markerless pose detection Low-Cost-Elektromyograph kombiniert mit markerloser Posenerkennung DOI 10.1515/teme-2021-0066 erste Arbeit, die diese beiden Methoden für dynamische Übungen kombiniert. Die Methode ist aufgrund des batte- Abstract: This papers presents a low-cost electromyograph riebetriebenen Geräts und seiner handlichen Größe leicht combined with marker-less pose detection using computer an andere Sportarten anwendbar. vision. The developed and build three channel electromyo- graph is tested by measuring the muscle activity of one Schlüsselwörter: Elektromyographie, markerlose Posener- leg, while the subject is performing squats. Simultane- kennung, Low-Cost, Kniebeugen. ously, a camera records the exercise and subsequently the image data is evaluated by OpenPose. We could show that this simple setup enables the user to evaluate the muscle 1 Introduction activity of three independent muscles as function of the Measuring the present muscle activity during motion, can knee angle. These results are in good agreement to the give feedback for training and therapy but also an insight expected muscle activity. The sample-rate of the EMG to the interplay of muscles in the human body [1]. This device is 2 kHz. The overall cost of the developed device can be used to control exoskeletons to augment human is under 100 €. To our knowledge, this is the first work power [2]. Due to the fact that the muscle activity cannot combining these two methods for dynamic exercises. The be measured directly, indirect indicators are used, one method is well customizable for other sports due to the of them is the electric signal propagating through the battery powered device and its handy size. muscle during tension. This signal can be recorded by Keywords: Electromyography, marklerless pose detection, an electromyograph (EMG). Further, it is desirable to low-cost, squats. correlate the muscle activity with the executed movement. Combing an EMG with the body pose to that specific time, Zusammenfassung: In dieser Arbeit wird ein kostengüns- a detailed description of the movement can be achieved. tiger Elektromyograph kombiniert mit markerloser Pose- The contraction of the muscle fiber is initiated from nerkennung mittels Computer Vision vorgestellt. Der ent- an electric impulse from a motoneuron, which receives wickelte und gebaute Dreikanal-Elektromyograph wurde a signal form the central nervous system. At the motor getestet, indem die Muskelaktivität des Oberschenkels ge- endplates, which are specialized synapses, the muscle fiber messen wurde, während die Testperson Kniebeugen macht. action potential is generated [3]. The electric potential Gleichzeitig zeichnete eine Kamera die Übung auf, anschlie- difference of the whole muscle fiber can be measured by ßend wurden die Bilddaten mit OpenPose ausgewertet. placing surface electrodes on the skin or directly in the Wir konnten zeigen, dass mit diesem einfachen Aufbau muscle. The measured signal is processed and displayed die Muskelaktivität von drei unabhängigen Muskeln als by an EMG. The surface EMG is a noninvasive, save and Funktion des Kniewinkels ausgewertet werden kann. Die easy method to display muscle activity and is therefore Ergebnisse sind in guter Übereinstimmung zu der erwar- chosen for this study [4]. teten Muskelaktivität. Die Abtastrate des EMG-Gerätes EMG devices are usually costly therefore the clinical, beträgt 2 kHz. Die Gesamtkosten für das entwickelte Ge- therapeutic and training utility suffers from it. Low-cost rät liegen unter 100 €. Nach unserem Wissen ist dies die EMG could overcome this limitation and bring EMG to clinical and non-clinical users. The demand for low- *Corresponding author: Florian Scheible, Raphael Lamprecht, cost EMG solutions has been satisfied by the market, Marc Rives, Alexander Sutor, Institute of Measurement and Sen- which has already developed such devices. One example sor Technology, UMIT – Private University for Health Sciences, Medical Informatics and Technology, Hall in Tirol, Austria, e-mail: is the Myoware muscle sensor (SEN-13723, MyoWare, florian.scheible@umit.at, raphael.lamprecht@umit.at, The authors SparkFun Electronics), which was validated against off- F. Scheible and R. Lamprecht contributed equally to this work.
S72 F. Scheible, R. Lamprecht et al., Low-Cost EMG with pose detection the-shelf EMGs and showed good reliability. Nevertheless, The circuit for the analogue signal processing is shown the measurement noise has been shown to be larger [5, 6]. in Figure 1. At first, the signal was amplified by a factor Other low-cost EMG devices were designed by scratch of 251 with an instrumentation amplifier (INA114, Burr- and tested with repeatable exercises [7]. All systems are Brown, USA). Further, the signal was filtered with a challenged by the common noise sources in EMG signals, band-pass filter (10 Hz to 480 Hz). Additionally, a driven- which are the individual tissue structure, inherent noise in right-leg circuit fed the common mode voltage back to the electrode, movement artifacts, electromagnetic noise, the reference electrode using an inverted amplifier. This muscle cross-talk and the electric cardiac activity [8]. feedback loop reduces the common mode voltage [12]. The proposed method measures these biosignals with a self-built and low-cost EMG and correlates them with the current joint angle estimated by a camera. The com- bination of pose detection and EMG signals enables the user in therapy, sport and biomechanical research to con- nect muscle activity directly to movements. This gives a valuable insight to the biomechanical processes in the body. Commercially available systems are highly sophisti- cated and precise using active or passive marker to detect postures [7]. In this work, we used OpenPose, which is a open-source neuronal network trained to detect postures markerlessly [9]. It could be shown that OpenPose is an Fig. 2: An exemplary EMG signal of two squats: the upper panel equally exact but less laborious and costly method to de- shows the raw signal in Bit and the lower panel shows the normal- tect postures as opposed to marker-based systems [10, 11] ized root mean square (muscle activity) of the same signal. The next section will present the used methods, es- pecially the EMG device and the data processing. In the Before conversion by the analog-digital-converter following, the results will be discussed and the paper will (ADC) the signal was amplified again by an adjustable be concluded by a discussion of these results. inverting amplifier. This enables the user to control the amplification and max out the resolution of the ADC. The used microcontroller (Teensy 3.6, PJRC, USA) has an 2 Methods 16 Bit ADC, of which 13 Bit can be reasonably used at a maximum input voltage of 3.3 V. The measured data was The muscle activity was recorded by a low-cost three saved on a microSD card, which limited the sampling rate channel EMG device, which was developed and build to 2 kHz. The device has a 3D-printed housing with but- specially for that purpose. tons to allow the user to start, stop the measurement and enter the setup mode to check the amplification level. Fur- ther, LEDs indicate the signal amplitude and the device’s status. The saved data was processed with Matlab (2020a, MathWorks, Natick, MA, USA). At first, the DC compo- nent of the EMG signal ( ) was removed. Further, the root mean square ( ) is calculated by ′ ∫︁ + ( ) = 2 ( ) (1) ′ where is the filter width, in this work = 0.5 s [3] and Fig. 1: The EMG signal was recorded by the displayed circuit finally, the signal was normalized to one. Hereafter, the which had three basic steps: instrumentation amplifier (1), band- normalized root mean square will be called muscle activity. pass filter (2) and adjustable inverting amplifier (3). Further, the driven-right-leg circuit (4) is shown in the lower part of the An exemplary raw signal and the muscle activity of it are figure. shown in Figure 2.
F. Scheible, R. Lamprecht et al., Low-Cost EMG with pose detection S73 Additionally, the exercises were filmed with a com- All three muscles play a role in knee extension, whereas mercially available camera (RX10IV, Sony, Minato City, m. vastus medialis and lateralis stabilize the knee during Tokyo, Japan). The video and EMG data were synchro- squats, whereat both muscles are relatively concerted in nized by an audio signal emitted by the EMG device, magnitude and timing during knee extension [4]. The m. which marked the end of its recording. The marker signal rectus femoris is active during hip flexion, knee extension was prerecorded and cross-correlated with the audio of and straight leg raising [4]. To specifically measure the the video. Therefore, in the field no additional synchro- activity of these muscles the surface electrodes were placed nization effort is needed. Finally, the EMG signal was according to the SENIAM project [13], see Table 1. The down-sampled to the sample rate of the video, which was measurement electrodes (F-301, SKINTACT/Leonhard 50 Hz. The down-sampling was done by a linear interpola- Lang GmbH, Innsbruck, Austria) were placed in a distance tion of the original EMG signal on the time scale of the of approx. 30 mm and the reference electrodes at knee level, camera. Therefore, this final step acted as additional low see Figure 3. The contact surface was prepared by shaving pass filter and aliasing effects are avoided. the hair and cleaning skin with alcoholic wipes [4]. 3 Results The recorded EMG signals are shown in Figure 4, in which every muscle is indicated separately and additionally the knee angle. The colors indicate the movement phase, which was detected using the gradient of knee angle. Fig. 3: The affixed electrode according to the positions depicted in Table 1. Persuading a controlled and repeatable muscle activity, squats were chosen as exercise. The six subjects (24 years to 30 years) repeated respectively ten squats, first round without any additional weight and, after a short break, with barbells in both hands with a total weight of 18.6 kg. The subjects were numbered and called 1−6 . The pace of the exercise was set by a metronome at 50 bpm, where every phase of a squat (hold top, downwards movement, hold bottom, upwards movement) took around 1.2 s. Table 1: Position of the surface electrodes according to SENIAM project [13]. Fig. 4: The EMG signal and knee angle recorded while a sub- Muscle Electrode Position ject ( 6 ) was doing squats with additional weight: In the upper RV 50% on the line from the anterior spina iliaca superior section of the figure the muscle activity for the three evaluated to the superior part of the patella muscles is displayed. The color represents the movement direction VM 80% on the line between the anterior spina iliaca supe- and the black dashed sections the preparation for the exercise, rior and the joint space in front of the anterior border which was not further evaluated. In the lowest panel the knee of the medial ligament angle estimated by OpenPose is displayed. The time scale stays VL 2/3 on the line from the anterior spina iliaca superior the same in all plots. to the lateral side of the patella The muscle activity as function of the knee angle Three muscles were monitored during the squats, of every phase was averaged over all squats of one sub- which were the musculus (m.) rectus femoris (RV), m. ject/exercises and is displayed in Figure 5. The data for vastus medialis (VM) and the m. vastus lateralis (VL). every muscle was normalized on the maximum activity
S74 F. Scheible, R. Lamprecht et al., Low-Cost EMG with pose detection Fig. 5: The average magnitude of the EMG signal over all squats indicated as function of the knee angle, in which 0° corresponds to a straight leg. The upwards movement is shown in the left panel and the downwards movement vis-a-vis. One frame of of the selected subject ( 6 ) is displayed in the center. Additionally, the detected joints and the measured knee angle are marked. during both exercise, therefore a quantitative comparison between the exercises is possible. However, no conclusion 4 Discussion may be drawn about the overall strength, nor participants This section will discuss at first the results and will further may be compared with each other quantitatively. The give an insight to the technical shortcomings and possible dashed line indicates the muscle activity with weights. improvements. Muscle activity during rising is generally higher and even The measured EMG shows good agreement with the more with weights, while no difference is seen during muscle load, which can be seen in Figure 6. Therefore the downward movement. results correlate, as expected, to the muscle activity. The Figure 6 shows the muscle activity for all subjects synchronicity of the VF and VM is clearly visible, whereas during the exercise with weights, it agrees for most of the the RV shows similar behavior [14]. The maximum activity subjects, while subject 3 shows different muscle activity. of the muscles is in the acceleration phase of the squat, The reason for that stays unclear, therefore 3 will be coincide with other authors [15, 16]. Therefore, one can excluded for further evaluations. be sure that the measured signal is the muscle activity The maximum activity of the single muscles is shown and not just movement artifacts. Muscle cross-talk may in Figure 7. All subjects show good agreement on the be responsible for the similar behavior of the RV and VL, angle of maximum activity, with the difference within which may be attributed to the close placement of the a subject being of the same order of magnitude as the electrodes (Figure 3). overall difference. It can be seen that the maximum of all The shift of the maximum muscle activity, seen in muscles shifts to a lower angle under additional load. Figure 7, cannot be explained by a change in the execu- Fig. 6: The mean and normalized muscle activity over all repetitions during the exercises with weights displayed for every subject 1−6 .
F. Scheible, R. Lamprecht et al., Low-Cost EMG with pose detection S75 Fig. 7: The angle at which every muscle had its highest activity. The upper panels show the results without weight and the lower ones with weight. The vertical line indicates the mean value, with the standard derivation as dashed lines. tion of the exercise, since the movement of the hip and According to the data sheet, the common-mode rejection shoulder remains more or less the same for all subjects. ratio (CMRR) of the the INA114 is around 110 dB, which The changed body center of gravity or a different load is in the expected range for EMGs. The CMRR was not on the musculature may be the reasons. Hence, further evaluated experimentally for the presented device, as this investigations would be necessary e.g. using weights which is an important factor to specify EMG devices this will are fixed to the subject’s body. be done in the future. The 10 Hz to 480 Hz band-pass is In this work the processed EMG signals were mainly a good choice for this purpose and may be adapted for discussed in the time domain, evaluating them in the fre- other muscle groups or fatigue detection. quency domain could give an insight to muscle fatigue [17]. The calculation of the RMS is one of the most common The developed EMG device has an sufficient amplifi- processing algorithms for EMG signals, more enhanced cation rate and the signal to noise ratio is in an acceptable algorithms like wavelet functions may be used in the fu- range. The spectrum of the signal is depicted in Figure 8, ture [8, 18]. which shows good correlation with expected spectrum of The pose detection works precise and stable, however an EMG signal [4]. The right-leg drive successfully can- in our setup not in real time. The precision was not quan- cels the noise induced by the power line, since at the titatively evaluated in this work but other authors could local power frequency of 50 Hz no peak is visible. The show that the precision is sufficient [10, 11]. Qualitative observations showed that overlapping limbs could lead to small detection malfunctions. In the trade-off between cost and precision, OpenPose is a very good compromise compared to marker-based systems and faster compared to manual measurements [14, 19]. Squats were chosen due to the simplicity of the exercise and the predictable muscle activity. The movement takes place in one plane which is orthogonal to the camera axis, hence the estimation of the joint angles is straight forward. Extending this approach to out-of-plane exercises would require 3D-camera systems, while OpenPose has 3D capabilities already built in. Fig. 8: The spectrum of the EMG signal of the upwards phase for all subjects. 5 Conclusion input impedance of the INA114 is 10 GΩ, therefore an electrode-skin impedance of 100 MΩ can be tolerated [4]. This work presented a low-cost electromyograph combined with pose detection using a neuronal network. The three
S76 F. Scheible, R. Lamprecht et al., Low-Cost EMG with pose detection channel electromyograph measures the muscle activity of [9] Zhe Cao, Gines Hidalgo, Tomas Simon, Shih-En Wei, and one thigh, while a subject is doing squats. Simultaneously, Yaser Sheikh. OpenPose: Realtime Multi-Person 2D Pose Estimation Using Part Affinity Fields. IEEE Transactions on a camera records the exercise and subsequently the image Pattern Analysis and Machine Intelligence, 43(1):172–186, data is evaluated by OpenPose. This makes the presented 2021. setup cheaper, more portable and easier to apply com- [10] Iwori Takeda, Atsushi Yamada, and Hiroshi Onodera. Artifi- pared to commercially available systems. We could show, cial Intelligence-Assisted motion capture for medical applica- this simple setup enables the user to evaluate the muscle tions: a comparative study between markerless and passive activity for every knee angle. To our knowledge, those is marker motion capture. Computer methods in biomechanics and biomedical engineering, pages 1–10, 2020. the first work combining these two methods for dynamic [11] Nobuyasu Nakano, Tetsuro Sakura, Kazuhiro Ueda, Leon exercises, like squats. The method is well customizable Omura, Arata Kimura, Yoichi Iino, Senshi Fukashiro, and for other sports, like pull-ups, cycling on roller trainer or Shinsuke Yoshioka. Evaluation of 3D Markerless Motion sport climbing etc. Capture Accuracy Using OpenPose With Multiple Video Cameras. Frontiers in sports and active living, 2:50, 2020. [12] Joseph D. Bronzino. Medical devices and systems. The elec- Acknowledgment: We thank Leonhard Lang GmbH (Inns- trical engineering handbook series. CRC/Taylor & Francis, bruck, Austria) for offering the electrodes free of charge. Boca Raton, FL, 2006. [13] SENIAM project. SENIAM: Surface ElectroMyoGraphy for the Non-Invasive Assessment of Muscles. [14] J. A. Isear, J. C. Erickson, and T. W. Worrell. EMG analysis References of lower extremity muscle recruitment patterns during an unloaded squat. Medicine and science in sports and exercise, [1] Agnes Sturma, Laura A. Hruby, Cosima Prahm, Johannes A. 29(4):532–539, 1997. Mayer, and Oskar C. Aszmann. Rehabilitation of Upper [15] Valdeci Carlos Dionisio, Gil Lúcio Almeida, Marcos Duarte, Extremity Nerve Injuries Using Surface EMG Biofeedback: and Rogério Pessoto Hirata. Kinematic, kinetic and EMG Protocols for Clinical Application. Frontiers in Neuroscience, patterns during downward squatting. Journal of electromyo- 12:906, 2018. graphy and kinesiology : official journal of the International [2] Markus Hessinger, Eike Christmann, Roland Werthschützky, Society of Electrophysiological Kinesiology, 18(1):134–143, and Mario Kupnik. Messung von Nutzerinteraktion mit 2008. einem Exoskelett durch EMG und Gelenk-Drehmomente. tm - [16] Hasan Ulas Yavuz, Deniz Erdağ, Arif Mithat Amca, and Technisches Messen, 85(7-8):487–495, 2018. Serdar Aritan. Kinematic and EMG activities during front and [3] D. Gordon E. Robertson, Graham E. Caldwell, Joseph back squat variations in maximum loads. Journal of sports Hamill, Gary Kamen, and Saunders N. Whittlesey. Research sciences, 33(10):1058–1066, 2015. methods in biomechanics. Human Kinetics, Champaign, IL, [17] A. Georgakis, L. K. Stergioulas, and G. Giakas. Fatigue anal- second edition edition, 2014. ysis of the surface EMG signal in isometric constant force [4] Eleanor Criswell and Jeffrey R. Cram, editors. Cram’s intro- contractions using the averaged instantaneous frequency. duction to surface electromyography. Jones and Bartlett, IEEE transactions on bio-medical engineering, 50(2):262– Sudbury, MA, 2. ed. edition, 2011. 265, 2003. [5] Sophie Heywood, Yong Hao Pua, Jodie McClelland, Paula [18] Raymond C. H. So, Joseph K-F Ng, Ringo W. K. Lam, Geigle, Ann Rahmann, Kelly Bower, and Ross Clark. Low-cost Cynthia K. K. Lo, and Gabriel Y. F. Ng. EMG wavelet electromyography - Validation against a commercial system analysis of quadriceps muscle during repeated knee extension using both manual and automated activation timing thresh- movement. Medicine and science in sports and exercise, olds. Journal of electromyography and kinesiology : official 41(4):788–796, 2009. journal of the International Society of Electrophysiological [19] Haerin Lee, Moonki Jung, Ki-Kwang Lee, and Sang Hun Kinesiology, 42:74–80, 2018. Lee. A 3D Human-Machine Integrated Design and Analy- [6] Sergio Del Fuentes Toro, Yuyang Wei, Ester Olmeda, Lei sis Framework for Squat Exercises with a Smith Machine. Ren, Wei Guowu, and Vicente Díaz. Validation of a Low- Sensors (Basel, Switzerland), 17(2), 2017. Cost Electromyography (EMG) System via a Commercial and Accurate EMG Device: Pilot Study. Sensors (Basel, Switzerland), 19(23), 2019. [7] Tamara Grujic Supuk, Ana Kuzmanic Skelin, and Maja Cic. Design, development and testing of a low-cost sEMG system and its use in recording muscle activity in human gait. Sensors (Basel, Switzerland), 14(5):8235–8258, 2014. [8] Rubana H. Chowdhury, Mamun B. I. Reaz, Mohd Alauddin Bin Mohd Ali, Ashrif A. A. Bakar, K. Chellappan, and T. G. Chang. Surface electromyography signal processing and classification techniques. Sensors (Basel, Switzerland), 13(9):12431–12466, 2013.
You can also read