Development of an AI Algorithm for Automatic Classification of Gram Stain Images in Microbiology
Notice bibliographique
Résumé
Abstract This paper reflects on the development and performance of an advanced artificial intelligence (AI) algorithm for the automated processing and classification of Gram stain images obtained from actual microbiology samples used in clinical microbiology. The aim of the project was to effectively categorize non-standardized Gram stain images into the six most common categories: Gram-negative rods, Gram-positive cocci in chains, Gram-positive cocci in clusters, Gram-positive rods, Gram-negative cocci, and yeasts. The development and testing relied on 1,077 Gram stain images of varying sizes, originating from different laboratories and captured using diverse microscopes at different points in time, resulting in differences in image quality, scaling, color balance, and the presence of artifacts. The dataset was split into 80% training and 20% testing subsets, with the split performed in a stratified manner so that each object group was proportionally represented in both the training and testing sets. Preprocessing involved computer vision techniques to improve contrast and color balance, detect contours and object borders, and implement filtering mechanisms to remove unwanted artifacts. Morphological analysis of shapes was then performed to extract parameters characterizing each contour. Next, human-like classification criteria—based on gradient, morphological features (e.g., shape, size) and spatial arrangement that mimic microbiologists’ visual assessment—were established, achieving around 92% accuracy in image classification without using machine learning (ML) methods. However, any further improvements turned practically impossible, prompting the use of ML methods. Building on pre-obtained features, a random forest ML algorithm was employed to further refine the criteria, with three models trained and tested successively. The first model determined the Gram stain reaction (positive or negative) of each object. The second model classified objects into one of six predefined categories. The third model aggregated individual object classifications to generate an overall classification for each slide, based on the number of objects observed in each category and their occupied area. Overall, the ML solution was significantly more accurate, reaching 99.9% accuracy in classifying the images into one of the aforementioned groups. The algorithm’s limitations include inability to classify mixed cultures, as it primarily focuses on the dominant category. In cases where positive and negative objects coexist, the algorithm tends to prioritize Gram-positive objects. Additionally, the current morphological assessment is insufficient for yeast classification. Addressing these limitations is a crucial avenue for future research to enhance the algorithm’s versatility and accuracy.
Récupéré en direct depuis OpenAlex et désinversé. Les résumés ne sont pas conservés dans cette base de données : les index inversés représentent 8,6 Go des 9,3 Go de texte de la base, et le serveur dispose de 13 Go libres.
Comment cette classification a été obtenuedéplier
Prédiction machine sur la base complète
Imitation des enseignantsNi prévalence calibrée, ni vérité terrain. Validation humaine à venir. Le volet Gemma est une étiquette directe du modèle pour chaque travail de la base, lue sur la notice réduite au titre. Le volet Codex est un classifieur appris des 10 348 étiquettes directes de Codex et calibré sur les taux pondérés de l'échantillon; les champs sans appui suffisant ne portent aucun appel Codex. Le mode candidate est l'union des deux volets; le consensus est leur intersection. Ces sorties portent le statut machine_predicted_unvalidated et ne sont pas des étiquettes humaines.
Scores du classifieur distillé par catégorie (deux têtes)
| Catégorie | Codex | Gemma |
|---|---|---|
| Métarecherche | 0,002 | 0,005 |
| Méta-épidémiologie (sens strict) | 0,001 | 0,000 |
| Méta-épidémiologie (sens large) | 0,001 | 0,001 |
| Bibliométrie | 0,002 | 0,001 |
| Études des sciences et des technologies | 0,001 | 0,001 |
| Communication savante | 0,002 | 0,001 |
| Science ouverte | 0,002 | 0,001 |
| Intégrité de la recherche | 0,001 | 0,002 |
| Charge utile insuffisante (le modèle a refusé de juger) | 0,004 | 0,003 |
Scores machine (provisoires)
Les deux têtes enseignantes du modèle étudiant, lues sur ce travail. Un score ordonne la base pour la relecture; il n'affirme jamais une catégorie, et le statut de validation accompagne chaque rangée tel quel.
Scores de référence d'un modèle non mature (critères de maturité non atteints, 7 itérations). Un score ordonne; il n'affirme jamais une catégorie.
score_only:v0-immature-baseline · tel quel depuis la passe de notation : score_only signifie que le nombre peut ordonner les travaux, et qu'aucune étiquette de catégorie n'en découleClassification
machine, non validéePrédiction automatique; un appel candidat d’une seule source (Gemma direct ou Codex distillé), pas un consensus.
Le détail, modèle par modèle et score par score, se trouve en fin de page sous « Comment cette classification a été obtenue ».