KidneyNet-V: Automated Kidney Stone Detection in CT Scans Using a Customized MobileNetV2 Model

Page 1


International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 12 Issue: 01 | Jan 2025 www.irjet.net p-ISSN: 2395-0072

KidneyNet-V: Automated Kidney Stone Detection in CT Scans Using a Customized MobileNetV2 Model

1B. Tech Student, Dept. of Computer Science and Engineering (Data Science), Institute of Aeronautical Engineering, Telangana, India

2B. Tech Student, Dept. of Computer Science and Engineering (Data Science), Institute of Aeronautical Engineering, Telangana, India

3AssociateProfessor&DeputyHead,Dept.of Computer Science and Engineering (Data Science), Institute of Aeronautical Engineering, Telangana, India ***

Abstract - Kidney stones represent a significant health concern,leadingtonumeroushospitalizationsandseverepain. Timely diagnosis is vital for proper treatment and to avoid complications like kidney failure. This paper presents KidneyNet-V,astreamlinedandeffectivedeeplearningmodel based on a customized MobileNetV2 architecture, aimed at automatically detecting kidney stones from CT scans. This model was developed using a dataset which consists of 1799 CTimages,dividedintotwocategories:thosewithandwithout kidney stones. Our approach incorporates advanced techniquessuchasglobalaveragepooling,dropoutlayers,and data augmentation, which enhance This model's robustness andefficiency.TheevaluationmetricsrevealthatKidneyNet-V achieves an accuracy of 99.71%, with exceptional precision, recall, and F1 scores, demonstrating its effectiveness in diagnosingkidneystones.Inaddition,comparisonswithother deep learning models highlight KidneyNet-V's enhanced accuracy and efficiency, as well as its lower computational demands.Auser-friendlywebapplication,builtwithStreamlit, enables healthcare professionals to upload CT images and receive instantaneous predictions, thereby enhancing the speed of diagnosis. This work illustrates the potential of KidneyNet-V as a valuable tool in medical decision support systems, paving the way for future innovations in automated healthcare solutions.

Key Words: Kidney stones, Deep learning, KidneyNet-V, MobileNetV2, CT scans, Data augmentation, Medical decision support, Automated diagnosis, Healthcare solutions, Efficient, Automated, Streamlit

1.INTRODUCTION

Kidneystonesareaprevalenturologicalconditionthataffect millionsofindividualsworldwide,oftenresultinginsevere pain, hospitalizations, and long-term complications like chronickidneydiseaseorrenalfailure.Earlydetectionand diagnosis are vital to preventing these outcomes and ensuring timely treatment. Traditionally, CT scans are considered the gold standard in the detection of kidney stones because of their high sensitivity and ability to visualize the size, shape, and location of stones. Manual

interpretation of CT scans is slow, error-prone, and operator-dependentonradiologists'experience.Toaddress theselimitations,artificialintelligence(AI)hasemergedasa promising solution in the field of medical imaging. Deep learning models, in particular, have demonstrated remarkable success in automating the analysis of medical images,improvingbothdiagnosticspeedandaccuracy.Yet, thewidespreadadoptionofAI-baseddiagnosticsystemsis often hindered by the complexity and computational demandsofmanyexisting models. Thesemodelstypically requirelargedatasets,extensivecomputationalresources, andconsiderableprocessingtime,makingthemdifficultto implement in real-time diagnostic settings or resourceconstrainedenvironments.

Fig -1: Flowchartillustratingtheprojectworkflowfor kidneystonedetection.

This paper introduces KidneyNet-V, an optimized deep learning model tailored for the automated kidney stone identificationfromCTimages.Thismodelisbothefficient and lightweight, ensuring effective performance without

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 12 Issue: 01 | Jan 2025 www.irjet.net p-ISSN: 2395-0072

high computational demands. Leveraging the strengths of theMobileNetV2architecture,wedevelopedacustomized solutionthatbalancesaccuracywithreducedcomputational complexity.Thismodelhasbeentrainedandvalidatedona dataset consisting of 1,799 CT images, which helped achieving impressive results with an accuracy of 99.71%, alongwithhighprecision,recall,andF1scores.KidneyNet-V isintegratedintoauser-friendlywebapplication,providing healthcareprofessionalswithanaccessibletoolforreal-time kidneystonedetectionanddiagnosis.

2. METHODOLOGY

2. 1 Data Preprocessing

The dataset comprises CT scan images of kidneys, categorized based on the presence or absence of kidney stones. To ensure consistency in model training, preprocessing techniques such as image resizing, normalization,andaugmentationwereapplied.Theimages were resized to a standard dimension suitable for deep learningmodels,andnormalizationensuredthatpixelvalues remained within an optimal range. Data augmentation techniques were selectively used to enhance model generalizationandpreventoverfitting.

2. 2 Model Selection and Training

To achieve a balance between accuracy and computational efficiency, MobileNetV2 was chosen as the base model. The classifier was modified to suit the binary classificationtask,incorporatingregularizationtechniquesto enhance model stability. A custom training strategy was employed,usinganadaptivelearningratepolicytoimprove convergence. The dataset was split into training and validationsets, with the model trainedusingan optimized learningcyclewhilemonitoringkeyperformancemetrics.

2. 3 Implementation and Optimization

The model was trained using a structured training approach that included early stopping mechanisms to preventoverfitting.Thesystemwasfurtheroptimizedusinga fine-tuningprocess,ensuringthatthemodelcouldeffectively learndomain-specificfeaturesfromCTscanimages.Thefinal trainedmodelwastestedonunseendatatoevaluateitsrealworldperformance.

2. 4 Deployment and Application

To make the detection system user-friendly and accessible, the trained model was deployed using a lightweight interactive web interface. The interface allows users to upload CT scan images, and the model processes them to provide an immediate classification result. The system includes a probability-based confidence score to supportdecision-making.Thedeploymentensuresthatusers, including medical professionals, can utilize the system withoutneedingspecializedtechnicalexpertise.

Fig -2: CTscansdisplayingkidneyswiththepresenceof kidneystones
Fig -3: CTscansdisplayingkidneyswiththeabsence ofkidneystones

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 12 Issue: 01 | Jan 2025 www.irjet.net p-ISSN: 2395-0072

3. IMPLEMENTATION

3. 1 Model Architecture

The core of the kidney stone detection system is built uponMobileNetV2,alightweightdeeplearningarchitecture thatisefficientandwell-suitedformobileandedgedevice applications. The original MobileNetV2 architecture was modified to suit the specific task of binary classification (presencevs.absenceofkidneystones).Theclassification head of the pre-trained model was removed and replaced with a custom classifier consisting of a dropout layer for regularizationandafullyconnectedlayerwithtwooutput neurons.Thedropoutlayerhelpsinpreventingoverfitting byrandomlysettingsomeofthelayer'sinputunitstozero duringtraining,encouragingthemodeltogeneralizebetter. Thisarchitectureensureshighaccuracywhilemaintaining efficiency.

3. 2 Data Processing and Augmentation

The dataset used for training contains CT scan images labeled according to the presence of kidney stones. These imageswerepreprocessedandaugmentedtoensurethatthe modelcouldgeneralizewellacrossvariousunseendata.The preprocessing steps involved resizing images to 224x224 pixels, which is the required input size for MobileNetV2. Normalizationwasappliedtoscalepixelvaluestoarange suitable for training deep learning models. Data augmentation techniques, such as random rotations, flips, and contrast adjustments, were used to increase the diversity of the dataset, which helps the model perform betterunderreal-worldconditionswhereimagesmayvary inorientation,brightness,andnoise.

3. 3 Training Process

The model was trained using the FastAI library, which simplifiestheimplementationofdeeplearningmodels.The training process began by loading the dataset using ImageDataLoaders from the FastAI library, which automaticallysplitsthedataintotrainingandvalidationsets. The model was trained for 10 epochs using the one-cycle learningratepolicy,whichdynamicallyadjuststhelearning rate during training to ensure optimal performance. The EarlyStoppingCallbackwasemployedtohalttrainingifthe validation loss did not improve for 3 consecutive epochs, helpingavoidoverfitting.Aftertraining,themodelachieved high accuracy on the validation set, making it ready for deployment.

3. 4 Model Evaluation and Testing

After training, the model was evaluated using various performancemetrics,suchasaccuracyandconfusionmatrix, toensureitwasgeneralizingwelltounseendata.Themodel wastestedonaseparatetestdataset,andtheaccuracyscore wasfoundtobeabove90%,indicatingthemodel'sreliability

indetectingkidneystones.Theconfusionmatrixhelpedto visualizethe true positives, falsepositives, true negatives, and false negatives, providing further insights into model performance.

3. 5 Deployment using Streamlit

To make the system accessible to users, the trained model was deployed using Streamlit, a Python-based framework that allows the creation of interactive web applications. Streamlit enables users to upload CT scan images via a user-friendly interface. Upon uploading an image,thesystempre-processestheimageandfeedsitinto the trained model for prediction. The model classifies the imageaseithercontainingkidneystonesorbeingstone-free andoutputstheclassificationalongwithaprobabilityscore indicatingtheconfidenceleveloftheprediction.

Streamlitallowstheapptobeeasilydeployedonaweb serverforremoteaccess,enablingmedicalprofessionalsor usersinvariouslocationstoaccessthemodel’scapabilities. The user interface is designed to be simple and intuitive, providingimmediatefeedbackonthepresenceorabsenceof kidney stones based on the uploaded CT scan image. This ensuresthatthesystemisaccessibletobothtechnicaland non-technicalusers.

Fig -4: User-friendlywebpageinterfaceforKidneyNet-V, allowinghealthcareprofessionalstouploadCTimagesand receiveinstantpredictionsforkidneystonedetection.

4. RESULTS

4. 1 Model Performance Metrices

KidneyNet-V's performance was assessed through several evaluation metrics, each emphasizing its effectiveness in detecting kidney stones. This model achievedaremarkableaccuracyof99.71%,showcasingits precise classification capabilities for CT images. It also performed very well in terms of precision, recall, and F1 scores,withallthemetricsreflecting99.71%.Theseresults emphasizethemodel'sdependabilityand efficiencyinthe identificationofkidneystones,henceitisaveryusefultool in clinical applications. This strong performance supports the model's potential to aid healthcare professionals in

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 12 Issue: 01 | Jan 2025 www.irjet.net p-ISSN: 2395-0072

early-stagediagnoses,whichcouldleadtoimprovedpatient outcomesthroughtimelyintervention.

4. 2 Confusion Matrix Analysis

The confusion matrix created from the test outcomes offeredimportantinsightsofthismodel’sabilitytoclassify data. It detailed the rates of false positives (FP), false negatives(FN),truepositives(TP),andtruenegatives(TN).

The analysis indicated that KidneyNet-V accurately identifiedthevastmajorityofkidneystonecases,withvery few misclassifications. This high level of accuracy in differentiating between the two categories reinforces the model's robustness and highlights its potential to aid healthcare professionals in making precise kidney stone diagnoses.

5. CONCLUSIONS

TheKidneyNet-Vprojecthassuccessfullydemonstratedthe effectivenessofusingacustomizedMobileNetV2modelfor kidneystonedetectionfromCTscans.Thismodelachieveda remarkable accuracy of 99.71%, along with equally impressive metrics for Recall, Precision, and F1 score, underscoring its potential as a reliable diagnostic tool. Throughtheincorporationofadvancedtechniquessuchas global average pooling and dropout layers, the model not only improved its performance but also preserved computationalefficiency,whichisappropriateforreal-time applications in clinical settings. Furthermore, the development of a user-friendly web application has

enhancedtheaccessibilityofthistechnologyforhealthcare professionals,enablingthemtoquicklyuploadimagesand receivetimelypredictions.Thepositivefeedbackreceived frominitialusersindicatesthepracticalvalueofintegrating AI solutions in medical diagnostics, paving the way for improved patient care. In conclusion, KidneyNet-V representsasignificantstepforwardinautomatedkidney stone detection, providing a valuable tool for healthcare professionals.Futureworkcouldfocusonincreasingthesize ofthedataset,exploringotherdeeplearningarchitectures, andfurtherrefiningthemodeltoenhanceitsperformance and applicability. This project not only highlights the capabilities of deep learning in medical imaging but also emphasizestheimportanceofcontinuedinnovationinthe fieldofautomatedhealthcaresolutions.

REFERENCES

[1] Kilic,Ugur,Karabey Aksakalli,Isil,Tumuklu Ozyer,Gulsah,Aksakalli,Tugay,Ozyer,Baris,Adanur,Se nol,Exploring the Effect of Image Enhancement Techniques with Deep Neural Networks on Direct Urinary System X-Ray (DUSX) Images for Automated Kidney Stone Detection, International Journal of Intelligent Systems,2023, 3801485, 17 pages,2023.https://doi.org/10.1155/2023/3801485

[2] Ravisankar,Priyadharsini,etal."DeepLearning-Based Renal Stone Detection: A Comprehensive Study and PerformanceAnalysis"AppliedComputerSystems,vol. 29,no.1,RigaTechnicalUniversity,2024,pp.112-116. https://doi.org/10.2478/acss-2024-0014

[3] Sohaib Asif, Xiaolong Zheng, Yusen Zhu, An optimized fusion of deep learning models for kidney stone detection from CT images, Journal of King Saud University - Computer and Information Sciences, Volume 36, Issue 7, 2024, 102130, ISSN 1319-1578, https://doi.org/10.1016/j.jksuci.2024.102130

[4] Songhua,Xu&Aslam,MuhammadUsman&WaqasCh, Muhammad&Hussain,Shahid.(2024).QuantumDeep Learning for Automatic Chronic Kidney Disease Identification and Classification with CT images. 10.21203/rs.3.rs-4743771/v1.

Fig -5: OutputfromtheKidneyNet-Vmodelshowcasing thepredictionresults,indicatingtheabsenceorthe presenceofkidneystonesintheuploadedCTscan.

Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.