Next Article in Journal
Water Treatment of Manganese Oxides and Organic Matter through Pre-Oxidation and Coagulation/Sedimentation
Previous Article in Journal
Fabrication of Titanium Oxide Thin-Film Electrodes with Photocatalytic Activities and an Evaluation of Their Photoelectrochemical Properties
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Proceeding Paper

AI-DAS: AI-Based Driving Assistance System for Scooters for Traffic Accident Avoidance †

Department of Computer Information and Network Engineering, Lunghwa University of Science and Technology, Taoyuan 33306, Taiwan
*
Author to whom correspondence should be addressed.
Presented at the IEEE 5th Eurasia Conference on Biomedical Engineering, Healthcare and Sustainability, Tainan, Taiwan, 2–4 June 2023.
Eng. Proc. 2023, 55(1), 58; https://doi.org/10.3390/engproc2023055058
Published: 6 December 2023

Abstract

:
Due to strong mobility, low costs, and easy parking, the scooter has become an important mode of transportation in Taiwan. The number of traffic accidents is also increasing because of drivers’ bad driving habits. For road traffic injury prevention, the government has approved the road safety policy to promote awareness of road safety. Thus, we propose an AI-based driving assistance system (AI-DAS) for scooter riders to prevent traffic accidents. In the AI-DAS, Raspberry Pi controls the camera and sensors for the scooter. The AI-DAS detects pedestrians and monitors lanes not only to warn riders and pedestrians by sound and light but also to drastically reduce accidents and traffic jams. The AI-DAS is implemented using the python programming language and is tested on the Raspberry Pi hardware platform.

1. Introduction

Due to strong mobility, low costs, and easy parking, the scooter has become an important mode of transportation in Taiwan. The number of traffic accidents is also increasing year by year because of the bad driving habits of riders, especially young riders. Therefore, the number of people killed in traffic accidents is increasing in Taiwan.
Recently, there has been much research focusing on safety message dissemination [1,2] and safe driving assistance systems [3,4,5] to avoid traffic accidents. In Refs. [1,2], each vehicle broadcasts or rebroadcasts the safety message after receiving it. The safety message for car crash alerts or rescue operation notifications must be rapidly and successfully disseminated in risk areas to avoid potential traffic accidents. However, broadcasting storms [6] may happen if all vehicles’ safety messages rebroadcast.
To prevent the broadcast storm problem, the safe driving assistance system [3,4,5] has been developed. In Ref. [4], each vehicle collects near-crash and crash data by video cameras to alert the driver and avoid potentially risky driving behaviors. In Ref. [3], LASER radio detection sensors and global positioning system (GPS) sensors are necessary to detect the vehicle and lane position. In Ref. [5], the obstacles in front of the car can be detected and the distance between the car and the nearest obstacles can be estimated. In Refs. [3,4,5], the obstacles and lane position can be seen. However, there no further operations are performed for the purpose of avoiding traffic accidents.
As a result, an AI-based driving assistance system (AI-DAS) is proposed not only to detect pedestrians and monitor lane lines but also to warn riders and pedestrians by sound and light for in order to avoid accidents. The rest of this paper is organized as follows. The hardware design of the AI-DAS is introduced in Section 2.1. The concepts of the lane position detection and accident alerting system are proposed in Section 2.2. Finally, Section 3 concludes the paper.

2. AI-Based Driving Assistance System (AI-DAS)

The functions of the AI-DAS are organized as follows.
  • Lane Line Detection Function
This function is used to detect the lane line by the output picture from the camera module.
  • Scooter Position Detection Function
It is used to recognize the scooter position between two neighboring lane lines.
  • Turn Signal Function
The turn signal function is the main contribution of the AI-DAS. It is a function designed to warn other drivers or pedestrians when the scooter begins to move out of its lane according to the recognition results from the scooter position detection function. If the scooter position is a little too far to the left/right, and the turn signal is not working, the turn signal function turns on automatically.
The hardware and software design of the AI-DAS are illustrated as follows.

2.1. Hardware Design of AI-DAS

The hardware design and the actual implementation of the AI-DAS are shown in Figure 1 and Figure 2, respectively. The AI-DAS consists of a Raspberry Pi module, cellular phone module, and camera module, where the scooter position detection function, lane line detection function, and turn signal function are embedded in the Raspberry Pi module. The camera module shown in Figure 2a is fixed to the handle pipe to obtain pictures or video of the lane. In addition, the camera module communicates with the Raspberry Pi module using a USB port connection.
As shown in Figure 2b, the Raspberry Pi module is powered by the scooter and is placed in the storage compartment of the scooter. The cellular phone module is also fixed to the handle pipe. As shown in Figure 2c, it displays the operational results of the lane line detection and turn signal functions. The connection between the Raspberry Pi and cellular phone modules is established as follows.
The cellular phone is set up as a virtual access point (AP).
The Raspberry Pi connects to the virtual AP by Wi-Fi communication.
A virtual IP address is assigned to the Raspberry Pi.
An SSH connection app is installed on the cellular phone.
The Raspberry Pi is logged in with the virtual IP address by the SSH app.

2.2. Software Design of the AI-DAS

The software design of the AI-DAS consisting of the lane line detection, scooter position detection, and turn signal functions is described in this section.
Lane line detection function: The lane line detection function is composed of the following 5 stages.
  • Distortion Correction
Figure 3a shows the raw image from the camera module. In digital photography, the optical aberration in a camera deforms and twists physically upright lines in the resulting images and makes the images appear curvy. To make a distortion correction to raw images, we obtained the camera calibration matrices and distortion coefficients utilizing chessboard images.
OpenCV (Ver. 2.x) [7] is open source and widely used for image processing applications. In this paper, three functions, findChessboardCorners (), calibrateCamera (), and undistort () are used for distortion correction. As a result, Figure 3a is modified to Figure 3b.
  • Thresholding
To make images easier to analyze, we convert the images from color to binary images using gradients and color transforms. After thresholding, Figure 3b becomes Figure 4a.
  • Color Conversion
Figure 4a shows that the lane is not easy to recognize. Therefore, before thresholding, we first transform RGB images into the HSV color space. cv2.cvtColor is used for conversion, and the thresholding and color conversion results of Figure 3a are shown in Figure 4b.
  • Perspective Transformation
For lane line detection, we transform images into bird’s-eye-view image. cv2.getPerspectiveTransform() is used to obtain the transformation matrix, and cv2.warpPerspective() is used for bird’s-eye-view images. The transformation results are shown in Figure 5a.
  • Lane detection
Since the pixels of the lane lines are concentrated within a certain range of the x-axis, the sliding window polynomial fitting approach [8,9] is used to detect the lane lines. The detection results are shown in Figure 5b. The left lane line is marked as a red line and the right lane line is marked as a blue line.
Scooter position detection: Figure 5b reveals that the position of the scooter is located in the middle of the picture. In addition, we obtain the center position of the lane through the center of the two-lane lines. Therefore, the offset of the scooter can be calculated by the position of the scooter and the center position of the lane.
Finally, the results of the lane detection are shown in Figure 6.
Turn signal function: The turn signal controller controls the left and right lights and is embedded in the scooter’s computer. After receiving a turn instruction from the lane line detection module, the GPIO control pin of Raspberry Pi sends the signal to the turn signal controller of the scooter. Therefore, the scooter rider can avoid damage as much as possible.

3. Conclusions

The scooter is an important mode of transportation in Taiwan, and the number of traffic accidents is also increasing because of drivers’ bad driving habits. Thus, we propose an AI-based driving assistance system (AI-DAS) for scooters in order to prevent road traffic injuries. In the AI-DAS, we detect lanes and control the turn signals not only to warn riders and pedestrians by sound and light but also to drastically reduce traffic accidents. In the future, the AI-DAS will include a module for the detection of moving cars and a module for the prediction of the direction of moving cars to further avoid traffic accidents.

Author Contributions

Conceptualization, Y.-D.C. and Y.-C.C.; methodology, Y.-C.C.; software, Y.-C.C.; validation, Y.-D.C. and Y.-C.C.; formal Analysis, Y.-C.C.; investigation, Y.-C.C.; resources, Y.-C.C.; data curation, Y.-C.C.; writing—original draft preparation, Y.-C.C.; writing—review and editing, Y.-D.C.; visualization, Y.-C.C.; supervision, Y.-D.C.; project administration, Y.-C.C.; funding acquisition, Y.-C.C. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Data are contained within the article.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Suthaputchakun, C.; Dianati, M.; Sun, Z. Trinary partitioned blackburstbased broadcast protocol for time-critical emergency message dissemination in vanets. IEEE Trans. Veh. Technol. 2014, 63, 2926–2940. [Google Scholar] [CrossRef]
  2. Chen, Y.-D.; Shih, Y.-P.; Shih, K.-P. An emergency message dissemination protocol using n-way search with power control for vanets. In Proceedings of the 2015 IEEE International Conference on Communications (ICC), London, UK, 8–12 June 2015; pp. 3653–3658. [Google Scholar]
  3. McCall, J.; Trivedi, M. Video-based Lane estimation and tracking for driver assistance: Survey, system, and evaluation. IEEE Trans. Intell. Transp. Syst. 2006, 7, 20–37. [Google Scholar] [CrossRef]
  4. Li, L.; Zhu, X. Design concept and method of advanced driver assistance systems. In Proceedings of the 2013 Fifth International Conference on Measuring Technology and Mechatronics Automation, Hong Kong, China, 16–17 January 2013; pp. 434–437. [Google Scholar]
  5. Fang, C.-Y.; Hsu, W.-H.; Ma, C.-W.; Chen, S.-W. A vision-based safety driver assistance system for motorcycles on a smartphone. In Proceedings of the 17th International IEEE Conference on Intelligent Transportation Systems (ITSC), Qingdao, China, 8–11 October 2014; pp. 328–333. [Google Scholar]
  6. Tseng, Y.-C.; Ni, S.-Y.; Chen, Y.-S.; Sheu, J.-P. The broadcast storm problem in a mobile ad hoc network. In Proceedings of the ACM International Conference on Mobile Computing and Networking (MOBICOM), Seattle, WA, USA, 15–19 August 1999; pp. 153–167. [Google Scholar]
  7. Intel Open-Source Computer Vision Library Reference Manual. 2001. Available online: https://www.cs.unc.edu/Research/stc/FAQs/OpenCV/OpenCVReferenceManual.pdf (accessed on 5 December 2023).
  8. Dragojevi’c, M.; Stevi’c, S.; Kruni´c, M.; Luki´c, N. Advanced Lane finding prototype based on autoware platform. In Proceedings of the 2020 Zooming Innovation in Consumer Technologies Conference (ZINC), Novi Sad, Serbia, 26–27 May 2020; pp. 169–173. [Google Scholar]
  9. Yılmaz, M.E.; Erkmen, B. Advanced Lane line detection using heterogeneous embedded computing. In Proceedings of the 2021 International Conference on Innovations in Intelligent SysTems and Applications (INISTA), Kocaeli, Turkey, 25–27 August 2021; pp. 1–5. [Google Scholar]
Figure 1. Hardware components of the AI-DAS.
Figure 1. Hardware components of the AI-DAS.
Engproc 55 00058 g001
Figure 2. Actual implementation of the AI-DAS in a (a) camera, (b) Raspberry Pi, and (c) cellular phone, respectively.
Figure 2. Actual implementation of the AI-DAS in a (a) camera, (b) Raspberry Pi, and (c) cellular phone, respectively.
Engproc 55 00058 g002
Figure 3. (a) Raw images of the lane lines. (b) Distortion correction of (a).
Figure 3. (a) Raw images of the lane lines. (b) Distortion correction of (a).
Engproc 55 00058 g003
Figure 4. (a) Results of the thresholding. (b) Results of the color conversion.
Figure 4. (a) Results of the thresholding. (b) Results of the color conversion.
Engproc 55 00058 g004
Figure 5. (a) Result of the perspective transformation. (b) Results of the lane line detection.
Figure 5. (a) Result of the perspective transformation. (b) Results of the lane line detection.
Engproc 55 00058 g005
Figure 6. Result of the lane detection.
Figure 6. Result of the lane detection.
Engproc 55 00058 g006
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Chen, Y.-D.; Chang, Y.-C. AI-DAS: AI-Based Driving Assistance System for Scooters for Traffic Accident Avoidance. Eng. Proc. 2023, 55, 58. https://doi.org/10.3390/engproc2023055058

AMA Style

Chen Y-D, Chang Y-C. AI-DAS: AI-Based Driving Assistance System for Scooters for Traffic Accident Avoidance. Engineering Proceedings. 2023; 55(1):58. https://doi.org/10.3390/engproc2023055058

Chicago/Turabian Style

Chen, Yen-Da, and Yu-Cheng Chang. 2023. "AI-DAS: AI-Based Driving Assistance System for Scooters for Traffic Accident Avoidance" Engineering Proceedings 55, no. 1: 58. https://doi.org/10.3390/engproc2023055058

Article Metrics

Back to TopTop