Multi-Pedestrian Tracking System Based on Asynchronized IMUs? Chuanhua Lu, Hideaki Uchiyama, Diego Thomas, Atsushi Shimada, and Rin-ichiro Taniguchi Kyushu University, Fukuoka Japan {luchuanhua,uchiyama,diego thomas}@limu.ait.kyushu-u.ac.jp, atsush@ait.kyushu-u.ac.jp, rin@kyudai.jp Abstract. We propose a multi-pedestrian tracking system based on MEMS based IMUs as a novel tool for human behavior analysis. With asynchronized multiple IMUs, our system can track IMU-attached pedes- trians in synchronization at a high frame rate in the large environment, compared with vision based approaches. The output data is similar to standard PDR systems as follows: the time-series position, velocity, and heading of the pedestrians in the 3D space. To realize our system, we propose a simple but effective calibration technique for synchronizing the timelines of the asynchronized IMUs. With our system, users can analyze the detailed motion behaviors of the people who participate in a group work or a collective activity, quantitatively. By combining with other sensors such as an eye tracker, our system can further provide more comprehensive data in the experiments. Keywords: Multi-pedestrian · Inertial navigation · Calibration. 1 Introduction Various demands on indoor positioning systems also has been rapidly increas- ing for location-based services, such as navigation to shops, and advertisements. From a technical point of view, the indoor positioning systems can be classified into three categories: radio wave based systems, vision based ones, and inertial sensor based ones. The use of radio frequency identification (RFID) [2,10], Blue- tooth low energy (BLE) [9], and WiFi [12,14] belongs to the first category. These systems are stable, and easy to use after the calibration of the sensor positions is performed once in the target environment. However, their positioning accuracy is still relatively low due to noisy measurement of the sensor data. As another drawback, they can provide the position of the users only, and generally cannot provide their velocity and heading. The second category, which is vision based systems, can be further separated into two subcategories: fixed-camera based ones [4, 6, 15], and movable-camera based ones [1, 8]. Both two subcategories can achieve high accurate indoor positioning. However, the main drawback of vision ? Supported by JSPS KAKENHI Grant Number JP18H04125 2 C. Lu et al. based approaches is that they require an appropriate illumination conditions for cameras, such as bright illumination or less dynamic illumination changes. The movable-camera based ones are generally based on simultaneous localization and mapping (SLAM). Typically, SLAM cannot perform well when the target space is not static. The last one, which is inertial sensor based systems [11, 13, 16], can be considered as most cost-effective. Even with low cost IMU sensors, these systems can achieve high accurate and high frame rate positioning based on both dead reckoning and map matching. Moreover, they have no constraint to the environment such as crowd or illumination changes, and also can provide the velocity and heading of the users. Therefore, rather than the radio wave or vision based systems, the inertial sensor based ones can be more suitable for human motion analysis in various situations. In this paper, we propose a multi-pedestrian tracking system based on MEMS based IMUs. Our goal is to track multiple IMU-attached pedestrians in synchro- nization at high frame rate in the large environment, compared with vision based approaches. Especially, we tackle the case of using asynchronized IMUs because the global time based synchronization for multiple IMUs is not always usable, or not accurate. In our prototype system, we use the NGIMU1 as an IMU device. The use of our system is designed as follows. First, we fix all of the IMUs on the board, and rotate them for the process of time-synchronization. Next, we attach the IMU onto each pedestrian, and collect data during the experiments for hu- man motion analysis. After the experiments, we synchronize all of the data, and finally output all of the tracking results. For the behavior or motion analysis for each pedestrian, we can use any PDR system, such as [5]. Since we use an IMU based PDR, our system can output the time series position, velocity, and heading of the pedestrians under various conditions, compared with vision based systems. With our system, the researchers on human behavior analysis can ana- lyze the movements of the people who participate in a group work or a collective activity, quantitatively. By combining with other sensors such as eye tracker or electroencephalograph (EEG), our system can provide more comprehensive data in the experiments. In summary, the contribution of our paper is threefold as follows. – A novel multiple pedestrian tracking systems is proposed. – A calibration process for offline time-synchronization of multi-IMUs is pro- posed. – A potential usage is introduced. 2 System Configuration Our system is designed for tracking multiple IMU-attached pedestrians in the large 3D environment. First, we attach asynchronized IMUs onto pedestrians to capture the data during the movement, and then process the data offline. The definition of asynchronized IMUs is that they have their own timelines 1 http://x-io.co.uk/ngimu/ Multi-Pedestrian Tracking System Based on Asynchronized IMUs 3 Capture timer IM Us recorded time points recorded sensor data Processing data synchronizer synchronized sensor data single PDR synchronized tracking results data viewer Fig. 1: The overview of our system configuration. individually such that the timing of booting an IMU corresponds to the origin of the timeline. Since it is not easy to simultaneously boot all of the IMUs, for instance 10 IMUs, the time synchronization technique is required for our system. As illustrated in Fig. 1, our system is based on two main steps: the data capture during the experiment for human behavior analysis, and the data processing after the experiment. The modules in the processes consist of four parts: the timer, the data synchronizer, the single PDR, and the data viewer. In the rest of this section, we explain the detail of each module, and its usage. 2.1 Timer The timer is a simple tool to save time points for all the processes. During the experiment, some important time points should be manually recorded by the users: when the first IMU is booted, when the last IMU is booted, when the calibration data capture is started and ended, etc. This tool is normally installed on a laptop so that the time points are recorded in a global timeline given by a laptop. 2.2 Data Synchronizer We propose a software based time synchronization technique to use asynchro- nized IMUs for multiple pedestrian tracking. As illustrated in Fig. 2, the global 4 C. Lu et al. Angular velocity 0 IMU2 timeline Angular velocity 0 IMU1 timeline 0 ‫ݐ‬ଵ ‫ݐ‬ଶ ‫ݐ‬ଷ ‫ݐ‬ସ ‫ݐ‬ହ ‫଺ݐ‬ Global timeline Fig. 2: The global timeline and each IMU timeline. time defined in the timer is the main timeline in our system. In this section, we first explain how to use the timer for the data synchronizer, and then explain how to synchronize the data from different IMUs. Usage and timeline Here is the example of using two IMUs for explanation simplicity. If multiple IMUs are used, IMU2 corresponds to the lastly-booted IMU, and IMU1 corresponds to the firstly-booted IMUs. First, the users record the time t1 with the timer, as the time point before booting all the IMUs. Then, they boot IMU1 at time t2 , and do the same for IMU2 at time t3 . These are not recorded. We assume that each IMU starts recording the data to the internal memory card immediately right after it is booted. For an asychronized IMU, the booting time corresponds to the origin of each IMU timeline. Therefore, the time points of each origin in each IMU timeline are different in the global timeline. The users record time t4 with the timer, as the time point after all IMUs are finally booted. They start a specific motion for calibrating the IMU timelines at time t5 , and finish the motion at time t6 . It should be noted that we do not record t2 and t3 in the timer because it is not easy to manually save the accurate time point. This means that we do not know the exact time of t2 and t3 in the processing. t1 , t4 , t5 and t6 are roughly necessary for the time synchronization. Next, we explain the main idea of how to merge the IMU timelines onto the global timeline. As discussed before, the exact value of t3 , when IMU2 is booted, is not known. Therefore, in the IMU2 timeline, it is not possible to find the exact correspondence of time points which are recorded in the global time. To solve this problem, we use t4 , which is recorded with the timer after IMU2 is booted. Before recording a next time point tx after t4 , the IMUs are stationary for a time ts , which should be larger than t4 − t3 . This stationary process is useful to segment the data. In the IMU2 timeline, the IMUs are stationary between tx − t3 − ts and tx − t3 of the global timeline. We assume that t4 − t3 is small Multi-Pedestrian Tracking System Based on Asynchronized IMUs 5 (a) Step 1 (b) Step 2 (c) Step 3 (d) Step 4 (e) Back to step 1 Fig. 3: The motion for calibrating the IMU timelines. enough (less than 10s), and use ts = 10s. For most researches, we do not need the exact correspondence of tx in each timeline, and can use tx − t4 as the approximation instead. It is easy to find that the IMUs are also stationary at this time (tx − t4 ∈ [tx − t3 − ts , tx − t3 ]). Therefore, using this approximation will not introduce any error on positioning. User interaction for synchronization Hereafter, we match the IMU1 time- line to the IMU2 timeline for the time synchronization. When using more than three IMUs, we sequentially match the IMU1 timeline to others. To use the time synchronizer, the user interaction is required in the step of the data capture. In this process, we propose to use a board to fix the IMUs on it, and move the board to generate some unique data changes in the angular velocity space. After all the IMUs are booted, we fix the IMUs on the board such that their z-axis on the IMU frame is perpendicular to the board. Then, the IMUs are stationary for ts = 10s for the data segmentation. After this, we rotate the calibration board around z-axis on the ground or a desk, as illustrated in Fig. 3. This movement should be designed for matching two sequential data accurately. In our empirical experiments, we found that the sufficient amplitude of the rotation was around ±30◦ for more than 10 rounds. At the end, the IMUs are again stationary for ts = 10s. To compute the time offset between IMU1 timeline and IMU2 timeline, we match the angular velocity data on z-axis. Computation of time offset The time offset ∆t = t3 − t2 is computed by minimizing the least absolute deviation (LAD): tX max argmin |IM U 1.datat+∆t − IM U 2.datat | (1) ∆t t=tmin ∆t ∈ (0, t4 − t1 ) (2) tmin = t5 − t4 (3) tmax = t6 − t4 (4) 6 C. Lu et al. Algorithm 1: Matching the IMU1 timeline to the IMU2 timeline for IM U 1i in IM U 1: IM U 1i .∆t = N one IM U 1i .LAD = 0.0 for ∆t in range(0, t4 − t1 ): LAD = 0.0 for t in range(t5 − t4 , t6 − t4 ): LAD = LAD + |IM U 1i .datat+∆t − IM U 2.datat | if (IM U 1i .∆t == N one) or (IM U 1i .LAD > LAD): IM U 1i .∆t = ∆t IM U 1i .LAD = LAD Angular velocity 0 Global time IMU 1 IMU 2 Fig. 4: An example result of merged timeline. where IM U 1.data is the angular velocity of IMU1, IM U 2.data is that of IMU2. As illustrated in Algorithm 1, the optimal ∆t is found by a slide window based approach. Finally, as illustrated in Fig. 4, the time offset ∆t can be computed so that all the IMU timelines are matched to the global timeline. Theoretically, the error on computed ∆t is less than 1.0/rs , where rs is the sampling rate. 2.3 Single PDR & Data Viewer We can use any single PDR system such as foot-mounted or chest-mounted one to generate the tracking result for each pedestrian. The mount positions can be selected according to the issues of human motion analysis. With the synchronized sensor data, it is easy to merge all of the results in the one timeline. 3 Experiment We show the behavior analysis of two persons: a person who guides a person, and a person who is guided, namely the guide and the follower. We attach the Multi-Pedestrian Tracking System Based on Asynchronized IMUs 7 3 2.5 2 step length (m) 1.5 1 guide 0.5 follower 0 0 20 40 60 80 100 120 140 traveled time (s) Fig. 5: The relationship between the step length of the guide and that of the follower along the traveled time. IMU on each right foot, and use a standard foot-mounted PDR system based on dead reckoning and map matching for generating each tracking result. With the synchronized tracking results, it is possible to analyze the relation- ship between the walking status of two people: the guide and the follower. For example, as illustrated in Fig. 5, the relationship between the step length of the guide and that of the follower along the traveled time can be generated. Gener- ally, the follower tries to walk as the guide does. With vision based approaches, it is not possible to acquire the step-level human motion in the large environment. By using our synchronization technique, we can provide the tracking results of multiple pedestrians. From a psychological point of view, it would be interesting to analyze the degree of the comfort for the follower. 4 Conclusion In this paper, we proposed a cost-effective multi-pedestrian tracking system based on MEMS IMUs. Our system supports the researchers who are working on tracking multiple pedestrians for human motion analysis. With our calibra- tion process, the synchronization error on time was less than 50ms, which can satisfy most of research purposes. Our data viewer can be a tool such that the researchers can intuitively analyze the position and heading of the pedestrians in the experiments. In our future work, we apply this system to the human motion analysis in crowd [7]. With vision based approaches, it is possible to track many pedestrians in the images. However, the tracking is performed in an image space, and does not provide any motion in the 3D space. By using a foot-mounted IMU, we will clarify how the pedestrians walk in the crowd by analyzing the high frame rate foot motions. Also, it would be interesting to use our system with eye trackers so that the psychological aspect of pedestrians can be clarified [3]. 8 C. Lu et al. References 1. Davison, A.J., Reid, I.D., Molton, N.D., Stasse, O.: Monoslam: Real-time single camera slam. IEEE Transactions on Pattern Analysis & Machine Intelligence (6), 1052–1067 (2007) 2. Finkenzeller, K.: RFID handbook: fundamentals and applications in contactless smart cards, radio frequency identification and near-field communication. John Wiley & Sons (2010) 3. Hayhoe, M., Ballard, D.: Eye movements in natural behavior. Trends in cognitive sciences 9(4), 188–194 (2005) 4. Khan, S.M., Shah, M.: A multiview approach to tracking people in crowded scenes using a planar homography constraint. In: European Conference on Computer Vision. pp. 133–146. Springer (2006) 5. Lu, C., Uchiyama, H., Thomas, D., Shimada, A., Taniguchi, R.i.: Indoor positioning system based on chest-mounted imu. Sensors 19(2), 420 (2019) 6. Mohedano, R., Del-Blanco, C.R., Jaureguizar, F., Salgado, L., Garcı́a, N.: Ro- bust 3d people tracking and positioning system in a semi-overlapped multi-camera environment. In: Image Processing, 2008. ICIP 2008. 15th IEEE International Con- ference on. pp. 2656–2659. IEEE (2008) 7. Moussaı̈d, M., Perozo, N., Garnier, S., Helbing, D., Theraulaz, G.: The walking behaviour of pedestrian social groups and its impact on crowd dynamics. PloS one 5(4), e10047 (2010) 8. Mur-Artal, R., Tardós, J.D.: Orb-slam2: An open-source slam system for monoc- ular, stereo, and rgb-d cameras. IEEE Transactions on Robotics 33(5), 1255–1262 (2017) 9. Newman, N.: Apple ibeacon technology briefing. Journal of Direct, Data and Dig- ital Marketing Practice 15(3), 222–225 (2014) 10. Ni, L.M., Liu, Y., Lau, Y.C., Patil, A.P.: Landmarc: indoor location sensing using active rfid. In: Pervasive Computing and Communications, 2003.(PerCom 2003). Proceedings of the First IEEE International Conference on. pp. 407–415. IEEE (2003) 11. Ojeda, L., Borenstein, J.: Personal dead-reckoning system for gps-denied environ- ments. In: Safety, Security and Rescue Robotics, 2007. SSRR 2007. IEEE Interna- tional Workshop on. pp. 1–6. IEEE (2007) 12. Woo, S., Jeong, S., Mok, E., Xia, L., Choi, C., Pyeon, M., Heo, J.: Application of wifi-based indoor positioning system for labor tracking at construction sites: A case study in guangzhou mtr. Automation in Construction 20(1), 3–13 (2011) 13. Yan, H., Shan, Q., Furukawa, Y.: Ridi: Robust imu double integration. arXiv preprint arXiv:1712.09004 (2017) 14. Yang, C., Shao, H.R.: Wifi-based indoor positioning. IEEE Communications Mag- azine 53(3), 150–157 (2015) 15. Zhan, B., Monekosso, D.N., Remagnino, P., Velastin, S.A., Xu, L.Q.: Crowd anal- ysis: a survey. Machine Vision and Applications 19(5-6), 345–357 (2008) 16. Zhang, Y., Hu, W., Xu, W., Wen, H., Chou, C.T.: Naviglass: Indoor localisation using smart glasses. In: EWSN. pp. 205–216 (2016)