# Development of an automatic method for quantifying the performance of a bicycle path-following task using computer vision

Jules Ronné, François May, Laura Dubuis, Thomas Robert

► To cite this version:

Jules Ronné, François May, Laura Dubuis, Thomas Robert. Development of an automatic method for quantifying the performance of a bicycle path-following task using computer vision. Multidisciplinary Biomechanics Journal, 2025, 49th congress of the Société de Biomécanique, 10.46298/mbj.14468. hal-04737939v2

HAL Id: hal-04737939

https://hal.science/hal-04737939v2

Submitted on 31 Jan 2025

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>
# Development of an automatic method for quantifying the performance of a bicycle path-following task using computer vision

Jules Ronné, François May, Laura Dubuis, Thomas Robert*

Univ Lyon, Univ Eiffel, Univ Claude Bernard Lyon 1, LBMC UMR_T 9406, Lyon, France

* Corresponding author: thomas.robert@univ-eiffel.fr

Received date: 05/04/2024

Accepted date: 28/06/2024

Publication date: 31/01/2025

**Keywords:** bicycle, path tracking, human control, performance metric, computer vision

© 2025 The Authors

Licence CC-BY 4.0

Published by Société de Biomécanique

## 1. Introduction

Measuring a bike's handling quality requires quantifying both the workload and the performance achieved. Indeed, handling quality was defined by the ease and precision with which a pilot may complete a given task (Cooper and Harper 1969). Whereas subjective workload measurement methods are beginning to be proposed in the literature (e.g. Ronné et al. 2023), performance measurement methods remain very limited.

Zellner and Weir (1978) proposed a test procedure for motorcycle handling quality. The task was to ride on a narrow line painted on the ground. The proposed performance metrics are related to trajectory deviation from the reference line (mean absolute deviation and mean square deviation). However, the method they used to estimate deviation was indirect, i.e.: relies on acceleration measurement coupled with a task-dependent trajectory model.

Since then, very little non-task-specific quantification method has been proposed to study bicycle path-tracking performance metrics.

In this study, we proposed to develop an automatic performance quantification method based on a line deviation measurement using computer vision during a line-following task. We demonstrated this method by analysing the performance of a group of cyclists on a straight-line path-tracking task.

## 2. Methods

### 2.1 Experimental setup

A GoPro Hero3 camera was affixed to the bicycle's handlebar so that both the front wheel and the ground were in its field of view. The camera settings were 1920x1080 image, 60 Hz frequency, fisheye, and automatic stabilization turned off.

A 43 m circuit materialized by a 10 cm wide white line was marked on a tarred surface. The experimental bicycle was a foldable city bicycle from the brand Strida.

### 2.2 Calibration of homography

This step aims to convert the camera images into a calibrated top-view image of the ground. A static image (with the bike upright and the handlebar straight) of a calibration grid drawn on the ground was taken to estimate the homographic transformation matrix. In a transformed and calibrated top-view image, an operator manually identified the mean axis of the wheel and its plane of symmetry. The intersection of these two entities gives the point of contact (Q) of the front wheel with the ground. This point was fixed in the steering frame of reference.

### 2.3 Line detection

The videos are broken down into a succession of frames that are systematically transformed using the homographic process. Each image was converted into HSV
format. The pixels belonging to the line are first identified after thresholding. Each line's pixel was included if, for each color channel, its value was between the high and the low thresholds. The line was then approximated by a rectangle following an edge detection and a boxing approximation (findCountours and minAreaRect from OpenCV). The deviation from the line (distance between the contact point Q and the center of the white line) was ultimately the number of pixels between the axis of the detected rectangle and point Q.

## 2.4 Method assessment

This method assumes that the transformation matrix remains relatively the same when roll and steer angles are varying. To evaluate its validity, a video recording was made of a line-tracking task with the front wheel covered in fresh paint on a 15-meter straight line followed by a left turn. On one side, the deviation from the line was estimated using the method described above. On the other side, the distance between the line of the track and the trajectory (the trail left by the painted wheel) was measured using Kinovea software on an aerial view. This distance was defined as the reference measurement. The agreement between the two methods was assessed following a Bland-Altman method.

## 2.5 Calculation of a performance metric for a cyclist sample

A group of 20 cyclists were asked to perform a line-following task. Instructions were to follow the white line drawn on the ground with the front wheel as closely as possible at three subjective speeds (slow, comfortable and fast). Each condition was repeated 3 times in random order following a free-speed training trial. The mean absolute error distance (noted $|d_{Q/line}|$) was calculated for each participant and trial.

We assumed that performance was a parabolic function of speed and was subject to a strong training effect. We tested these hypotheses using a generalized linear model with the following factors: mean speed during the trial ($\bar{u}$, speed squared ($\bar{u}^2$), and exponential of trial number ($n_{trial}$).

# 3. Results and discussion

## 3.1 Method assessment

The Bland-Altman assessment shows a 95% limit of agreement of 0.27 ± 4.9 cm between the computer

vision and manual painting methods. These results exhibit a very small bias and variability of error of a few centimeters. This variability was likely because the homographic transformation was less correct when the bicycle was out of the vertical position. A more elaborate method should take the roll and steer angles into account.

## 3.2 Effect of speed and training on performance

The statistical model reveals a parabolic effect of velocity on the performance metric, as well as an exponential training effect (Table 1) and Figure 1 shows $|d_{Q/line}|$ as a function of $\bar{u}$ for every trial where a parabolic speed effect suggests an optimal velocity for task completion (as per this metric). Indeed, at this velocity, vehicle stability is adequate to facilitate the task, whereas lateral dynamic sensitivity remains moderate, forgiving overly sharp trajectory corrections. This result is consistent with Ronné et al. (2023), showing that handling quality perception was also U-shaped with speed. It is also interesting to note the strong training effect (see Fig. 1) on the task and on the bicycle (the bicycle used was unusual for the participants) with a stabilized performance after five laps.

<figure><img src="image_2.png" /><figcaption>Figure 1. $|d_{Q/line}|$ as a function of $\bar{u}$ for every trial completed and statistical model for $n_{trial}$ of 2, 5 and 10. The performance metric exhibits a high sensitivity to speed and training effect.</figcaption></figure>

<table><caption>Table 1. Statistical model of the performance metric.</caption><thead><tr><th>$|d_{Q/line}|$ = i + aū + bu² + ce⁻ⁿ_{trial} + ε (cm)</th><th>R² = 0.26</th><th>Coef.</th><th>p</th></tr></thead><tbody><tr><td>a</td><td>-4.0</td><td></td><td>0.009</td></tr><tr><td>b</td><td>0.82</td><td></td><td>0.007</td></tr><tr><td>c</td><td>34</td><td></td><td>&lt;0.001</td></tr></tbody></table>
## 4. Conclusions

We proposed an automatic method for quantifying line-tracking performance. The measurement error associated with this method was sufficiently low to investigate the underlying phenomenon for which it was designed: the handling quality of the two-wheeled vehicle, human control, or pilot skills.

This article presents an initial exploration of the effects of experimental conditions on the calculated metric. The metric proves highly sensitive to both bicycle speed and participant training.

## Conflict of Interest Statement

The authors declare no conflict of interest in this study.

## References

* Cooper G, Harper R. 1969. The use of pilot ratings in evaluation of aircraft handling qualities. NASA Ames Technical Report.

* Ronné J, et al. 2023. Bicycle handling quality perception: mixed effect of stability and manoeuvrability. *The Evolving Scholar* - BMD 2023. https://doi.org/10.59490/648c083143b3bec00d30df9f

* Zellner JW, Weir DH. 1978. Development of Handling Test Procedures for Motorcycles https://doi.org/10.4271/780313