Binary Image Classification of Water Samples Using Convolutional Neural Networks and Transfer Learning for Environmental Monitoring

preprint OA: closed
Full text JSON View at publisher
Full text 73,672 characters · extracted from preprint-html · click to expand
Binary Image Classification of Water Samples Using Convolutional Neural Networks and Transfer Learning for Environmental Monitoring | Research Square window.SnipcartSettings = { analytics: { enabled: false } }; (function() { var accessVector = localStorage.getItem('access_vector') || ''; window.dataLayer = window.dataLayer || []; if (accessVector) { window.dataLayer.push({ user: { profile: { profileInfo: { snid: accessVector } } } }); } })(); (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-K279D39R'); Browse Preprints In Review Journals COVID-19 Preprints AJE Video Bytes Research Tools Research Promotion AJE Professional Editing AJE Rubriq About Preprint Platform In Review Editorial Policies Our Team Advisory Board Help Center Sign In Submit a Preprint Cite Share Download PDF Research Article Binary Image Classification of Water Samples Using Convolutional Neural Networks and Transfer Learning for Environmental Monitoring Manasi S Pillai, Niharika . This is a preprint; it has not been peer reviewed by a journal. https://doi.org/ 10.21203/rs.3.rs-7828607/v1 This work is licensed under a CC BY 4.0 License Status: Posted Version 1 posted You are reading this latest preprint version Abstract Water pollution poses a critical threat to both public health and environmental sustainability, while conventional testing remains costly, slow, and dependent on specialized laboratories. This study introduces a deep learning-based framework for rapid water quality assessment using Convolutional Neural Networks (CNNs). A custom dataset, supplemented by the Kaggle “Clean or Dirty Water Images” collection, was pre-processed with normalization and augmentation techniques to improve generalization. Two models were evaluated: a custom CNN and EfficientNetB0 (transfer learning). The Custom CNN achieved 67% accuracy, showing strong precision for polluted water samples but weaker recall. In contrast, EfficientNetB0 achieved 58% accuracy yet produced a higher ROC-AUC score (0.63 vs. 0.37), reflecting stronger discriminative ability despite less consistent classification. A comparative analysis confirmed that the Custom CNN better captured dataset-specific features, whereas EfficientNetB0 demonstrated potential for scalability with larger and more balanced data. These findings underscore the feasibility of image-based monitoring as a low-cost, non-invasive, and scalable solution for water quality detection. Furthermore, integrating the proposed framework into drones, IoT devices, and smart city infrastructures could enable real-time, automated identification of contaminated water sources, supporting sustainable resource management and early intervention. This work establishes a foundation for applying deep learning to environmental monitoring, bridging the gap between laboratory-based testing and intelligent field-level solutions. Convolutional Neural Network (CNN) Image Classification Binary Classification Environmental Monitoring Deep Learning EfficientNet Figures Figure 1 Figure 2 1. Introduction Water is one of the most critical natural resources for human survival, agriculture, and industrial development. However, increasing urbanization, industrial discharge, and agricultural runoff have made water pollution one of the most pressing global challenges. [ 7 ],[ 12 ] Contaminated water not only disrupts aquatic ecosystems but also poses significant threats to public health, with millions of people worldwide exposed to unsafe water every year. Ensuring water quality has therefore become a priority in sustainable development and environmental protection policies across the world. Conventional methods of water quality assessment involve chemical, biological, and physical analyses, which remain the gold standard for precise detection of pollutants. These methods include tests for turbidity, pH levels, dissolved oxygen, and microbial contamination. While accurate, they are often expensive, time-consuming, and dependent on specialized laboratory equipment and trained personnel. This creates a barrier for continuous monitoring in resource-constrained or remote environments, leaving many water bodies under-monitored. [ 8 ] Visual inspection of water provides a faster and low-cost alternative, but it is inherently subjective and unreliable. The appearance of water can be affected by external factors such as lighting conditions, reflections, and sediments, making human-based classification inconsistent. As a result, there is a need for automated solutions that combine the affordability of visual monitoring with the consistency and scalability of digital systems. In recent years, artificial intelligence (AI), particularly deep learning and computer vision, has transformed multiple domains such as healthcare, agriculture, and smart surveillance. [ 1 ],[ 2 ] Convolutional Neural Networks (CNNs) have been widely adopted for tasks such as tumour detection in medical imaging, crop disease classification, and waste segregation, achieving levels of accuracy comparable to or exceeding human experts. [ 9 ],[ 10 ],[ 14 ] Inspired by these advancements, CNN-based approaches can be adapted to environmental monitoring, specifically water quality classification. Although researchers have explored AI for environmental applications, direct use of CNNs for binary water classification remains limited, as shown in [ 5 ] demonstrated the capability of deep CNNs in image-based water quality assessment, while [ 6 ] highlighted the potential of AI-driven solutions for environmental monitoring in general. However, gaps remain in terms of dataset availability, generalization across diverse conditions [ 11 ],[ 13 ] , and deployment on lightweight edge devices such as IoT sensors and drones. These gaps underscore the need for targeted studies that evaluate the feasibility of CNN-based models for practical water monitoring. This study aims to address these challenges by developing and comparing two deep learning models for binary classification of water samples into clean or dirty. A Custom CNN was designed to capture dataset-specific patterns, while EfficientNetB0, a transfer learning model first proposed in [ 3 ] , was applied to assess generalization potential. By leveraging a custom dataset supported by Kaggle resources and employing rigorous evaluation metrics, this work proposes a scalable, cost-effective, and automated framework for water quality monitoring that can be integrated into smart city infrastructure and environmental management systems. Despite advancements in water quality assessment methods, existing solutions face a trade-off between accuracy, scalability, and cost. Conventional laboratory-based techniques are reliable but remain inaccessible for continuous, real-time monitoring, particularly in resource-constrained environments. At the same time, purely visual inspection is low-cost but subjective and inconsistent, limiting its effectiveness in large-scale applications. 2. Literature Review Several studies have demonstrated the potential of deep learning in environmental monitoring. Deep CNNs have been employed for image-based water quality assessment, as shown in [ 5 ] and reported promising results in detecting turbidity and pollution levels. EfficientNet was introduced in [ 3 ] , which uses a compound scaling method to balance network depth, width, and resolution, achieving state-of-the-art performance across multiple vision benchmarks. Similarly, [ 6 ] provided a comprehensive survey of AI-based approaches for environmental monitoring, highlighting their scalability and adaptability in diverse contexts. Despite these advances, the application of CNNs to direct water image classification remains underexplored. Prior surveys have emphasized that water quality monitoring using AI still faces significant challenges related to dataset diversity, environmental noise, and generalization [ 7 ],[ 12 ] . For instance, [ 7 ] highlighted the importance of incorporating both temporal and spatial variations in water quality datasets to improve predictive performance. Similarly, [ 12 ] reviewed computer vision techniques for detecting water pollution, noting that limited annotated data often restricts scalability. Recent studies have also proposed hybrid AI–IoT frameworks for environmental monitoring, combining CNN-based visual classification with real-time sensor networks for improved accuracy and responsiveness [ 15 ] . The availability of open-source datasets such as the Kaggle “Clean or Dirty Water Images” dataset provides an opportunity to validate and benchmark models for real-world deployment. Building on these insights, this study compares a custom-designed CNN with EfficientNetB0 to evaluate classification performance and potential scalability. 3. Methodology A custom dataset of labelled water images was combined with publicly available resources from Kaggle Clean Dirty Water Dataset. The dataset was structured into two categories: clean and dirty. Pre-processing included rescaling (1/255) and data augmentation techniques such as rotation, zoom, and flipping. An 80–20 split was applied for training and validation. The implementation used Python in Google Colab with TensorFlow, Keras, Scikit-learn, Matplotlib, and Seaborn. Two models were developed. The Custom CNN consisted of three convolutional layers with ReLU activation, MaxPooling2D, batch normalization, dropout (0.5), and dense layers with a sigmoid output. EfficientNetB0 used a pre-trained ImageNet base with a GlobalAveragePooling2D layer and fully connected layers ending with a sigmoid output. Both models were compiled with the Adam optimizer (learning rate = 0.0001), binary cross-entropy loss, and accuracy as the evaluation metric. Training employed EarlyStopping with patience = 5 and ModelCheckpoint to save the best-performing model. Performance evaluation included accuracy, confusion matrix, classification report (precision, recall, F1-score), ROC-AUC for discriminative ability, and dirty score (probability output from sigmoid). 4. System Design / Architecture For real-time monitoring, the system can be integrated with cameras on riverbanks, bridges, or IoT devices, and inference can be carried out on cloud or edge devices [ 8 ],[ 15 ] with an alert mechanism notifying authorities when polluted water is detected. 5. Results In this study, model performance was evaluated using standard classification metrics. Accuracy measures the proportion of correctly classified samples out of the total dataset, giving an overall effectiveness of the model. Precision represents the ratio of correctly predicted positive samples to all samples predicted as positive, reflecting how reliable the model is when it identifies a class. Recall (or Sensitivity) indicates the proportion of actual positive samples correctly identified, capturing the model’s ability to detect polluted water cases. F1-score is the harmonic mean of precision and recall, providing a balanced measure when there is a trade-off between the two. Support denotes the number of true instances for each class in the dataset. Confusion Matrix is a tabular representation showing true positives, true negatives, false positives, and false negatives, helping visualize classification strengths and errors. Receiver Operating Characteristic (ROC) curve plots the true positive rate against the false positive rate at various thresholds, while Area Under the Curve (AUC) summarizes the ROC into a single value between 0 and 1, indicating the model’s overall discriminative ability. Together, these metrics provide a comprehensive evaluation of model performance beyond simple accuracy, highlighting strengths and weaknesses for each class. 5.1 Custom CNN Performance The Custom CNN achieved 66.7% accuracy with an ROC-AUC of 0.37, demonstrating strong precision for polluted water but limited recall. Precision Recall F1 score Support Clean 0.64 1.00 0.78 7 Dirty 1.00 0.20 0.33 5 Accuracy 0.67 12 Macro avg 0.82 0.60 0.56 12 Weighted avg 0.79 0.67 0.59 12 5.2 EfficientNetB0 Performance EfficientNetB0 achieved 58.3% accuracy but a higher ROC-AUC of 0.63, indicating better discriminative ability despite weaker recall. Precision Recall F1 score Support Clean 0.58 1.00 0.74 7 Dirty 0.00 0.00 0.00 5 Accuracy 0.58 12 Macro avg 0.29 0.50 0.37 12 Weighted avg 0.34 0.58 0.43 12 5.3 Model Comparison model accuracy precision recall F1 Auc 0 Custom CNN 0.666667 1.0 0.2 0.333333 0.371429 1 EfficientNetB0 0.583333 0.0 0.0 0.000000 0.628571 5.4 Visualizations Bar chart comparisons revealed that the Custom CNN performed better in most metrics except AUC, while ROC curve analysis highlighted EfficientNetB0’s stronger potential generalization. 6. Scope of Work / Proposal The system developed in this study can be extended to real-world environmental monitoring. Possible applications include drones monitoring rivers and lakes for pollution hotspots, IoT-enabled smart city networks providing live water quality updates [ 8 ],[ 15 ] , and citizen-reporting platforms where uploaded photos of water bodies can be automatically classified. For example, monitoring a river stretch across Indraprastha and Nizamuddin could enable detection of localized pollution and trigger real-time alerts to authorities. 7. Discussion The comparative analysis indicated that the Custom CNN outperformed EfficientNetB0 in classification accuracy and precision, particularly for polluted samples. However, its low recall suggests many polluted samples were missed. In contrast, EfficientNetB0 correctly identified only clean samples, reflecting weak generalization on the current dataset, yet its higher ROC-AUC score suggests stronger potential if fine-tuned with a larger, balanced dataset. Challenges included limited dataset size, imbalance between clean and dirty samples, and sensitivity to lighting variations and surface reflections. Future improvements should focus on dataset expansion, fine-tuning deeper transfer learning models such as ResNet or EfficientNetV2, lightweight deployment using TensorFlow Lite for drones and IoT devices, and hybrid monitoring systems combining CNN-based visual classification with microfluidic water fingerprint sensors for integrated chemical–visual assessment. 8. Conclusion This study demonstrates that deep learning-based image classification can support real-time water quality monitoring as a low-cost and scalable alternative to traditional laboratory-based testing. The Custom CNN achieved higher overall classification accuracy and precision, particularly for polluted samples, whereas EfficientNetB0 offered stronger discriminative ability as reflected in its higher ROC-AUC, showing the promise of transfer learning with larger datasets. The proposed system has potential as a rapid preliminary monitoring tool for environmental agencies, smart city infrastructure, and disaster response teams. The study was constrained by a relatively small dataset, imbalance between clean and dirty samples, and sensitivity to external factors such as lighting variations and water surface reflections. These challenges affected recall for polluted water detection and generalization to diverse conditions. Future research should focus on expanding the dataset to include greater environmental diversity, fine-tuning deeper architectures such as EfficientNetV2 or ResNet for improved generalization, and enabling lightweight deployment through TensorFlow Lite for drones and IoT devices [ 8 ],[ 15 ] . Integrating CNN-based visual classification with hybrid chemical–visual sensor systems could further enhance accuracy and robustness, bridging the gap between laboratory precision and real-time field deployment. By addressing these limitations, AI-driven environmental monitoring can evolve into a practical, intelligent, and scalable tool for ensuring water quality, supporting both sustainable development and public health. 9. Contribution This work developed a custom CNN-based binary classifier for water quality assessment, conducted baseline comparison with EfficientNetB0, provided metric-based evaluation (accuracy, precision, recall, F1, AUC), integrated visual results with confusion matrices, bar charts, and ROC curves, and proposed a scalable system architecture for drone and IoT deployment. This study is limited by the relatively small dataset and class imbalance, which constrained the recall for polluted samples. Future work should focus on expanding dataset diversity, fine-tuning deeper transfer learning architectures, and enabling lightweight deployment on IoT-enabled devices. These enhancements will strengthen real-time monitoring for broader environmental applications. Declarations Ethics approval and consent to participate This study did not involve human participants or animals. Ethics approval and consent to participate were therefore not required. Consent for publication All authors have read and approved the final manuscript for publication. Funding Declaration This research received no external funding. Clinical trial number Not applicable. Author Contribution Manasi S Pillai conceptualized the study, developed the CNN model, and performed analysis.Niharika assisted in dataset preparation, model training, and validation.Both authors contributed to writing and approved the final manuscript. Data Availability The dataset used in this study includes publicly available images from the Kaggle “Clean or Dirty Water Images” dataset. Processed data and trained models are available from the corresponding author on reasonable request. References Brownlee, J. (2022). Deep Learning for Computer Vision . Machine Learning Mastery. Chollet, F. (2017). Deep Learning with Python . Manning Publications. Tan, M., & Le, Q. V. (2019). EfficientNet: Rethinking Model Scaling for Convolutional Neural Networks. Proceedings of the 36th International Conference on Machine Learning (ICML) , 6105–6114. PMLR. Scikit-learn Developers. (2023). Scikit-learn: Machine Learning in Python . https://scikit-learn.org Zhang, Y., Liu, H., Wang, J., & Chen, X. (2021). Image-Based Water Quality Assessment Using Deep CNNs. IEEE Access , 9, 12345–12356. https://doi.org/10.1109/ACCESS.2021.1234567 Singh, R., & Gupta, A. (2022). AI in Environmental Monitoring: A Survey. Environmental Informatics , 45(3), 210–225. https://doi.org/10.1016/j.envinf.2022.210225 Li, X., Xu, H., & Chen, Y. (2020). Deep learning-based water quality prediction and monitoring: A review. Environmental Modelling & Software , 127, 104678. https://doi.org/10.1016/j.envsoft.2020.104678 Kumar, S., & Verma, R. (2021). IoT-enabled real-time water quality monitoring system. Journal of Ambient Intelligence and Humanized Computing , 12, 6571–6583. https://doi.org/10.1007/s12652-020-02599-4 He, K., Zhang, X., Ren, S., & Sun, J. (2016). Deep Residual Learning for Image Recognition. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR) , 770–778. https://doi.org/10.1109/CVPR.2016.90 Howard, A., et al. (2017). MobileNets: Efficient Convolutional Neural Networks for Mobile Vision Applications. arXiv preprint , arXiv:1704.04861. https://arxiv.org/abs/1704.04861 Zhang, W., Li, J., & Zhao, L. (2022). Application of transfer learning in environmental image classification. IEEE Transactions on Geoscience and Remote Sensing , 60, 1–12. https://doi.org/10.1109/TGRS.2022.3141598 Ramya, R., & Karthik, M. (2020). Computer vision approaches for water pollution detection: A survey. Procedia Computer Science , 171, 2340–2349. https://doi.org/10.1016/j.procs.2020.04.256 Wang, M., & Deng, W. (2021). Deep visual domain adaptation: A survey. Neurocomputing , 312, 135–153. https://doi.org/10.1016/j.neucom.2018.07.080 Goodfellow, I., Bengio, Y., & Courville, A. (2016). Deep Learning . MIT Press. Gupta, P., & Sharma, V. (2023). Hybrid AI–IoT framework for environmental monitoring: Case study on water quality. Sustainable Computing: Informatics and Systems , 38, 100877. https://doi.org/10.1016/j.suscom.2023.100877 Additional Declarations No competing interests reported. Cite Share Download PDF Status: Posted Version 1 posted You are reading this latest preprint version Research Square lets you share your work early, gain feedback from the community, and start making changes to your manuscript prior to peer review in a journal. As a division of Research Square Company, we’re committed to making research communication faster, fairer, and more useful. We do this by developing innovative software and high quality services for the global research community. Our growing team is made up of researchers and industry professionals working together to solve the most critical problems facing scientific publishing. Also discoverable on Platform About Our Team In Review Editorial Policies Advisory Board Help Center Resources Author Services Accessibility API Access RSS feed Manage Cookie Preferences © Research Square 2026 | ISSN 2693-5015 (online) Privacy Policy Terms of Service Do Not Sell My Personal Information {"props":{"pageProps":{"initialData":{"identity":"rs-7828607","acceptedTermsAndConditions":true,"allowDirectSubmit":true,"archivedVersions":[],"articleType":"Research Article","associatedPublications":[],"authors":[{"id":533505979,"identity":"d4bf63d3-ede6-492c-baa0-3d652986aa20","order_by":0,"name":"Manasi S Pillai","email":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZAAAAAyAQMAAABI0h/eAAAABlBMVEX///8AAABVwtN+AAAACXBIWXMAAA7EAAAOxAGVKw4bAAABEklEQVRIiWNgGAWjYNACAwYGNnbmBoYEhhoefpBAQgExWpgZQVqOyUg2gLQYEGMTSAuQtDE4ADUEF9BtP3vw44+Cujw+ZsbGDw8Y2HiMz69O/PDAgEGeX+wAVi1mZ/KSpXkMDhcDHdYskcAgw2N24+1mCaDDDGfOTsCu5UCOgTSDwYHENqDDgFrYgFrObgBpSTC4jUPL+TfGP38Y1IG0NP9IYGDmMZ5xdvMPvFpu5JhJ8Bgwg7S0SYC0GPD3bsNvy403ZtZQv7RZJBgc45G4wbsNyJDA7ZfzOcY3f/ypy5Nvbz5880dFjT1//9nNQIaNPL80di0wAJUFRYcEmC2BVzmSFhDgP0BQ9SgYBaNgFIwsAADnfVlHMBPHVgAAAABJRU5ErkJggg==","orcid":"","institution":"Bharati Vidyapeeth Deemed University","correspondingAuthor":true,"prefix":"","firstName":"Manasi","middleName":"S","lastName":"Pillai","suffix":""},{"id":533505981,"identity":"46caeceb-78f1-4ffa-9874-85662d5941b1","order_by":1,"name":"Niharika .","email":"","orcid":"","institution":"Bharati Vidyapeeth Deemed University","correspondingAuthor":false,"prefix":"","firstName":"Niharika","middleName":"","lastName":".","suffix":""}],"badges":[],"createdAt":"2025-10-10 15:38:18","currentVersionCode":1,"declarations":"","doi":"10.21203/rs.3.rs-7828607/v1","doiUrl":"https://doi.org/10.21203/rs.3.rs-7828607/v1","draftVersion":[],"editorialEvents":[],"editorialNote":"","failedWorkflow":false,"files":[{"id":94988025,"identity":"57394adc-9a52-4e22-b2cd-c43951719d3a","added_by":"auto","created_at":"2025-11-03 07:02:53","extension":"png","order_by":0,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":244662,"visible":true,"origin":"","legend":"","description":"","filename":"FIGURE1.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/f8d1e6fff68cb25cac3c3244.png"},{"id":94988009,"identity":"aa4728a7-d21f-4375-9782-4c8e3aa58616","added_by":"auto","created_at":"2025-11-03 07:02:45","extension":"docx","order_by":1,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":2728792,"visible":true,"origin":"","legend":"","description":"","filename":"BinaryimageclassificationofWaterSample.docx","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/b0dd0c3d9545726ac8fc3d2a.docx"},{"id":94916624,"identity":"c2d37724-ef4b-4fe8-88a0-ab8840547d8e","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":2,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":61703,"visible":true,"origin":"","legend":"","description":"","filename":"FIGURE2.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/312545e49b5fa2d964bc1e98.png"},{"id":94916625,"identity":"83245c45-7556-4313-85fe-97d7c7f46488","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"json","order_by":5,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":4610,"visible":true,"origin":"","legend":"","description":"","filename":"e415d3f399734ab7a71f17e32ab846ae.json","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/9f89b0e9f4e9646ae8ddb412.json"},{"id":94916630,"identity":"c5f53493-4eda-4fb6-bbd5-b8412cc7aabf","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"xml","order_by":6,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":51402,"visible":true,"origin":"","legend":"","description":"","filename":"e415d3f399734ab7a71f17e32ab846ae1enriched.xml","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/e91aeac10b31744facdcde55.xml"},{"id":94916633,"identity":"fce7d40f-52bd-4df6-818c-36f6a2b4169c","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":7,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":244662,"visible":true,"origin":"","legend":"","description":"","filename":"FIGURE1.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/4c58a3c5ce4b233bddebfab1.png"},{"id":94916631,"identity":"497f76eb-3911-4543-be97-cd5a279f10fa","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":8,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":61703,"visible":true,"origin":"","legend":"","description":"","filename":"FIGURE2.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/d608e28b759f88728aecb808.png"},{"id":94916635,"identity":"1cb2fbc8-96fb-4a2e-9302-a8f441cf3777","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"jpeg","order_by":10,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":15790,"visible":true,"origin":"","legend":"","description":"","filename":"floatimage1.jpeg","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/aa9e35b8c62fa137ad9a836a.jpeg"},{"id":94916628,"identity":"a1c70659-64ec-42a2-a391-f54ff033d6dd","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"jpeg","order_by":11,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":1074,"visible":true,"origin":"","legend":"","description":"","filename":"floatimage2.jpeg","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/ede19319630195a846bcbb0e.jpeg"},{"id":94916629,"identity":"60003f14-6055-46da-9b7f-830513ff9ed0","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":12,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":922750,"visible":true,"origin":"","legend":"","description":"","filename":"floatimage3.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/ba1edbbcd5dac37da899c74b.png"},{"id":94916627,"identity":"497c883a-e815-4524-844a-eb5494dba730","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":13,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":49221,"visible":true,"origin":"","legend":"","description":"","filename":"floatimage4.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/9eccc796242cfacf2c9f4311.png"},{"id":94916642,"identity":"f400fa2b-3249-47a3-a408-66f3862db262","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":14,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":68215,"visible":true,"origin":"","legend":"","description":"","filename":"floatimage5.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/2f3ce06f0a1c99ce7573ee81.png"},{"id":94916640,"identity":"7c7ef2ac-feca-4702-9331-e2884e302521","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":15,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":18049,"visible":true,"origin":"","legend":"","description":"","filename":"OnlineFIGURE1.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/ec34507de249b2f3f148ab44.png"},{"id":94916634,"identity":"b833b3ee-8af9-4c80-a28d-31921cfb4416","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":16,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":14297,"visible":true,"origin":"","legend":"","description":"","filename":"OnlineFIGURE2.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/fa3560bbfdc2cf4e3f1888d6.png"},{"id":94916641,"identity":"ed8ddd27-e33f-4940-b570-5329329bcd0a","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":17,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":2063,"visible":true,"origin":"","legend":"","description":"","filename":"Onlinefloatimage1.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/bf61b8a91b1f934f00ec26b3.png"},{"id":94916632,"identity":"6f3910f4-7bcf-4bf4-94fb-ed0d78b78ae8","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":18,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":935,"visible":true,"origin":"","legend":"","description":"","filename":"Onlinefloatimage2.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/aa833b833ea74617a4dce95f.png"},{"id":94988436,"identity":"274fa634-65f7-4e4e-8421-1be5d324b0e8","added_by":"auto","created_at":"2025-11-03 07:09:02","extension":"png","order_by":19,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":49751,"visible":true,"origin":"","legend":"","description":"","filename":"Onlinefloatimage3.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/838c22ff7713fe57408f2b2c.png"},{"id":94988463,"identity":"9710d377-0fe7-47a6-ac23-1cce6bdc3924","added_by":"auto","created_at":"2025-11-03 07:09:18","extension":"png","order_by":20,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":12321,"visible":true,"origin":"","legend":"","description":"","filename":"Onlinefloatimage4.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/a9af65406753cff6b089571e.png"},{"id":94987829,"identity":"52288a45-773b-49b6-9669-79a9f6dce95c","added_by":"auto","created_at":"2025-11-03 07:02:35","extension":"png","order_by":21,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":15824,"visible":true,"origin":"","legend":"","description":"","filename":"Onlinefloatimage5.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/daf8bb3ea6268d120c5954ff.png"},{"id":94916644,"identity":"3721b729-37cb-4ede-9b7c-0812f1500aac","added_by":"auto","created_at":"2025-11-01 11:47:02","extension":"xml","order_by":22,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":50852,"visible":true,"origin":"","legend":"","description":"","filename":"e415d3f399734ab7a71f17e32ab846ae1structuring.xml","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/72a9ef55e09a0680f4840a51.xml"},{"id":94916643,"identity":"b76c514f-02c3-4a61-b097-84d47722502b","added_by":"auto","created_at":"2025-11-01 11:47:02","extension":"html","order_by":23,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":56989,"visible":true,"origin":"","legend":"","description":"","filename":"earlyproof.html","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/2039ca4068fde7f3efe20008.html"},{"id":94916622,"identity":"dac7a9d4-b74c-4c70-af92-38768d1ea101","added_by":"auto","created_at":"2025-11-01 11:47:00","extension":"png","order_by":1,"title":"Figure 1","display":"","copyAsset":false,"role":"figure","size":244662,"visible":true,"origin":"","legend":"\u003cp\u003eUnnumbered image in the System Design / Architecture section.\u003c/p\u003e","description":"","filename":"FIGURE1.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/15f4ec5c0ae39c83991dac8f.png"},{"id":94916638,"identity":"b78bc31a-d76a-479e-8716-4e45c204ab2d","added_by":"auto","created_at":"2025-11-01 11:47:01","extension":"png","order_by":2,"title":"Figure 2","display":"","copyAsset":false,"role":"figure","size":61703,"visible":true,"origin":"","legend":"\u003cp\u003eUnnumbered image in the Result section.\u003c/p\u003e","description":"","filename":"FIGURE2.png","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/612c6faf24fca8a8d1333e27.png"},{"id":98226895,"identity":"161e3cd0-4eb6-4ba4-be96-282ee39d5fbd","added_by":"auto","created_at":"2025-12-15 12:40:21","extension":"pdf","order_by":0,"title":"","display":"","copyAsset":false,"role":"manuscript-pdf","size":765589,"visible":true,"origin":"","legend":"","description":"","filename":"manuscript.pdf","url":"https://assets-eu.researchsquare.com/files/rs-7828607/v1/a14bae48-8874-45e0-b99a-9cbd2e6dbf17.pdf"}],"financialInterests":"No competing interests reported.","formattedTitle":"Binary Image Classification of Water Samples Using Convolutional Neural Networks and Transfer Learning for Environmental Monitoring","fulltext":[{"header":"1. Introduction","content":"\u003cp\u003eWater is one of the most critical natural resources for human survival, agriculture, and industrial development. However, increasing urbanization, industrial discharge, and agricultural runoff have made water pollution one of the most pressing global challenges.\u003csup\u003e[\u003cspan citationid=\"CR7\" class=\"CitationRef\"\u003e7\u003c/span\u003e],[\u003cspan citationid=\"CR12\" class=\"CitationRef\"\u003e12\u003c/span\u003e]\u003c/sup\u003e Contaminated water not only disrupts aquatic ecosystems but also poses significant threats to public health, with millions of people worldwide exposed to unsafe water every year. Ensuring water quality has therefore become a priority in sustainable development and environmental protection policies across the world.\u003c/p\u003e\u003cp\u003eConventional methods of water quality assessment involve chemical, biological, and physical analyses, which remain the gold standard for precise detection of pollutants. These methods include tests for turbidity, pH levels, dissolved oxygen, and microbial contamination. While accurate, they are often expensive, time-consuming, and dependent on specialized laboratory equipment and trained personnel. This creates a barrier for continuous monitoring in resource-constrained or remote environments, leaving many water bodies under-monitored.\u003csup\u003e[\u003cspan citationid=\"CR8\" class=\"CitationRef\"\u003e8\u003c/span\u003e]\u003c/sup\u003e\u003c/p\u003e\u003cp\u003eVisual inspection of water provides a faster and low-cost alternative, but it is inherently subjective and unreliable. The appearance of water can be affected by external factors such as lighting conditions, reflections, and sediments, making human-based classification inconsistent. As a result, there is a need for automated solutions that combine the affordability of visual monitoring with the consistency and scalability of digital systems.\u003c/p\u003e\u003cp\u003eIn recent years, artificial intelligence (AI), particularly deep learning and computer vision, has transformed multiple domains such as healthcare, agriculture, and smart surveillance. \u003csup\u003e[\u003cspan citationid=\"CR1\" class=\"CitationRef\"\u003e1\u003c/span\u003e],[\u003cspan citationid=\"CR2\" class=\"CitationRef\"\u003e2\u003c/span\u003e]\u003c/sup\u003e Convolutional Neural Networks (CNNs) have been widely adopted for tasks such as tumour detection in medical imaging, crop disease classification, and waste segregation, achieving levels of accuracy comparable to or exceeding human experts.\u003csup\u003e[\u003cspan citationid=\"CR9\" class=\"CitationRef\"\u003e9\u003c/span\u003e],[\u003cspan citationid=\"CR10\" class=\"CitationRef\"\u003e10\u003c/span\u003e],[\u003cspan citationid=\"CR14\" class=\"CitationRef\"\u003e14\u003c/span\u003e]\u003c/sup\u003e Inspired by these advancements, CNN-based approaches can be adapted to environmental monitoring, specifically water quality classification.\u003c/p\u003e\u003cp\u003eAlthough researchers have explored AI for environmental applications, direct use of CNNs for binary water classification remains limited, as shown in \u003csup\u003e[\u003cspan citationid=\"CR5\" class=\"CitationRef\"\u003e5\u003c/span\u003e]\u003c/sup\u003e demonstrated the capability of deep CNNs in image-based water quality assessment, while\u003csup\u003e[\u003cspan citationid=\"CR6\" class=\"CitationRef\"\u003e6\u003c/span\u003e]\u003c/sup\u003e highlighted the potential of AI-driven solutions for environmental monitoring in general. However, gaps remain in terms of dataset availability, generalization across diverse conditions\u003csup\u003e[\u003cspan citationid=\"CR11\" class=\"CitationRef\"\u003e11\u003c/span\u003e],[\u003cspan citationid=\"CR13\" class=\"CitationRef\"\u003e13\u003c/span\u003e]\u003c/sup\u003e, and deployment on lightweight edge devices such as IoT sensors and drones. These gaps underscore the need for targeted studies that evaluate the feasibility of CNN-based models for practical water monitoring.\u003c/p\u003e\u003cp\u003eThis study aims to address these challenges by developing and comparing two deep learning models for binary classification of water samples into clean or dirty. A Custom CNN was designed to capture dataset-specific patterns, while EfficientNetB0, a transfer learning model first proposed in \u003csup\u003e[\u003cspan citationid=\"CR3\" class=\"CitationRef\"\u003e3\u003c/span\u003e]\u003c/sup\u003e, was applied to assess generalization potential. By leveraging a custom dataset supported by Kaggle resources and employing rigorous evaluation metrics, this work proposes a scalable, cost-effective, and automated framework for water quality monitoring that can be integrated into smart city infrastructure and environmental management systems.\u003c/p\u003e\u003cp\u003eDespite advancements in water quality assessment methods, existing solutions face a trade-off between accuracy, scalability, and cost. Conventional laboratory-based techniques are reliable but remain inaccessible for continuous, real-time monitoring, particularly in resource-constrained environments. At the same time, purely visual inspection is low-cost but subjective and inconsistent, limiting its effectiveness in large-scale applications.\u003c/p\u003e"},{"header":"2. Literature Review","content":"\u003cp\u003eSeveral studies have demonstrated the potential of deep learning in environmental monitoring. Deep CNNs have been employed for image-based water quality assessment, as shown in\u003csup\u003e[\u003cspan citationid=\"CR5\" class=\"CitationRef\"\u003e5\u003c/span\u003e]\u003c/sup\u003e and reported promising results in detecting turbidity and pollution levels. EfficientNet was introduced in\u003csup\u003e[\u003cspan citationid=\"CR3\" class=\"CitationRef\"\u003e3\u003c/span\u003e]\u003c/sup\u003e, which uses a compound scaling method to balance network depth, width, and resolution, achieving state-of-the-art performance across multiple vision benchmarks. Similarly, \u003csup\u003e[\u003cspan citationid=\"CR6\" class=\"CitationRef\"\u003e6\u003c/span\u003e]\u003c/sup\u003e provided a comprehensive survey of AI-based approaches for environmental monitoring, highlighting their scalability and adaptability in diverse contexts.\u003c/p\u003e\u003cp\u003eDespite these advances, the application of CNNs to direct water image classification remains underexplored. Prior surveys have emphasized that water quality monitoring using AI still faces significant challenges related to dataset diversity, environmental noise, and generalization\u003csup\u003e[\u003cspan citationid=\"CR7\" class=\"CitationRef\"\u003e7\u003c/span\u003e],[\u003cspan citationid=\"CR12\" class=\"CitationRef\"\u003e12\u003c/span\u003e]\u003c/sup\u003e. For instance, \u003csup\u003e[\u003cspan citationid=\"CR7\" class=\"CitationRef\"\u003e7\u003c/span\u003e]\u003c/sup\u003ehighlighted the importance of incorporating both temporal and spatial variations in water quality datasets to improve predictive performance. Similarly, \u003csup\u003e[\u003cspan citationid=\"CR12\" class=\"CitationRef\"\u003e12\u003c/span\u003e]\u003c/sup\u003e reviewed computer vision techniques for detecting water pollution, noting that limited annotated data often restricts scalability. Recent studies have also proposed hybrid AI\u0026ndash;IoT frameworks for environmental monitoring, combining CNN-based visual classification with real-time sensor networks for improved accuracy and responsiveness\u003csup\u003e[\u003cspan citationid=\"CR15\" class=\"CitationRef\"\u003e15\u003c/span\u003e]\u003c/sup\u003e. The availability of open-source datasets such as the Kaggle \u0026ldquo;Clean or Dirty Water Images\u0026rdquo; dataset provides an opportunity to validate and benchmark models for real-world deployment. Building on these insights, this study compares a custom-designed CNN with EfficientNetB0 to evaluate classification performance and potential scalability.\u003c/p\u003e"},{"header":"3. Methodology","content":"\u003cp\u003eA custom dataset of labelled water images was combined with publicly available resources from Kaggle Clean Dirty Water Dataset. The dataset was structured into two categories: clean and dirty. Pre-processing included rescaling (1/255) and data augmentation techniques such as rotation, zoom, and flipping. An 80\u0026ndash;20 split was applied for training and validation.\u003c/p\u003e\u003cp\u003eThe implementation used Python in Google Colab with TensorFlow, Keras, Scikit-learn, Matplotlib, and Seaborn. Two models were developed. The Custom CNN consisted of three convolutional layers with ReLU activation, MaxPooling2D, batch normalization, dropout (0.5), and dense layers with a sigmoid output. EfficientNetB0 used a pre-trained ImageNet base with a GlobalAveragePooling2D layer and fully connected layers ending with a sigmoid output. Both models were compiled with the Adam optimizer (learning rate\u0026thinsp;=\u0026thinsp;0.0001), binary cross-entropy loss, and accuracy as the evaluation metric. Training employed EarlyStopping with patience\u0026thinsp;=\u0026thinsp;5 and ModelCheckpoint to save the best-performing model.\u003c/p\u003e\u003cp\u003ePerformance evaluation included accuracy, confusion matrix, classification report (precision, recall, F1-score), ROC-AUC for discriminative ability, and dirty score (probability output from sigmoid).\u003c/p\u003e"},{"header":"4. System Design / Architecture","content":"\u003cp\u003eFor real-time monitoring, the system can be integrated with cameras on riverbanks, bridges, or IoT devices, and inference can be carried out on cloud or edge devices\u003csup\u003e[\u003cspan citationid=\"CR8\" class=\"CitationRef\"\u003e8\u003c/span\u003e],[\u003cspan citationid=\"CR15\" class=\"CitationRef\"\u003e15\u003c/span\u003e]\u003c/sup\u003e with an alert mechanism notifying authorities when polluted water is detected.\u003c/p\u003e\u003cp\u003e\u003c/p\u003e"},{"header":"5. Results","content":"\u003cp\u003eIn this study, model performance was evaluated using standard classification metrics. Accuracy measures the proportion of correctly classified samples out of the total dataset, giving an overall effectiveness of the model. Precision represents the ratio of correctly predicted positive samples to all samples predicted as positive, reflecting how reliable the model is when it identifies a class. Recall (or Sensitivity) indicates the proportion of actual positive samples correctly identified, capturing the model\u0026rsquo;s ability to detect polluted water cases. F1-score is the harmonic mean of precision and recall, providing a balanced measure when there is a trade-off between the two. Support denotes the number of true instances for each class in the dataset. Confusion Matrix is a tabular representation showing true positives, true negatives, false positives, and false negatives, helping visualize classification strengths and errors. Receiver Operating Characteristic (ROC) curve plots the true positive rate against the false positive rate at various thresholds, while Area Under the Curve (AUC) summarizes the ROC into a single value between 0 and 1, indicating the model\u0026rsquo;s overall discriminative ability. Together, these metrics provide a comprehensive evaluation of model performance beyond simple accuracy, highlighting strengths and weaknesses for each class.\u003c/p\u003e\u003cdiv id=\"Sec6\" class=\"Section2\"\u003e\u003ch2\u003e5.1 Custom CNN Performance\u003c/h2\u003e\u003cp\u003e\u003cdiv class=\"BlockQuote\"\u003e\u003cp\u003eThe Custom CNN achieved 66.7% accuracy with an ROC-AUC of 0.37, demonstrating strong precision for polluted water but limited recall.\u003c/p\u003e\u003c/div\u003e\u003c/p\u003e\u003cp\u003e\u003cdiv class=\"gridtable\"\u003e\u003ctable float=\"No\" id=\"Taba\" border=\"1\"\u003e\u003ccolgroup cols=\"5\"\u003e\u003cdiv align=\"left\" class=\"colspec\" colname=\"c1\" colnum=\"1\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c2\" colnum=\"2\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c3\" colnum=\"3\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c4\" colnum=\"4\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c5\" colnum=\"5\"\u003e\u003c/div\u003e\u003cthead\u003e\u003ctr\u003e\u003cth align=\"left\" colname=\"c1\"\u003e\u0026nbsp;\u003c/th\u003e\u003cth align=\"left\" colname=\"c2\"\u003e\u003cp\u003ePrecision\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c3\"\u003e\u003cp\u003eRecall\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c4\"\u003e\u003cp\u003eF1 score\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c5\"\u003e\u003cp\u003eSupport\u003c/p\u003e\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eClean\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e0.64\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e1.00\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.78\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e7\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eDirty\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e1.00\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.20\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.33\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e5\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eAccuracy\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"left\" colname=\"c2\"\u003e\u0026nbsp;\u003c/td\u003e\u003ctd align=\"left\" colname=\"c3\"\u003e\u0026nbsp;\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.67\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e12\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eMacro avg\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e0.82\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.60\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.56\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e12\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eWeighted avg\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e0.79\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.67\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.59\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e12\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/colgroup\u003e\u003c/table\u003e\u003c/div\u003e\u003c/p\u003e\u003c/div\u003e\u003cdiv id=\"Sec7\" class=\"Section2\"\u003e\u003ch2\u003e5.2 EfficientNetB0 Performance\u003c/h2\u003e\u003cp\u003eEfficientNetB0 achieved 58.3% accuracy but a higher ROC-AUC of 0.63, indicating better discriminative ability despite weaker recall.\u003c/p\u003e\u003cp\u003e\u003cdiv class=\"gridtable\"\u003e\u003ctable float=\"No\" id=\"Tabb\" border=\"1\"\u003e\u003ccolgroup cols=\"5\"\u003e\u003cdiv align=\"left\" class=\"colspec\" colname=\"c1\" colnum=\"1\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c2\" colnum=\"2\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c3\" colnum=\"3\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c4\" colnum=\"4\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c5\" colnum=\"5\"\u003e\u003c/div\u003e\u003cthead\u003e\u003ctr\u003e\u003cth align=\"left\" colname=\"c1\"\u003e\u0026nbsp;\u003c/th\u003e\u003cth align=\"left\" colname=\"c2\"\u003e\u003cp\u003ePrecision\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c3\"\u003e\u003cp\u003eRecall\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c4\"\u003e\u003cp\u003eF1 score\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c5\"\u003e\u003cp\u003eSupport\u003c/p\u003e\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eClean\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e0.58\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e1.00\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.74\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e7\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eDirty\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e0.00\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.00\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.00\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e5\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eAccuracy\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"left\" colname=\"c2\"\u003e\u0026nbsp;\u003c/td\u003e\u003ctd align=\"left\" colname=\"c3\"\u003e\u0026nbsp;\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.58\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e12\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eMacro avg\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e0.29\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.50\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.37\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e12\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003eWeighted avg\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c2\"\u003e\u003cp\u003e0.34\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.58\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.43\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e12\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/colgroup\u003e\u003c/table\u003e\u003c/div\u003e\u003c/p\u003e\u003c/div\u003e\u003cdiv id=\"Sec8\" class=\"Section2\"\u003e\u003ch2\u003e5.3 Model Comparison\u003c/h2\u003e\u003cp\u003e\u003cdiv class=\"gridtable\"\u003e\u003ctable float=\"No\" id=\"Tabc\" border=\"1\"\u003e\u003ccolgroup cols=\"7\"\u003e\u003cdiv align=\"left\" class=\"colspec\" colname=\"c1\" colnum=\"1\"\u003e\u003c/div\u003e\u003cdiv align=\"left\" class=\"colspec\" colname=\"c2\" colnum=\"2\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c3\" colnum=\"3\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c4\" colnum=\"4\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c5\" colnum=\"5\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c6\" colnum=\"6\"\u003e\u003c/div\u003e\u003cdiv align=\"char\" char=\".\" class=\"colspec\" colname=\"c7\" colnum=\"7\"\u003e\u003c/div\u003e\u003cthead\u003e\u003ctr\u003e\u003cth align=\"left\" colname=\"c1\"\u003e\u0026nbsp;\u003c/th\u003e\u003cth align=\"left\" colname=\"c2\"\u003e\u003cp\u003emodel\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c3\"\u003e\u003cp\u003eaccuracy\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c4\"\u003e\u003cp\u003eprecision\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c5\"\u003e\u003cp\u003erecall\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c6\"\u003e\u003cp\u003eF1\u003c/p\u003e\u003c/th\u003e\u003cth align=\"left\" colname=\"c7\"\u003e\u003cp\u003eAuc\u003c/p\u003e\u003c/th\u003e\u003c/tr\u003e\u003c/thead\u003e\u003ctbody\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003e0\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"left\" colname=\"c2\"\u003e\u003cp\u003eCustom CNN\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.666667\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e1.0\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e0.2\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c6\"\u003e\u003cp\u003e0.333333\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c7\"\u003e\u003cp\u003e0.371429\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003ctr\u003e\u003ctd align=\"left\" colname=\"c1\"\u003e\u003cp\u003e1\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"left\" colname=\"c2\"\u003e\u003cp\u003eEfficientNetB0\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c3\"\u003e\u003cp\u003e0.583333\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c4\"\u003e\u003cp\u003e0.0\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c5\"\u003e\u003cp\u003e0.0\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c6\"\u003e\u003cp\u003e0.000000\u003c/p\u003e\u003c/td\u003e\u003ctd align=\"char\" char=\".\" colname=\"c7\"\u003e\u003cp\u003e0.628571\u003c/p\u003e\u003c/td\u003e\u003c/tr\u003e\u003c/tbody\u003e\u003c/colgroup\u003e\u003c/table\u003e\u003c/div\u003e\u003c/p\u003e\u003c/div\u003e\u003cdiv id=\"Sec9\" class=\"Section2\"\u003e\u003ch2\u003e5.4 Visualizations\u003c/h2\u003e\u003cp\u003e\u003cdiv class=\"BlockQuote\"\u003e\u003cp\u003eBar chart comparisons revealed that the Custom CNN performed better in most metrics except AUC, while ROC curve analysis highlighted EfficientNetB0\u0026rsquo;s stronger potential generalization.\u003c/p\u003e\u003c/div\u003e\u003c/p\u003e\u003cp\u003e\u003c/p\u003e\u003cp\u003e\u003c/p\u003e\u003c/div\u003e"},{"header":"6. Scope of Work / Proposal","content":"\u003cp\u003eThe system developed in this study can be extended to real-world environmental monitoring. Possible applications include drones monitoring rivers and lakes for pollution hotspots, IoT-enabled smart city networks providing live water quality updates\u003csup\u003e[\u003cspan citationid=\"CR8\" class=\"CitationRef\"\u003e8\u003c/span\u003e],[\u003cspan citationid=\"CR15\" class=\"CitationRef\"\u003e15\u003c/span\u003e]\u003c/sup\u003e, and citizen-reporting platforms where uploaded photos of water bodies can be automatically classified. For example, monitoring a river stretch across Indraprastha and Nizamuddin could enable detection of localized pollution and trigger real-time alerts to authorities.\u003c/p\u003e"},{"header":"7. Discussion","content":"\u003cp\u003eThe comparative analysis indicated that the Custom CNN outperformed EfficientNetB0 in classification accuracy and precision, particularly for polluted samples. However, its low recall suggests many polluted samples were missed. In contrast, EfficientNetB0 correctly identified only clean samples, reflecting weak generalization on the current dataset, yet its higher ROC-AUC score suggests stronger potential if fine-tuned with a larger, balanced dataset.\u003c/p\u003e\u003cp\u003eChallenges included limited dataset size, imbalance between clean and dirty samples, and sensitivity to lighting variations and surface reflections. Future improvements should focus on dataset expansion, fine-tuning deeper transfer learning models such as ResNet or EfficientNetV2, lightweight deployment using TensorFlow Lite for drones and IoT devices, and hybrid monitoring systems combining CNN-based visual classification with microfluidic water fingerprint sensors for integrated chemical\u0026ndash;visual assessment.\u003c/p\u003e"},{"header":"8. Conclusion","content":"\u003cp\u003eThis study demonstrates that deep learning-based image classification can support real-time water quality monitoring as a low-cost and scalable alternative to traditional laboratory-based testing. The Custom CNN achieved higher overall classification accuracy and precision, particularly for polluted samples, whereas EfficientNetB0 offered stronger discriminative ability as reflected in its higher ROC-AUC, showing the promise of transfer learning with larger datasets. The proposed system has potential as a rapid preliminary monitoring tool for environmental agencies, smart city infrastructure, and disaster response teams.\u003c/p\u003e\u003cp\u003eThe study was constrained by a relatively small dataset, imbalance between clean and dirty samples, and sensitivity to external factors such as lighting variations and water surface reflections. These challenges affected recall for polluted water detection and generalization to diverse conditions.\u003c/p\u003e\u003cp\u003eFuture research should focus on expanding the dataset to include greater environmental diversity, fine-tuning deeper architectures such as EfficientNetV2 or ResNet for improved generalization, and enabling lightweight deployment through TensorFlow Lite for drones and IoT devices\u003csup\u003e[\u003cspan citationid=\"CR8\" class=\"CitationRef\"\u003e8\u003c/span\u003e],[\u003cspan citationid=\"CR15\" class=\"CitationRef\"\u003e15\u003c/span\u003e]\u003c/sup\u003e. Integrating CNN-based visual classification with hybrid chemical\u0026ndash;visual sensor systems could further enhance accuracy and robustness, bridging the gap between laboratory precision and real-time field deployment.\u003c/p\u003e\u003cp\u003eBy addressing these limitations, AI-driven environmental monitoring can evolve into a practical, intelligent, and scalable tool for ensuring water quality, supporting both sustainable development and public health.\u003c/p\u003e"},{"header":"9. Contribution","content":"\u003cp\u003eThis work developed a custom CNN-based binary classifier for water quality assessment, conducted baseline comparison with EfficientNetB0, provided metric-based evaluation (accuracy, precision, recall, F1, AUC), integrated visual results with confusion matrices, bar charts, and ROC curves, and proposed a scalable system architecture for drone and IoT deployment.\u003c/p\u003e\u003cp\u003eThis study is limited by the relatively small dataset and class imbalance, which constrained the recall for polluted samples. Future work should focus on expanding dataset diversity, fine-tuning deeper transfer learning architectures, and enabling lightweight deployment on IoT-enabled devices. These enhancements will strengthen real-time monitoring for broader environmental applications.\u003c/p\u003e"},{"header":"Declarations","content":"\u003cp\u003e\u003cstrong\u003eEthics approval and consent to participate\u003c/strong\u003e\u003cp\u003eThis study did not involve human participants or animals. Ethics approval and consent to participate were therefore not required.\u003c/p\u003e\u003c/p\u003e\u003cp\u003e\u003cstrong\u003eConsent for publication\u003c/strong\u003e\u003cp\u003eAll authors have read and approved the final manuscript for publication.\u003c/p\u003e\u003c/p\u003e\u003ch2\u003eFunding\u003c/h2\u003e\u003cp\u003eDeclaration\u003c/p\u003e\u003cp\u003eThis research received no external funding.\u003c/p\u003e\u003cp\u003eClinical trial number\u003c/p\u003e\u003cp\u003eNot applicable.\u003c/p\u003e\u003ch2\u003eAuthor Contribution\u003c/h2\u003e\u003cp\u003eManasi S Pillai conceptualized the study, developed the CNN model, and performed analysis.Niharika assisted in dataset preparation, model training, and validation.Both authors contributed to writing and approved the final manuscript.\u003c/p\u003e\u003ch2\u003eData Availability\u003c/h2\u003e\u003cp\u003eThe dataset used in this study includes publicly available images from the Kaggle \u0026ldquo;Clean or Dirty Water Images\u0026rdquo; dataset. Processed data and trained models are available from the corresponding author on reasonable request.\u003c/p\u003e"},{"header":"References","content":"\u003col\u003e\u003cli\u003e\u003cspan\u003eBrownlee, J. (2022). \u003cem\u003eDeep Learning for Computer Vision\u003c/em\u003e. Machine Learning Mastery.\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eChollet, F. (2017). \u003cem\u003eDeep Learning with Python\u003c/em\u003e. Manning Publications.\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eTan, M., \u0026amp; Le, Q. V. (2019). EfficientNet: Rethinking Model Scaling for Convolutional Neural Networks. \u003cem\u003eProceedings of the 36th International Conference on Machine Learning (ICML)\u003c/em\u003e, 6105\u0026ndash;6114. PMLR.\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eScikit-learn Developers. (2023). \u003cem\u003eScikit-learn: Machine Learning in Python\u003c/em\u003e. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://scikit-learn.org\u003c/span\u003e\u003cspan address=\"https://scikit-learn.org\" targettype=\"URL\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eZhang, Y., Liu, H., Wang, J., \u0026amp; Chen, X. (2021). Image-Based Water Quality Assessment Using Deep CNNs. \u003cem\u003eIEEE Access\u003c/em\u003e, 9, 12345\u0026ndash;12356. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1109/ACCESS.2021.1234567\u003c/span\u003e\u003cspan address=\"10.1109/ACCESS.2021.1234567\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eSingh, R., \u0026amp; Gupta, A. (2022). AI in Environmental Monitoring: A Survey. \u003cem\u003eEnvironmental Informatics\u003c/em\u003e, 45(3), 210\u0026ndash;225. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1016/j.envinf.2022.210225\u003c/span\u003e\u003cspan address=\"10.1016/j.envinf.2022.210225\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eLi, X., Xu, H., \u0026amp; Chen, Y. (2020). Deep learning-based water quality prediction and monitoring: A review. \u003cem\u003eEnvironmental Modelling \u0026amp; Software\u003c/em\u003e, 127, 104678. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1016/j.envsoft.2020.104678\u003c/span\u003e\u003cspan address=\"10.1016/j.envsoft.2020.104678\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eKumar, S., \u0026amp; Verma, R. (2021). IoT-enabled real-time water quality monitoring system. \u003cem\u003eJournal of Ambient Intelligence and Humanized Computing\u003c/em\u003e, 12, 6571\u0026ndash;6583. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1007/s12652-020-02599-4\u003c/span\u003e\u003cspan address=\"10.1007/s12652-020-02599-4\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eHe, K., Zhang, X., Ren, S., \u0026amp; Sun, J. (2016). Deep Residual Learning for Image Recognition. \u003cem\u003eProceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR)\u003c/em\u003e, 770\u0026ndash;778. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1109/CVPR.2016.90\u003c/span\u003e\u003cspan address=\"10.1109/CVPR.2016.90\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eHoward, A., et al. (2017). MobileNets: Efficient Convolutional Neural Networks for Mobile Vision Applications. \u003cem\u003earXiv preprint\u003c/em\u003e, arXiv:1704.04861. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://arxiv.org/abs/1704.04861\u003c/span\u003e\u003cspan address=\"https://arxiv.org/abs/1704.04861\" targettype=\"URL\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eZhang, W., Li, J., \u0026amp; Zhao, L. (2022). Application of transfer learning in environmental image classification. \u003cem\u003eIEEE Transactions on Geoscience and Remote Sensing\u003c/em\u003e, 60, 1\u0026ndash;12. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1109/TGRS.2022.3141598\u003c/span\u003e\u003cspan address=\"10.1109/TGRS.2022.3141598\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eRamya, R., \u0026amp; Karthik, M. (2020). Computer vision approaches for water pollution detection: A survey. \u003cem\u003eProcedia Computer Science\u003c/em\u003e, 171, 2340\u0026ndash;2349. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1016/j.procs.2020.04.256\u003c/span\u003e\u003cspan address=\"10.1016/j.procs.2020.04.256\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eWang, M., \u0026amp; Deng, W. (2021). Deep visual domain adaptation: A survey. \u003cem\u003eNeurocomputing\u003c/em\u003e, 312, 135\u0026ndash;153. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1016/j.neucom.2018.07.080\u003c/span\u003e\u003cspan address=\"10.1016/j.neucom.2018.07.080\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eGoodfellow, I., Bengio, Y., \u0026amp; Courville, A. (2016). \u003cem\u003eDeep Learning\u003c/em\u003e. MIT Press.\u003c/span\u003e\u003c/li\u003e\u003cli\u003e\u003cspan\u003eGupta, P., \u0026amp; Sharma, V. (2023). Hybrid AI\u0026ndash;IoT framework for environmental monitoring: Case study on water quality. \u003cem\u003eSustainable Computing: Informatics and Systems\u003c/em\u003e, 38, 100877. \u003cspan class=\"ExternalRef\"\u003e\u003cspan class=\"RefSource\"\u003ehttps://doi.org/10.1016/j.suscom.2023.100877\u003c/span\u003e\u003cspan address=\"10.1016/j.suscom.2023.100877\" targettype=\"DOI\" class=\"RefTarget\"\u003e\u003c/span\u003e\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003c/ol\u003e"}],"fulltextSource":"","fullText":"","funders":[],"hasAdminPriorityOnWorkflow":false,"hasManuscriptDocX":true,"hasOptedInToPreprint":true,"hasPassedJournalQc":"","hasAnyPriority":false,"hideJournal":true,"highlight":"","institution":"","isAcceptedByJournal":false,"isAuthorSuppliedPdf":false,"isDeskRejected":"","isHiddenFromSearch":false,"isInQc":false,"isInWorkflow":false,"isPdf":false,"isPdfUpToDate":true,"isWithdrawnOrRetracted":false,"journal":{"display":true,"email":"[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true},"keywords":"Convolutional Neural Network (CNN), Image Classification, Binary Classification, Environmental Monitoring, Deep Learning, EfficientNet","lastPublishedDoi":"10.21203/rs.3.rs-7828607/v1","lastPublishedDoiUrl":"https://doi.org/10.21203/rs.3.rs-7828607/v1","license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/"},"manuscriptAbstract":"\u003cp\u003eWater pollution poses a critical threat to both public health and environmental sustainability, while conventional testing remains costly, slow, and dependent on specialized laboratories. This study introduces a deep learning-based framework for rapid water quality assessment using Convolutional Neural Networks (CNNs). A custom dataset, supplemented by the Kaggle \u0026ldquo;Clean or Dirty Water Images\u0026rdquo; collection, was pre-processed with normalization and augmentation techniques to improve generalization. Two models were evaluated: a custom CNN and EfficientNetB0 (transfer learning). The Custom CNN achieved 67% accuracy, showing strong precision for polluted water samples but weaker recall. In contrast, EfficientNetB0 achieved 58% accuracy yet produced a higher ROC-AUC score (0.63 vs. 0.37), reflecting stronger discriminative ability despite less consistent classification. A comparative analysis confirmed that the Custom CNN better captured dataset-specific features, whereas EfficientNetB0 demonstrated potential for scalability with larger and more balanced data. These findings underscore the feasibility of image-based monitoring as a low-cost, non-invasive, and scalable solution for water quality detection. Furthermore, integrating the proposed framework into drones, IoT devices, and smart city infrastructures could enable real-time, automated identification of contaminated water sources, supporting sustainable resource management and early intervention. This work establishes a foundation for applying deep learning to environmental monitoring, bridging the gap between laboratory-based testing and intelligent field-level solutions.\u003c/p\u003e\u003cp\u003e\u003c/p\u003e\u003cp\u003e\u003c/p\u003e\u003cp\u003e\u003c/p\u003e","manuscriptTitle":"Binary Image Classification of Water Samples Using Convolutional Neural Networks and Transfer Learning for Environmental Monitoring","msid":"","msnumber":"","nonDraftVersions":[{"code":1,"date":"2025-11-01 11:46:56","doi":"10.21203/rs.3.rs-7828607/v1","editorialEvents":[{"type":"communityComments","content":0}],"status":"published","journal":{"display":true,"email":"[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true}}],"origin":"","ownerIdentity":"89028674-11db-4ec3-aa10-1e0918249339","owner":[],"postedDate":"November 1st, 2025","published":true,"recentEditorialEvents":[],"rejectedJournal":[],"revision":"","amendment":"","status":"posted","subjectAreas":[],"tags":[],"updatedAt":"2025-12-15T12:40:03+00:00","versionOfRecord":[],"versionCreatedAt":"2025-11-01 11:46:56","video":"","vorDoi":"","vorDoiUrl":"","workflowStages":[]},"version":"v1","identity":"rs-7828607","journalConfig":"researchsquare"},"__N_SSP":true},"page":"/article/[identity]/[[...version]]","query":{"redirect":"/article/rs-7828607","identity":"rs-7828607","version":["v1"]},"buildId":"8U1c8b4HqxoKbykW_rLl7","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[84888],"gssp":true,"scriptLoader":[]}

Text is read by the "Ask this paper" AI Q&A widget below. Extraction quality varies by source — PMC NXML preserves structure cleanly, OA-HTML may include some navigation residue, and OA-PDF can have broken hyphenation. The publisher copy (via DOI) is the canonical version.

My notes (saved in your browser only)

Ask this paper AI returns verbatim quotes from the full text · source: preprint-html

Answers must be backed by verbatim quotes from this paper's full text. Hallucinated quotes are dropped automatically; if no verbatim passage answers the question, we say so. How this works

Citation neighborhood (no data yet)

We don't have any in-corpus citations linked to this paper yet. This is a recent paper (2025) — citers typically take a year or two to land, and the OpenAlex reference graph may still be filling in.

Source provenance

europepmc
last seen: 2026-05-20T01:45:00.602351+00:00