Simplified Machine Learning Model as an Intelligent Support for Safe Urban Cycling
Abstract
:1. Introduction
1.1. Urban Mobility
1.2. Road Safety for Cyclists
1.3. Intelligent Urban Cycling
- Section 2 is prepared to outline the intuitive information presented by the problem and the main research method adopted to identify the dominant characteristics and advantages of simplified machine learning in achieving unexpected collision risk identification tasks crucial for training and testing procedures to maximize the effectiveness of model classification.
- Section 3 is structured to generally explain the methodology used and the essential description of the proposed solution that includes the architecture of the proposed cognitive model and its main parts.
- Section 4 describes the experimental stage used to observe the performance of the model with different datasets and provides comparative tables and graphs that illustrate its performance when using different feature extractors and in each of the sample ranges that were used (one-shot and five-shot).
- Section 5 provides a discussion of notable results related to the evaluation of the proposed model, its generalization capacity, and its comparison against other state-of-the-art methods, as well as other particular aspects of its operation and performance.
- Section 6 expresses the main research conclusions.
- 1.
- Reducing time, effort, and costs related to the number of examples or training samples used in conventional deep learning (DL) and machine learning (ML) models;
- 2.
- Having this proposal, based on cutting-edge technology, presented as a novel support option for cyclists, allowing them to travel more safely during trips within urban areas;
- 3.
- Contributing to the area of machine learning with a model that proposes using fewer examples or samples of information for training and being able to resemble the natural learning of human beings.
2. Simplified Machine Learning
2.1. The Challenge of Machine Learning
2.2. Related Work
2.3. Contrastive Learning
2.4. Approach Overview and Contributions
- Medicine: In this field, its application focuses on supporting health professionals in the diagnosis of rare diseases using a limited number of medical images as training examples, which supports identifying conditions using minimal or scarce data. On the other hand, it could accelerate the development of more precise treatments, drugs, and diagnoses.
- Security systems and access control: Within facial recognition systems, being able to identify a person from a single image is essential in situations such as access control, where it is very likely that there are no several images available. It also helps improve biometric authentication systems by being able to verify identities using minimal training samples.
- Handwriting recognition: In document scanning systems, it enables the recognition of handwritten or uncommon fonts using limited examples, enabling the scanning of historical or old documents. It also supports the classification and understanding of textual data with minimal labeled examples using only a limited set of examples.
- Robotics: Using object recognition with few examples, robots can identify and manipulate new objects with minimal training. This functionality allows for increased adaptability in non-uniform or dynamic environments such as commercial warehouses. Additionally, the ability of robots to learn tasks from a single demonstration facilitates the learning of complex tasks using few examples. Likewise, autonomous robotics uses recognition with few examples to detect or avoid unknown objects in its path for better self-driving.
- Species identification: It can support the identification and tracking of rare or completely unidentified species from a few photographic samples. Furthermore, it facilitates the study of biodiversity through the recognition of new species from limited observations or images.
3. Materials and Methods
3.1. Methodology
- 1.
- Research problem statement;
- 2.
- Design and development of the solution proposal;
- 3.
- Data collection and analysis;
- 4.
- Preliminary results.
3.2. Cognitive Model Architecture
Algorithm 1: General training algorithm for a Siamese neural network |
|
3.3. Affinity Layer Overview
3.4. Combined Affinity Layer Overview
3.5. Dataset Overview
- The MiniImageNet dataset, as stated by Vinyals et al. [23], contains 100 classes chosen randomly from the original ImageNet dataset, and each of those classes is itself composed of 600 images. The dataset was divided following what was presented in [31,35,36,37], into 64, 16, and 20 training, validation, and test classes, respectively. The main reason for using this dataset is its complexity and its repeated use to test many other one-shot learning tasks.
- The CIFAR-100 dataset, as stated in [32], contains 100 classes with 600 images each. The dataset was divided as suggested in [23,35,36,38] into 64, 16, and 20 training, validation, and test classes, respectively. This division is in line with other research that evaluated one-shot learning models with this dataset.
- The CUB-200–2011 dataset defined in [33], as previously mentioned, is a fine-grained dataset consisting of 200 classes and images. A split was applied to the dataset similar to the one proposed in [35] of 100, 50, and 50 classes for training, validation, and testing, respectively, which in turn is in line with the splits also established in [14,22,23,36,38,39,40].
4. Results
4.1. Experimental Setup
4.2. Comparison of the Model Against Reference Data
4.3. Performance and Generalization in the State-of-the-Art
5. Discussion
6. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
Abbreviations
CNN | convolutional neural network |
CNNs | convolutional neural networks |
DL | deep learning |
LSTM | long short-term memory |
ML | machine learning |
SML | simplified machine learning |
References
- López Gómez, L. La Bicicleta como Medio de Transporte en la Movilidad Sustentable; Technical Report; Dirección General de Análisis Legislativo: Senado de la República, Mexico, 2018. [Google Scholar]
- ITDP. Manual Ciclociudades I. La Movilidad en Bicicleta como Política Pública. In Manual Ciclociudades; Instituto de Políticas para el Transporte y el Desarrollo: Cuauhtémoc, Mexico, 2011; Volume I, p. 62. [Google Scholar]
- Vision Zero Network. What Is Vision Zero? 2022. Available online: https://visionzeronetwork.org/about/what-is-vision-zero/ (accessed on 17 January 2025).
- WHO. Global Status Report on Road Safety 2018; Technical Report; World Health Organization: Geneva, Switzerland, 2018. [Google Scholar]
- INEGI. Estadísticas a Propósito del Día de Muertos, DATOS NACIONALES; Technical Report; Instituto Nacional de Estadística y Geografía: Aguascalientes, Mexico, 2019. [Google Scholar]
- Hilmkil, A.; Ivarsson, O.; Johansson, M.; Kuylenstierna, D.; van Erp, T. Towards Machine Learning on data from Professional Cyclists. arXiv 2018, arXiv:1808.00198. [Google Scholar]
- Ngiam, J.; Khosla, A.; Kim, M.; Nam, J.; Lee, H.; Ng, A.Y. Multimodal Deep Learning. In Proceedings of the 28th International Conference on Machine Learning, ICML 2011, Bellevue, Washington, DC, USA, 28 June–2 July 2011; Getoor, L., Scheffer, T., Eds.; Omnipress: Madison, WI, USA, 2011; pp. 689–696. [Google Scholar]
- Srivastava, N.; Salakhutdinov, R. Multimodal Learning with Deep Boltzmann Machines. J. Mach. Learn. Res. 2014, 15, 2949–2980. [Google Scholar]
- Zhao, H.; Wijnands, J.S.; Nice, K.A.; Thompson, J.; Aschwanden, G.D.P.A.; Stevenson, M.; Guo, J. Unsupervised Deep Learning to Explore Streetscape Factors Associated with Urban Cyclist Safety. In Smart Transportation Systems 2019; Qu, X., Zhen, L., Howlett, R.J., Jain, L.C., Eds.; Springer: Singapore, 2019; pp. 155–164. [Google Scholar]
- Galán, R.; Calle, M.; García., J.M. Análisis de variables que influencian la accidentalidad ciclista: Desarrollo de modelos y diseño de una herramienta de ayuda. In Proceedings of the XIII Congreso de Ingeniería de Organización, Barcelona, Spain, 2–4 September 2009; Asociación para el Desarrollo de la Ingeniería de Organización-ADINGOR: Valencia, Spain, 2009; pp. 696–703. [Google Scholar]
- Caterini, A.L.; Chang, D.E. Deep Neural Networks in a Mathematical Framework, 1st ed.; Incorporated; Springer Publishing Company: Berlin/Heidelberg, Germany, 2018. [Google Scholar]
- Cuomo, S.; Di Cola, V.S.; Giampaolo, F.; Rozza, G.; Raissi, M.; Piccialli, F. Scientific Machine Learning Through Physics–Informed Neural Networks: Where we are and What’s Next. J. Sci. Comput. 2022, 92, 88. [Google Scholar] [CrossRef]
- Khosla, P.; Teterwak, P.; Wang, C.; Sarna, A.; Tian, Y.; Isola, P.; Maschinot, A.; Liu, C.; Krishnan, D. Supervised Contrastive Learning. arXiv 2021, arXiv:2004.11362. [Google Scholar]
- Chen, T.; Kornblith, S.; Norouzi, M.; Hinton, G. A Simple Framework for Contrastive Learning of Visual Representations. In Proceedings of the 37th International Conference on Machine Learning, Virtual, 13–18 July 2020; Daumé, H., III, Singh, A., Eds.; Proceedings of Machine Learning Research; PMLR: London, UK, 2020; Volume 119, pp. 1597–1607. [Google Scholar]
- van den Oord, A.; Li, Y.; Vinyals, O. Representation Learning with Contrastive Predictive Coding. arXiv 2019, arXiv:1807.03748. [Google Scholar]
- Tian, Y.; Krishnan, D.; Isola, P. Contrastive Multiview Coding. arXiv 2020, arXiv:1906.05849. [Google Scholar]
- Hjelm, R.D.; Fedorov, A.; Lavoie-Marchildon, S.; Grewal, K.; Bachman, P.; Trischler, A.; Bengio, Y. Learning deep representations by mutual information estimation and maximization. In Proceedings of the International Conference on Learning Representations, New Orleans, LA, USA, 6–9 May 2019. [Google Scholar]
- He, K.; Fan, H.; Wu, Y.; Xie, S.; Girshick, R. Momentum Contrast for Unsupervised Visual Representation Learning. In Proceedings of the 2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), Seattle, WA, USA, 14–19 June 2020; pp. 9726–9735. [Google Scholar] [CrossRef]
- Hernández-Herrera, A.; Rubio-Espino, E.; Álvarez-Vargas, R.; Ponce-Ponce, V.H. Una Exploración Sobre el Aprendizaje Automático Simplificado: Generalización a partir de Algunos Ejemplos. Komput. Sapiens 2021, 3, 36–41. [Google Scholar]
- Hernández-Herrera, A.; Rubio-Espino, E.; Álvarez-Vargas, R.; Ponce-Ponce, V.H. Simplified Machine Learning Model as an Intelligent Support for Safe Urban Cycling. Preprints 2024, 2024121671. [Google Scholar] [CrossRef]
- Lee, S.W.; O’Doherty, J.P.; Shimojo, S. Neural Computations Mediating One-Shot Learning in the Human Brain. PLoS Biol. 2015, 13, e1002137. [Google Scholar] [CrossRef] [PubMed]
- Snell, J.; Swersky, K.; Zemel, R. Prototypical Networks for Few-shot Learning. In Advances in Neural Information Processing Systems; Guyon, I., Luxburg, U.V., Bengio, S., Wallach, H., Fergus, R., Vishwanathan, S., Garnett, R., Eds.; Curran Associates, Inc.: Sydney, NSW, Australia, 2017; Volume 30. [Google Scholar]
- Vinyals, O.; Blundell, C.; Lillicrap, T.; Kavukcuoglu, K.; Wierstra, D. Matching Networks for One Shot Learning. In Advances in Neural Information Processing Systems; Lee, D., Sugiyama, M., Luxburg, U., Guyon, I., Garnett, R., Eds.; Curran Associates, Inc.: Sydney, NSW, Australia, 2016; Volume 29. [Google Scholar]
- Hernández-Sampieri, R.; Mendoza, C. Metodología de la Investigación: Las Rutas Cuantitativa, Cualitativa y Mixta; McGraw-Hill Interamericana: New York, NY, USA, 2018. [Google Scholar]
- Xing, E.; Jordan, M.; Russell, S.J.; Ng, A. Distance Metric Learning with Application to Clustering with Side-Information. In Advances in Neural Information Processing Systems; Becker, S., Thrun, S., Obermayer, K., Eds.; MIT Press: Cambridge, MA, USA, 2002; Volume 15. [Google Scholar]
- Hadsell, R.; Chopra, S.; LeCun, Y. Dimensionality Reduction by Learning an Invariant Mapping. In Proceedings of the 2006 IEEE Computer Society Conference on Computer Vision and Pattern Recognition (CVPR’06), New York, NY, USA, 17–22 June 2006; Volume 2, pp. 1735–1742. [Google Scholar] [CrossRef]
- Bromley, J.; Bentz, J.W.; Bottou, L.; Guyon, I.M.; LeCun, Y.; Moore, C.; Säckinger, E.; Shah, R. Signature Verification Using A “Siamese” Time Delay Neural Network. Int. J. Pattern Recognit. Artif. Intell. 1993, 7, 669–688. [Google Scholar] [CrossRef]
- Koch, G.R. Siamese Neural Networks for One-Shot Image Recognition. In Proceedings of the 32nd International Conference on Machine Learning, Lile, France, 6–11 July 2015. [Google Scholar]
- He, K.; Zhang, X.; Ren, S.; Sun, J. Deep residual learning for image recognition. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Las Vegas, NV, USA, 27–30 June 2016; pp. 770–778. [Google Scholar]
- Tan, M.; Le, Q. Efficientnet: Rethinking model scaling for convolutional neural networks. In Proceedings of the International Conference on Machine Learning, Long Beach, CA, USA, 10–15 June 2019; pp. 6105–6114. [Google Scholar]
- Li, X.; Yu, L.; Fu, C.W.; Fang, M.; Heng, P.A. Revisiting metric learning for few-shot image classification. Neurocomputing 2020, 406, 49–58. [Google Scholar] [CrossRef]
- Krizhevsky, A.; Hinton, G. Learning Multiple Layers of Features from Tiny Images; Technical Report; University of Toronto: Toronto, ON, Canada, 2009. [Google Scholar]
- Wah, C.; Branson, S.; Welinder, P.; Perona, P.; Belongie, S. The Caltech-UCSD Birds-200-2011 Dataset. 2011. Available online: https://www.vision.caltech.edu/datasets/cub_200_2011/ (accessed on 17 January 2025).
- Loquercio, A.; Maqueda, A.I.; del Blanco, C.R.; Scaramuzza, D. DroNet: Learning to Fly by Driving. IEEE Robot. Autom. Lett. 2018, 3, 1088–1095. [Google Scholar] [CrossRef]
- Chen, Z.; Fu, Y.; Zhang, Y.; Jiang, Y.G.; Xue, X.; Sigal, L. Multi-Level Semantic Feature Augmentation for One-Shot Learning. IEEE Trans. Image Process. 2019, 28, 4594–4605. [Google Scholar] [CrossRef] [PubMed]
- Sung, F.; Yang, Y.; Zhang, L.; Xiang, T.; Torr, P.H.; Hospedales, T.M. Learning to Compare: Relation Network for Few-Shot Learning. In Proceedings of the 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition, Salt Lake City, UT, USA, 18–22 June 2018; pp. 1199–1208. [Google Scholar] [CrossRef]
- Hilliard, N.; Phillips, L.; Howland, S.; Yankov, A.; Corley, C.D.; Hodas, N.O. Few-Shot Learning with Metric-Agnostic Conditional Embeddings. arXiv 2018, arXiv:1802.04376. [Google Scholar]
- Zhou, F.; Wu, B.; Li, Z. Deep Meta-Learning: Learning to Learn in the Concept Space. arXiv 2018, arXiv:1802.03596. [Google Scholar]
- Mangla, P.; Kumari, N.; Sinha, A.; Singh, M.; Krishnamurthy, B.; Balasubramanian, V.N. Charting the Right Manifold: Manifold Mixup for Few-shot Learning. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision (WACV), Snowmass Village, CO, USA, 1–5 March 2020. [Google Scholar]
- Kang, D.; Kwon, H.; Min, J.; Cho, M. Relational Embedding for Few-Shot Classification. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), Montreal, QC, Canada, 10–17 October 2021; pp. 8822–8833. [Google Scholar]
- Li, Z.; Zhou, F.; Chen, F.; Li, H. Meta-SGD: Learning to Learn Quickly for Few-Shot Learning. arXiv 2017, arXiv:1707.09835. [Google Scholar]
- Finn, C.; Abbeel, P.; Levine, S. Model-Agnostic Meta-Learning for Fast Adaptation of Deep Networks. In Proceedings of the 34th International Conference on Machine Learning, Sydney, NSW, Australia, 6–11 August 2017; Precup, D., Teh, Y.W., Eds.; Proceedings of Machine Learning Research (PMLR): London, UK, 2017; Volume 70, pp. 1126–1135. [Google Scholar]
Available | Not Available |
---|---|
Position | Types of possible moving obstacles |
Orientation | Number of moving obstacles |
Velocity | Position of moving obstacles |
Acceleration | Known dataset according to the problem for analysis and testing. |
Image/Video |
Highlighted Advantage | Overview |
---|---|
Inspired by the process of human cognition | The model mimics the human ability to learn new concepts quickly from a limited exposure of few examples. |
Requires less data | The model can learn from a small number of examples, reducing the need for large datasets. |
Faster training | The model can be trained faster because it requires fewer examples in the process. |
Lower costs | The model from a data collection perspective is more cost-effective because it requires less data collection and labeling. |
Greater adaptability | Due to its flexibility in terms of the amount of information it requires, the model can quickly adapt to new tasks or scenarios. |
Efficient learning process | The model uses techniques such as contrastive learning, where it learns from a similarity function or based on the transfer of previously learned knowledge. |
Improves generalization | The model can generalize from a few examples to unseen data based on learned features because it is designed to generalize from limited data to recognize new instances. |
Feature Extractor | Dataset | A1 | A2 | SML Model () | |||
---|---|---|---|---|---|---|---|
1-Shot | 5-Shot | 1-Shot | 5-Shot | 1-Shot | 5-Shot | ||
ResNet-18 | MiniImageNet | 62.93 | 69.66 | 62.86 | 67.66 | 67.05 | 81.40 |
CIFAR-100 | 62.83 | 68.50 | 64.30 | 67.99 | 67.14 | 80.17 | |
CUB-200–2011 | 70.46 | 77.29 | 70.48 | 76.32 | 73.52 | 83.73 | |
DroNet | 59.93 | 66.56 | 59.28 | 63.07 | 64.51 | 80.85 |
Feature Extractor | Dataset | A1 | A2 | SML Model () | |||
---|---|---|---|---|---|---|---|
1-Shot | 5-Shot | 1-Shot | 5-Shot | 1-Shot | 5-Shot | ||
EfficientNet-b0 | MiniImageNet | 64.14 | 70.47 | 61.65 | 64.49 | 66.90 | 81.71 |
CIFAR-100 | 68.72 | 73.59 | 66.95 | 68.99 | 71.17 | 79.12 | |
CUB-200–2011 | 73.58 | 80.38 | 71.83 | 76.90 | 74.34 | 84.42 | |
DroNet | 61.99 | 69.14 | 60.08 | 64.28 | 64.35 | 80.85 |
Model | Feature Extractor | MiniImageNet | |
---|---|---|---|
1-Shot | 5-Shot | ||
[23] MatchNet | ResNet-12 | 63.08 | 75.99 |
[41] Meta-SGD | ResNet-50 | 50.47 | 64.66 |
[22] ProtoNet | ResNet-12 | 62.39 | 68.20 |
[36] RelationNet | ResNet-34 | 57.02 | 71.07 |
[40] RENet | ResNet-12 | 67.60 | 82.58 |
SML (Our model) | ResNet-18 | 67.05 | 81.40 |
SML (Our model) | EfficientNet-B0 | 66.90 | 81.71 |
Model | Feature Extractor | CUB-200–2011 | |
---|---|---|---|
1-Shot | 5-Shot | ||
[23] MatchNet | ResNet-12 | 71.87 | 85.08 |
[41] Meta-SGD | ResNet-50 | 53.34 | 67.59 |
[22] ProtoNet | ResNet-12 | 66.09 | 82.50 |
[36] RelationNet | ResNet-34 | 66.20 | 82.30 |
[40] RENet | ResNet-12 | 79.49 | 91.11 |
SML (Our model) | ResNet-18 | 73.52 | 83.73 |
SML (Our model) | EfficientNet-B0 | 74.34 | 84.42 |
Model | Feature Extractor | CIFAR-100 | |
---|---|---|---|
1-Shot | 5-Shot | ||
[42] MAML | ResNet-12 | 49.28 | 58.30 |
[23] MatchNet | ResNet-12 | 50.53 | 60.30 |
[41] Meta-SGD | ResNet-50 | 53.83 | 70.40 |
[38] DEML+Meta-SGD | ResNet-50 | 61.62 | 77.94 |
[35] Dual TriNet | ResNet-18 | 63.41 | 78.43 |
SML (Our model) | ResNet-18 | 67.14 | 80.17 |
SML (Our model) | EfficientNet-B0 | 71.17 | 81.12 |
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. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Hernández-Herrera, A.; Rubio-Espino, E.; Álvarez-Vargas, R.; Ponce-Ponce, V.H. Simplified Machine Learning Model as an Intelligent Support for Safe Urban Cycling. Appl. Sci. 2025, 15, 1395. https://doi.org/10.3390/app15031395
Hernández-Herrera A, Rubio-Espino E, Álvarez-Vargas R, Ponce-Ponce VH. Simplified Machine Learning Model as an Intelligent Support for Safe Urban Cycling. Applied Sciences. 2025; 15(3):1395. https://doi.org/10.3390/app15031395
Chicago/Turabian StyleHernández-Herrera, Alejandro, Elsa Rubio-Espino, Rogelio Álvarez-Vargas, and Victor H. Ponce-Ponce. 2025. "Simplified Machine Learning Model as an Intelligent Support for Safe Urban Cycling" Applied Sciences 15, no. 3: 1395. https://doi.org/10.3390/app15031395
APA StyleHernández-Herrera, A., Rubio-Espino, E., Álvarez-Vargas, R., & Ponce-Ponce, V. H. (2025). Simplified Machine Learning Model as an Intelligent Support for Safe Urban Cycling. Applied Sciences, 15(3), 1395. https://doi.org/10.3390/app15031395