Global Publishing Platform
Serving Researchers Since 2012

Smart Ensemble-Based Pest Detection and Soil Fertility Analysis System for Sustainable Agriculture

DOI : 10.17577/IJERTV15IS031122
Download Full-Text PDF Cite this Publication

Text Only Version

 

Smart Ensemble-Based Pest Detection and Soil Fertility Analysis System for Sustainable Agriculture

Mr. P. Karthikeyan

Assistant Professor, Department of CSE, Siddharth Institute of Engineering & Technology. Puttur, Andhra Pradesh, India.

Putha Uma Maheswari

U.G. Scholar, Department of CSE, Siddharth Institute of Engineering & Technology. Puttur. Andhra Pradesh, India

Geni Sowjanya

U.G. Scholar. Department of CSE, Siddharth Institute of Engineering & Technology. Puttur, Andhra Pradesh, India

Poola Simhadri

U.G. Scholar, Department of CSE. Siddharth Institute of Engineering & Technology, Puttur. Andhra Pradesh, India

S. Venu

U.G. Scholar, Department of CSE, Siddharth Institute of Engineering & Technology, Puttur. Andhra Pradesh, India

Abstract – Agriculture is having a time because of bugs and poor soil quality. This is a problem for the crops and the future of farming. We made a system that uses computers to help farmers make decisions. It looks at pictures of the crops to figure out what kind of bugs are there. The system also checks the soil to see how healthy it is by looking at the nutrients it needs. Agriculture is a deal here and the system helps with that. It tells farmers what to do to get rid of the bugs and how to make the soil better. This way farmers can grow crops and take care of the land. The system is good at predicting problems and giving advice on what to do about bugs and fertilizer, for Agriculture. By reducing dependency on manual inspection and laboratory testing, the proposed approach supports precision agriculture, improves resource utilization, and enhances productivity, particularly for small-scale and rural farmers. Agriculture is having a time because of bugs and poor soil quality. This is a problem for the crops and the future of farming. We made a system that uses computers to help farmers make decisions. It looks at pictures of the crops to figure out what kind of bugs are there. The system also checks the soil to see how healthy it is by looking at the nutrients it needs. Agriculture is a deal here and the system helps with that. It tells farmers what to do to get rid of the bugs and how to make the soil better. This way farmers can grow crops and take care of the land. The system is good at predicting problems and giving advice on what to do about bugs and fertilizer, for Agriculture. By reducing dependency on manual inspection and laboratory testing, the proposed approach supports precision agriculture, improves resource utilization, and enhances productivity, particularly for small-scale and rural farmers.

Keywords- Machine learning, deep learning, pest detection, soil fertility analysis, convolutional neural networks, ensemble learning, precision agriculture.

  1. INTRODUCTION

    Agriculture is really important for making sure we have food around the world.. It has a lot of problems, like bugs eating crops soil getting bad weird weather and not using

    resources very well. The world has a lot of people and it is getting more so we need to grow food. This means we have to find ways to farm because the old ways are not working very well. Agriculture needs to change because it still relies on people looking at things and making decisions based on what they think and it takes a lot of work. We need to make Agriculture better so we can feed everyone. These traditional methods are usually pretty slow. They can be. They do not work well when things change quickly in the field. This means that crops are lost and the farming is not sustainable. The conventional approaches lead to crop losses and reduced sustainability of the conventional approaches.

    Pests are a problem for farmers. They can really hurt the amount of food that is grown every year. It is very important to find out what kind of pest is causing the problem soon as possible. This is because pests can do a lot of damage if they are not stopped.

    The usual way to find pests is for farmers or experts to look at the plants and try to figure out what is wrong.. This method is not very good because it requires a lot of knowledge about pests. Also it can take a time to figure out what is going on which means that the pests can do a lot of damage before anything is done to stop them. Sometimes the wrong pest is identified, which means that the wrong pesticides are used. This can be very bad, for the environment. It can also cost farmers a lot of money. Pests and the problems they cause are a deal and pest identification is a crucial part of dealing with them. Soil fertility is really important for crops to grow. The soil needs to have nutrients like nitrogen, phosphorus and potassium for the crops to be healthy. If these nutrients are not available the crops will not grow well.

    Soil fertility is important for crop growth and fertilizer is often used without knowing what the soil really needs. This is because farmers do not have the information about

    the soil. As a result farmers may use much or too little fertilizer, which can harm the soil. Soil fertility and fertilizer use are related and soil fertility is essential, for healthy crops.

    Machine learning can look at a lot of information find patterns that are not easy to see and make good predictions without being told exactly what to do.

    In farming machine learning can use different kinds of information like pictures of crops details about the soil and what the weather is like to help farmers make good decisions at the right time. Machine learning is very helpful, in farming because it can process all these kinds of information like crop images and soil parameters and use them to support farmers. Deep learning is really good at figuring things out. It uses something called Convolutional Neural Networks or CNNs for short. These Convolutional Neural Networks are very good at looking at pictures and telling what is in them. This makes deep learning and Convolutional Neural Networks very useful for finding pests and checking how healthy crops are. Deep learning and Convolutional Neural Networks can do this because they are good, at looking at pictures.

    Soil fertility analysis is a deal. Ensemble learning techniques are really good at making predictions better and more accurate. They do this by using machine learning models at the same time. This helps reduce mistakes that can happen when you only use one model. Ensemble learning techniques make the results more reliable. When we use based models for soil fertility analysis they can tell us how healthy the soil is and what nutrients it is missing. This means we can give good advice on what fertilizers to use. Using learning to detect pests and ensemble machine learning for soil analysis is a great way to make precision agriculture work really well. Ensemble learning techniques and machine learning models are important, for soil fertility analysis and precision agriculture.

  2. RELATED WORK

    Machine learning and deep learning are being used a lot in agriculture these days. People are really interested, in this because they want to find ways to manage crops that’re easy to use and give good results.

    Machine learning and deep learning can help with things like finding pests and checking the soil to see if it has nutrients. Some people have even made systems that can help farmers make decisions.

    This is a deal because machine learning and deep learning can really help farmers grow more food.

    People did some work on automating farming. They mostly used ways of looking at pictures and following rules. They looked at the color, texture and shape of crops in pictures. Then they used these things with classifiers like Support Vector Machines and k-Nearest Neighbors to figure out if there were any pests.

    They found that these methods were pretty good at identifying pests. They had some problems. The lighting had to be just right. The method did not work well. If the picture was not clear or if there was a lot of stuff in the background the method did not work well either. This made it hard to use these methods in the world, where things are not always

    perfect. Agricultural automation, like automation needs better methods that can handle real world problems.

    The field of image-based analysis has really taken off with the help of deep learning. Convolutional Neural Networks or CNNs for short are now the way to do this kind of analysis. For example Mohanty and his team used CNN architectures to figure out what diseases plants have by looking at pictures of their leaves. They were able to get it more than 95 percent of the time when they were working with controlled datasets. On people used similar methods to detect pests. They used CNN models like VGG16, ResNet50 and Inception networks to teach computers to recognize insects in pictures. These models were able to learn what to look for in the images. Convolutional Neural Networks are really good, at this kind of thing. These models do a lot better than the way of doing machine learning because they do not need people to pick out the important features. However the systems that use something called CNN usually need a lot of data that people have already looked at and labeled and they need a lot of power to run which can be a problem when you are working on a farm. You do not have a lot of resources. The CNN models are really good. They need a lot of data and power to work well which is not always possible in low-resource agricultural settings, like farms.

    To deal with the problem of not having data and to make things more general people are using something called transfer learning. This is a help. When we take a model that has already been trained on a lot of pictures and then train it some more on pictures of farms we get good results even when we do not have a lot of pictures to train it on. Transfer learning is good because it saves us time and we do not need much data.. Even with transfer learning the models can still be too sure of themselves and make mistakes when they see things they have not seen before, like different weather or lighting.

    In the area of soil fertility analysis people have used machine learning models for a time. Some models, like Random Forest and Gradient Boosting work well to figure out the levels of nutrients in the soil and to classify how fertile the soil is based on NPK parameters. For example XGBoost and CatBoost are very good at handling relationships between different things in soil datasets. They are usually very accurate and reliable. However when we use one model it can have a problem. It might pay much attention to some features and not enough to others, which can make the predictions less reliable. Soil fertility analysis is about understanding soil and these models like Random Forest and Gradient Boosting and also XGBoost and CatBoost are important tools, for this.

    Ensemble learning techniques are used to fix the problems of models. When we combine the predictions from classifiers like when we use voting or stacking the ensemble models do a better job and are more stable. For example in farming ensemble methods have worked well for systems that recommend crops and check soil health. They do a better job than models that work alone.A lot of systems that use ensemble methods only look at detecting pests or checking soil and they do not have a complete system that does both. Ensemble learning techniques like these can be very helpful, in areas especially when we use ensemble methods to make them better.

    Recent studies have emphasized the need for comprehensive decision support systems that unify pest detection, soil fertility assessment, and recommendation generation. IoT- enabled and AI-driven agricultural platforms have been proposed to provide real-time monitoring and predictive analytics [9]. While these systems demonstrate promising results, challenges related to cost, complexity, and interpretability remain.

  3. METHODOLOGY

    The proposed system uses an approach that relies on machine learning to automatically find pests and check soil fertility for precision agriculture. This system is made up of parts that work together including getting data cleaning up the data making a model using many models to make predictions and giving recommendations. This approach helps to make sure the system is accurate works well and can be used in different places, which is important for farms and other real-world agricultural environments. The precision agriculture system is designed to be good, at finding pests and checking soil fertility. The machine learning approach is a key part of this system.

    Data Acquisition

    The system uses two kinds of information: pictures of crop pests and data about soil nutrients. These pictures of pests come from available collections of agricultural images and from samples taken in the field showing many different types of pests in different lighting and backgrounds. The soil nutrient information is made up of numbers that show how much of important nutrients are in the soil, like nitrogen, phosphorus and potassium and it also includes labels that say how fertile the soil is. The crop pest images and soil nutrient data are used to teach computers to recognize patterns using computer programs. The crop pest images and soil nutrient data help train these computer programs to make predictions.

    Data Preprocessing

    The first thing we do with the pest images is make sure they are all the size. We make them 224×224 pixels so they work with the Convolutional Neural Network.

    Then we adjust the images so the colors are not too bright or too dull. This is called normalization. It helps the computer understand the images better.

    We also use a filter to get rid of noise in the images. This makes the pest images clearer.

    When we are training the computer to recognize the pest images we use some tricks to make it better, at finding them. We rotate the images make them bigger or smaller and flip them around. This helps the computer learn to find the pest images even when they’re not perfect.

    The Convolutional Neural Network is what we use to look at

    the pest images. We want to make sure it has the chance of working correctly.

    We need to make sure the soil nutrient data is good to use. So we do some work on it to make it consistent. We remove the values that do not fit in. This way we know the data is okay to use. If some values are missing or just not right we use math to figure out what they should be. This helps keep the dataset okay. We do this to make sure the soil nutrient data is consistent, across all the things we are looking at.

    Pest Detection Using Deep Learning

    For classifying pests we use a kind of computer program called a CNN-based deep learning model. This model uses something called transfer learning, which means it takes a program that has already been trained to recognize things called ResNet50 and teaches it to recognize pests in pictures of farms. The computer program can look at pictures of pests. Find things, like edges and textures and shapes which helps it figure out what kind of pest it is. We train the model by showing it lots of pictures of pests and telling it when it gets something and we use a special tool called the Adam optimizer to make sure the model gets better at recognizing pests over time. The model learns to recognize pests by looking at the pictures and trying to guess what they are. It gets better and better as it sees more pictures.

    Soil Fertility Analysis Using Machine Learning

    Soil fertility classification is done by using computer programs that work together. These programs, like Random Forest and Support Vector Machine and Gradient Boosting are taught with information about the nutrients in the soil like nitrogen and phosphorus and potassium to figure out if the soil is fertile or not. They can put the soil into three groups: soil that’s not very fertile soil that is somewhat fertile and soil that is very fertile.

    These computer programs can find connections between the nutrients in the soil and how fertile it is, even when these connections are not straightforward. By looking at which nutrientsre most important we can understand better what makes the soil healthy and this helps us make sense of the results from the soil fertility classification. Soil fertility classification is really, about understanding soil fertility and the computer programs help us do that.

    Ensemble Learning Strategy

    To make predictions more accurate ensemble learning is used. This means we combine the results from different machine learning models. We give importance to some models than others when we combine their results. This helps to reduce mistakes that individual models can make. It also makes the whole system work better even when the input is very different. When we use learning we can be more sure of the predictions. Ensemble learning models are better than using one model because they give us more confidence in the

    results. Ensemble learning is really good, at making predictions that we can trust.

    Recommendation Generation

    The final stage translates predictions into actionable recommendations. Based on detected pest types, the system suggests appropriate pest control measures. Soil fertility results are used to generate fertilizer recommendations tailored to nutrient deficiencies. This closes the loop between prediction and practical agricultural decision-making..

    Figure 1 Architecture Diagram

  4. RESULTS

    The new system for finding pests and checking soil health was tested to see how well it works. This system was checked using tests to see if it is accurate works well in different situations and is easy to use. Tests were done using pictures of pests that were already labeled and soil data that included information about nitrogen, phosphorus and potassium. The testing looked at three parts: finding pests checking soil health and using a combination of information to make decisions, about pest detection and soil fertility and soil health.

    For finding pests the computer model that uses pictures and is based on the ResNet50 design did a job. This model was very good at telling the difference between kinds of pests and it was right more than 90 percent of the time. The model was also very good at finding pests even when the pictures were not perfect like when the light was bad or the pest was at an angle. The people who made the model added some pictures to the mix, which helped the model get even better at finding pests. This model is way better than the way of finding pests because it can teach itself what to look for in a picture. The old way relied on people to tell it what to look for. This model can figure it out on its own, which makes it

    really good, at finding pests.

    Soil fertility analysis is really good at giving us results when we use machine learning models. We found that Random Forest and Gradient Boosting are very good at this they are better than linear classifiers. This is because they are good at understanding the relationships between the different nutrients in the soil. When we looked at what’s most important, for soil fertility we found that nitrogen is the most important thing then comes potassium and phosphorus. Using models together like Random Forest and Gradient Boosting makes our predictions more stable and stops them from being too closely tied to one set of data which is a problem that can happen with individual models.

    The ensemble learning strategy was really important for making the system more reliable. It worked by taking predictions from different classifiers and using a weighted voting system to make a decision. This made the system more confident in its answers. It made fewer mistakes. This was especially helpful when the individual models were not sure what to do. The ensemble learning strategy made the system better at making decisions than if it was just using a CNN or an ML model, on its own. The ensemble learning strategy is what made this happen because it used models to make a decision, not just one.

    The integrated recommendation module translated predictions into actionable insights. Pest detection outputs triggered suitable pest control suggestions, while soil fertility predictions generated fertilizer recommendations tailored to nutrient deficiencies. The end-to-end system demonstrated low inference latency, making it suitable for real-time or near-real-time agricultural decision support.

  5. CONCLUSION

    This study is about a system for agriculture that uses deep learning and machine learning to help farmers make good decisions. The system is really good at finding pests and checking the soil to see if it has nutrients. It solves some problems that farmers have with traditional ways of doing things. For example it can find pests away so farmers do not have to wait. It also makes it cheaper for farmers to check their soil.. It gives farmers the information they need to make good decisions about their farms. The intelligent agriculture decision support system is very helpful, for farmers because it uses learning and machine learning to make sure they have the best information.

    The system uses a kind of computer program called a CNN- based deep learning model to figure out what kind of pest is in a picture. This model is really good at getting the answer and it works well even when the pictures are not perfect. The model can learn from pictures too so it does not need a lot of new pictures to get better. This makes it useful for farmers who want to use it in their fields.

    When it comes to checking how healthy the soil is the system uses a kind of computer program that looks at how much nitrogen, phosphorus and potassium are in the soil. This program is really good, at telling whether the soil is healthy or not and it can also explain why it thinks that. The system looks at the NPK values. Uses that information to make a decision.

    The ensemble learning framework really makes things better by using predictions from different models. This helps to reduce mistakes and makes the results more reliable. It also makes sure that the performance is consistent when the input is not the same every time.

    The ensemble learning. The integrated recommendation engine work together to help farmers. The integrated recommendation engine provides advice on pest control and fertilizer to farmers, which is very useful. This is important because it helps to bridge the gap between making predictions and taking action. The ensemble learning framework and the integrated recommendation engine are helpful tools, for farmers.

    The system they have come up with is really meant to be used in the world. The system has a design it does not need a lot of computer power and it is easy for people to use. This means that the system is something that small farmers and farmers in areas can actually use. The system is helpful because it does not require farmers to know a lot of things or have special equipment. This helps farmers do their jobs in a way that’s good for the environment and helps them get the best results. The farming practices that the system supports are sustainable and precise which is what the system is about it is, about supporting sustainable farming and precision

    farming.

    While the results are promising, further improvements are possible. Future work can focus on expanding datasets, incorporating real-time IoT sensor data, and enhancing explainability through advanced XAI techniques. Mobile and cloud-based deployments can further improve accessibility and scalability. This study is about a system for agriculture that uses deep learning and machine learning to help farmers make good decisions. The system is really good at finding pests and checking the soil to see if it has nutrients. It solves some problems that farmers have with traditional ways of doing things. For example it can find pests away so farmers do not have to wait. It also makes it cheaper for farmers to check their soil.. It gives farmers the information they need to make good decisions about their farms. The intelligent agriculture decision support system is very helpful, for farmers because it uses learning and machine learning to make sure they have the best information.

    The system uses a kind of computer program called a CNN- based deep learning model to figure out what kind of pest is in a picture. This model is really good at getting the answer and it works well even when the pictures are not perfect. The model can learn from pictures too so it does not need a lot of new pictures to get better. This makes it useful for farmers who want to use it in their fields.

    When it comes to checking how healthy the soil is the system uses a kind of computer program that looks at how much nitrogen, phosphorus and potassium are in the soil. This program is really good, at telling whether the soil is healthy or not and it can also explain why it thinks that. The system looks at the NPK values. Uses that information to make a decision.

    The ensemble learning framework really makes things better by using predictions from different models. This helps to reduce mistakes and makes the results more reliable. It also makes sure that the performance is consistent when the input is not the same every time.

    The ensemble learning. The integrated recommendation engine work together to help farmers. The integrated recommendation engine provides advice on pest control and fertilizer to farmers, which is very useful. This is important because it helps to bridge the gap between making predictions and taking action. The ensemble learning framework and the integrated recommendation engine are helpful tools, for farmers.

    The system they have come up with is really meant to be used in the world. The system has a design it does not need a lot of computer power and it is easy for people to use. This means that the system is something that small farmers and farmers in areas can actually use. The system is helpful because it does not require farmers to know a lot of things or have special equipment. This helps farmers do their jobs in a way that’s good for the environment and helps them get the best results. The farming practices that the system supports

    are sustainable and precise which is what the system is about it is, about supporting sustainable farming and precision farming.

  6. FUTURE ENHANCEMENT

    The proposed system is really good, at finding pests and checking soil fertility.. There are some things that can be done to make it even better. The system needs to be improved so it can be used in places and work better in the real world. One thing that can be done is to add sensors that can send information about the soil to the system all the time. These sensors can measure how wet the soil is, how hot or cold it is and how acidic or basic it is. They can also check the environment around the soil. This means the system can watch the soil all the time and change its predictions if something changes in the field. The proposed system can get better at finding pests and checking soil fertility with these sensors.

    The development of an application is really important. This application will help farmers when they are out in the field. It will give them access to things, like pest detection and soil analysis. They can use the camera on their smartphone to do this. We can use models that are not too big and that work well with not a lot of power. This means that the mobile application can work quickly and give the farmers the information they need away. The mobile application will use these models and some other techniques to make sure it works well on devices that do not have a lot of power. This way farmers can use the application to get the information they need about pest detection and soil analysis.

    The system can also be made better by using techniques that make artificial intelligence explainable. This will help make things more transparent. If we show farmers what is going on and explain which things are important they will understand what the system is predicting. Farmers will also trust the automated recommendations from the system more. The artificial intelligence will be more helpful to farmers if they can see how it is making decisions. The system and the artificial intelligence will work together to make things clearer, for farmers.

    Future work may include predictive analytics using time- series models such as LSTM or GRU networks to forecast pest outbreaks and soil nutrient trends in advance. Additionally, expanding the dataset to include diverse crops, pest species, and climatic regions will improve generalization. Cloud-based deployment and multi-language support can further enhance scalability and accessibility, enabling widespread adoption of intelligent agriculture solutions.

  7. REFERENCES
  1. S. P. Mohanty, D. P. Hughes, and M. Salathé, Using deep learning for image-based plant disease detection, Frontiers in Plant Science, vol. 7, 2016.
  2. A. Too, L. Yujian, S. Njuki, and Y. Yingchun, A comparative study of fine-tuning deep learning models for plant disease identification, Computers and Electronics in Agriculture, vol. 161, 2019.
  3. T. Chen and C. Guestrin, XGBoost: A scalable tree boosting system,

    Proc. ACM SIGKDD, 2016.

  4. L. Rokach, Ensemble-based classifiers, Artificial Intelligence Review, vol. 33, no. 1, 2010.
  5. M. Hasan et al., Ensemble machine learning-based recommendation

    system for crop cultivation, Frontiers in Plant Science, 2023.

  6. R. K. Singh et al., Machine learning techniques for soil fertility prediction, Agricultural Informatics, 2018.
  7. A. Kamilaris and F. X. Prenafeta-Boldú, Deep learning in agriculture: A survey, Computers and Electronics in Agriculture, vol. 147, 2018.
  8. H. Wang et al., Soil nutrient prediction using machine learning models, IEEE Access, vol. 9, 2021.
  9. J. Li et al., Artificial intelligence in agriculture: A review,

    Information Processing in Agriculture, vol. 7, 2020.

  10. A. Morchid et al., IoT and AI-based smart irrigation systems, IEEE Access, vol. 12, 2024.
  11. Y. Lecun, Y. Bengio, and G. Hinton, Deep learning, Nature, vol. 521, 2015.
  12. K. He et al., Deep residual learning for image recognition, Proc. IEEE CVPR, 2016.
  13. J. Schmidhuber, Deep learning in neural networks, Neural Networks, vol. 61, 2015.
  14. M. R. Mahmood et al., Machine learning for smart agriculture: A survey, IEEE Transactions on Artificial Intelligence, 2024.
  15. A. Rehman et al., Precision agriculture using ML techniques,

    Sustainable Computing, 2022.

  16. Z. Sun et al., Improved random forest for agricultural data, Expert Systems with Applications, 2024.
  17. P. Garg et al., IoT-enabled pest monitoring systems, IEEE Sensors Journal, 2023.
  18. B. Deforce et al., Transformers in smart irrigation, Applied Soft Computing, 2024.</p
  19. R. Kumar et al., AI-based crop recommendation systems, Computers and Electronics in Agriculture, 2022.
  20. H. Zhao et al., Soil moisture prediction using ML, IEEE JSTARS, 2024.
  21. A. Katimbo et al., AI for irrigation water management, Smart Agricultural Technology, 2023
  22. M. Deshmukh et al., Crop prediction using XGBoost, ITM Web of Conferences, 2022.
  23. S. Sindiramutty et al., AI-enabled smart farming, IGI Global, 2024.
  24. L. Cheng et al., Smart agriculture for sustainability, Sustainable Cities and Society, 2024.
  25. H. Tong et al., Climate-smart agriculture evaluation, Journal of Cleaner Production, 2024.