SlideShare a Scribd company logo
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3262
Application Of Machine Learning in Modern Agriculture for Crop Yield
Prediction and Fertilizer Suggestions Along with The Amount of Usage
Unnathi Suvarna. V1, Dr. Dhananjaya . V2
1 M. Tech Student, Dept of Computer Science and Engineering, Impact College of Engineering and Applied Science,
Affiliated to Visvesvaraya Technological University, Bengaluru, Karnataka, India unnathiv95@gmail.com
2 Professor, Dept of Computer Science and Engineering, Impact College of Engineering and Applied Science,
Affiliated to Visvesvaraya Technological University, Bengaluru, Karnataka, India
csdhananjay@gmail.com
--------------------------------------------------------------------***---------------------------------------------------------------------
Abstract - The use of the internet has brought vast
numbers of users online through different platforms. Unlike
the old days, the internet is not just limited to email surfing,
there’s so much on the internet or let’s say everything is on
the internet. The Internet has solutions for almost
everything, from mental health to technical issues. In this
agriculture, fields cannot be untouched. The 21st Century has
been the age of technology where technology has been used
everywhere. So, for optimum results in each field, we use
various methods which can minimize the loss and give us
maximum benefits. The application of Machine learning in
Crop type prediction for modern world farming is very much
essential. Also, suggesting the type of fertilizer and amount
can increase the usability of the application.
Crop yield prediction and fertilizer suggesting application
use machine learning algorithms to predict the crops yield
based on various aspects: like the amount of rainfall and
other different real-world parameters.
Key Words: Machine Learning, Agriculture, Crop Type,
Fertilizer, KNN, Logistic Regression, Random Forest, XGB
Classifier.
1. INTRODUCTION
A Crop Yield Prediction and Fertilizer Recommender or
simply agriculture assistance application is a model or
system where farmers get suggestions or assistance in
various aspects. The system assists farmers by providing
crop yield prediction and fertilizer suggestions. These
kinds of suggestions and predictions in real-time can help
farmers to plan their crops which can overall impact their
livelihood including annual expenses, and other aspects.
Indian farmers are majorly dependent on waterfall each
year to decide what kind of crop to sow. Each year suicide
of farmers has become one of the serious issues. A major
reason for such cases is found to be untimely rainfall,
drought, heavy rainfall, and other similar weather
conditions. Due to such reasons, farmers do not get to
harvest the crops after a whole struggle. If this is the case
all the farmers will be forced to leave their occupations and
opt for alternatives.
Agriculture and associated sectors are vital to the Indian
economy. More people are working in agriculture, either
directly or indirectly. Because of the increase in population
and the need for food, a significant amount of fertiliser is
used in soil, which may result in contamination of soil and
deterioration of soil quality, causing a variety of problems
for future generations. It is critical to evaluate the amount
of fertiliser needed for a specific crop in relation to soil
fertility. The use of fertiliser has been measured using a
variety of methods.
Following each rainfall event, there is a correlation among
rainfall intensity and nutrient loss for different fertiliser
treatments. While timely and moderate rainfall can help
dissolve dry fertiliser and move nutrients into the soil
rooting zone, excessive rain can increase runoff and
leaching of nutrients like nitrate, sulphate, chloride, and
boron.
1.1 EXISTING SYSTEM
The existing system suggests us the previous works done
in a specific domain, where we can refer to and get ideas
from. Many farming or agriculture assistance systems have
been implemented or proposed focused in only a particular
aspect or crop.
In a research paper, the scholars proposed a system to
predict the amount of fertiliser needed for a specific crop
banana, as well as regression methods for future
plantations using Neural Networks. Nitrogen (N),
phosphorus (P), and potassium (K) are the three most
important soil nutrients for crop growth. The amount of
NPK in the soil varies depending on where you live. The
requirements for each crop differ as well. In this paper, a
model is built to recommend the amount of fertiliser
needed for the banana crop [1].
In a different paper proposed system's goal is to assist
farmers in cultivating crops for higher yield. The crops
chosen for this work are based on important crops from
the chosen location. Rice, Jowar, Wheat, Soyabean,
Sunflower, Cotton, Sugarcane, Tobacco, Onion, Dry Chili,
and other crops have been chosen. Crop yield data is
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3263
compiled from various sources over the last five years.
Scholars proposed the system in 3 steps: a. Soil
Classification b. Crop Yield Prediction and c. Fertilizer
Recommendation [2].
A paper published at IEEE predicts the yield of nearly all
types of crops grown in India. This script is novel because
it uses simple parameters such as state, district, season,
and area to predict crop yields in whatever year the user
desires. The paper predicts yield using advanced
regression techniques such as Kernel Ridge, Lasso, and
ENet algorithms, as well as the concept of Stacking
Regression to improve the algorithms [3].
Rainfall regimes, P application rates, soil P content, and
field management practices such as field bund and open
ditch construction can all influence phosphorus losses in
rice-wheat cropping systems. Heavy rainfalls shortly after
P applications, in particular, cause significant P loss, and P
loss increases with increasing P application rates and soil P
content. During the rice-growing season, P concentrations
in field ponding water regulate P concentrations in surface
runoff. The construction of open ditches can increase
phosphorus loss during the winter wheat growing season.
As a result, we propose that rice-wheat cropping systems
be managed to avoid heavy rain events while also
balancing crop P removal (20–30 kg P ha–1 in this study).
Furthermore, appropriate water management practices are
recommended, such as increasing the capacity of field
ponding water or using controlled irrigation in conjunction
with natural drying of the field rather than open ditches
during the wheat growing season [4].
2. PROPOSED SYSTEM
The previously proposed methods for predicting fertiliser
type are based on crop type and crop production. The
amount of fertiliser is only classified using image data. We
propose in this paper a method for predicting the amount
and type of fertiliser based on tabular data. To predict the
amount and type of fertiliser, multiple machine learning
algorithms are used.
Fig- 1 : Proposed System
3. PROPOSED METHODOLOGY
3.1 System Design & Architecture
Fig – 2 : System Design
Dataset: A dataset containing information about fertilizer
is gained from Kaggle.
Pre-processing: Various preprocessing methods used in
the tabular dataset are done. Different techniques are
employed for preparing datasets for classification and
regression.
Model Creation and training: Different machine models
based on operation are created. Each model is trained with
the corresponding dataset.
Model Tuning: Models are compared based on metric
values. The best one is further tuned and used for the final
prediction.
Fig - 3 : Architecture
3. IMPLEMENTATION
3.1 DATASET DETAILS
Crop Name Prediction Module
Fig – 4 : Dataset for Crop Prediction
Table for Temperature, Humidity, Moisture, and Soil Type
is used as features. Crop Type is the target Label.
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3264
Fertilizer Type Prediction Module
Fig - 5 : Dataset for Fertilizer Type Prediction
All the inputs from the previous module are taken. Besides
that, the crop type given as output by the previous module
is taken, and the Nitrogen, Potassium, and Phosphorus
value is taken.
Fertilizer Amount Prediction Module
Fig - 6 : Fertilizer Amount Prediction Module
A complex feature (Total Fertilizer) is gained from the
Nitrogen, Potassium, and Phosphorus value. Since this
feature can be gained from the NPK value, these features
might be biased, so they are removed. The Crop Type and
Fertilizer Name are gained from previous modules.
3.2 ALGORITHM USED
The macro average gives each prediction a similar weight
while calculating loss but there might be cases when your
data might be imbalanced and you want to give importance
to some predictions more (based on their proportion),
there you use a 'weighted' average. So, the weighted
average value for metrics is used.
Fig – 7 : Comparison in Initial Result of different
implementation
Besides Random Forest, all other algorithms are
performing good and they have similar metric values In
order to increase model performance hyperparameter
tuning and Isolation forest is done but there is no
improvement in model performance. So, a concept of
stacking multiple models is used and there is some
improvement in the model performance.
Fig – 8 : Comparison of the result of the implementation
From the above table, it can be clearly seen that the
stacked XGB and Random Forest perform the best.
The table below provides the information about the second
part where the fertilize type prediction is done.
From the Table, it can be clearly seen that all models
perform similarly in the four basic metrics used. So, cross-
validation is used to check the model performance in a
different split of data. Among all the classifiers, XGB
Classifier performs the best.
Fig – 9 : Comparison of different parameters in the
different algorithms.
Finally, in the third module fertilizer amount is calculated
using regression models. The table provides information
about model performance.
Fig - 10 : Comparison of Model Performance.
4. OUTCOMES
Graph – 1: Plot for Fertilizer amount
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3265
Graph – 2: Soil type with Fertilizer comparison
Fig – 11: Screenshot1 of the result in web-app
Fig - 12 : Screenshot2 of the result in web-app
5. CONCLUSION
When we use stacked regression, the results are far
superior to when those models were used individually.
This system is expected to solve modern life agriculture
related problems. To make it best usable for Indian
farmers we have kept the parameters according to Indian
weather conditions. Also, system developed is more user-
friendly since it has web app as well. Use of mobile phone
is very much, so in future implementing the solution as
mobile app would be better for common use.
REFERENCES
[1] JuhiReshma, S. R., and D. John Aravindhar.
"Fertilizer Estimation using Deep Learning
Approach." NVEO-NATURAL VOLATILES &
ESSENTIAL OILS Journal| NVEO (2021): 5745-
5752.
[2] Bondre, Devdatta A., and Santosh Mahagaonkar.
"Prediction of crop yield and fertilizer
recommendation using machine learning
algorithms." International Journal of Engineering
Applied Sciences and Technology 4.5 (2019):
371-376.
[3] Potnuru Sai Nishant; Pinapa Sai Venkat; Bollu
Lakshmi Avinash; B. Jabber. “Crop Yield
Prediction based on Indian Agriculture using
Machine Learning” IEEE 2020.
[4] LIU Jian, ZUO Qiang3, ZHAI Li-mei, LUO Chun-yan,
LIU Hong-bin, WANG Hong-yuan, LIU Shen, ZOU
Guo-yuan, REN Tian-zhi. “Phosphorus losses via
surface runoff in rice-wheat cropping systems as
impacted by rainfall regimes and fertilizer
applications” Science Direct, Journal of
Integrative Agriculture 2016.
[5] Yulong Yin, Hao Ying,Huifang Zheng, Qingsong
Zhang, Yanfang Xue, Zhenling Cui. “Estimation of
NPK requirements for rice production in diverse
Chinese environments under optimal fertilization
rates.” Science Direct: Agricultural and Forest
Meteorology, Dec 2020.
[6] Ananthara, M. G., Arunkumar, T., & Hemavathy, R.
(2013, February). CRY—an improved crop yield
prediction model using bee hive clustering
approach for agricultural data sets. In 2013
International Conference on Pattern Recognition,
Informatics and Mobile Engineering (pp. 473-
478). IEEE.
[7] Awan, A. M., & Sap, M. N. M. (2006, April). An
intelligent system based on kernel methods for
crop yield prediction. In Pacific-Asia Conference
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3266
on Knowledge Discovery and Data Mining (pp.
841-846). Springer, Berlin, Heidelberg.
[8]
Bang, S., Bishnoi, R., Chauhan, A. S. , Dixit, A. K., &
Chawla, I. (2019,August). Fuzzy Logic based Crop
Yield Prediction using Temperature and Rainfall
parameters predicted through ARMA, SARIMA,
and ARMAX models. In 2019 Twelfth
International Conference on Contemporary
Computing (IC3) (pp. 1-6). IEEE.
[9] Bhosale, S. V., Thombare, R. A., Dhemey, P. G., &
Chaudhari, A. N. (2018, August). Crop Yield
Prediction Using Data Analytics and Hybrid
Approach. In 2018 Fourth International
Conference on Computing Communication
Control and Automation (ICCUBEA) (pp. 1-5).
IEEE.
[10] Gandge, Y. (2017, December). A study on various
data mining techniques for crop yield prediction.
In 2017 International Conference on Electrical,
Electronics, Communication, Computer, and
Optimization Techniques (ICEECCOT) (pp. 420-
423). IEEE.
[11] Gandhi, N., Petkar, O., & Armstrong, L. J. (2016,
July). Rice crop yield prediction using artificial
neural networks. In 2016 IEEE Technological
Innovations in ICT for Agriculture and Rural
Development (TIAR) (pp. 105-110). IEEE.
[12] Gandhi, N., Armstrong, L. J., Petkar, O., & Tripathy,
A. K. (2016, July). Rice crop yield prediction in
India using support vector machines. In 2016
13th International Joint Conference on Computer
Science and Software Engineering (JCSSE) (pp. 1-
5). IEEE
[13] Gandhi, N., Armstrong, L. J., & Petkar, O. (2016,
July). Proposed decision support system (DSS) for
I ndian rice crop yield prediction. In 2016 IEEE
Technological Innovations in ICT for Agriculture
and Rural Development (TIAR) (pp. 13-18). IEEE.
[14] Islam, T., Chisty, T. A., & Ch akrabarty, A. (2018,
December). A Deep Neural Network Approach for
Crop Selection and Yield Prediction in
Bangladesh. In 2018 IEEE Region 10
Humanitarian Technology Conference (R10-HTC)
(pp. 1-6). IEEE.
[15] Jaikla, R., Auephanwiriyakul, S. , & Jintrawet, A.
(2008, May). Rice yield prediction using a support
vecto r regression method. In 2008 5th
International Conference on Electrical
Engineering/Electronics, Computer,
Telecommunications, and Information
Technology (Vol. 1, pp. 29-32). IEEE.

More Related Content

PDF
IRJET- Survey on Crop Suggestion using Weather Analysis
PDF
IMPLEMENTATION PAPER ON AGRICULTURE ADVISORY SYSTEM
PDF
Digital Soil Mapping using Machine Learning
PDF
A COMPREHENSIVE SURVEY ON AGRICULTURE ADVISORY SYSTEM
PDF
Crop Recommendation System Using Machine Learning
PDF
IRJET- Smart Agriculture Assistant and Crop Price Pediction
PDF
IRJET- IOT in Agriculture
PDF
A Novel System for Recommending Agricultural Crops Using Machine Learning App...
IRJET- Survey on Crop Suggestion using Weather Analysis
IMPLEMENTATION PAPER ON AGRICULTURE ADVISORY SYSTEM
Digital Soil Mapping using Machine Learning
A COMPREHENSIVE SURVEY ON AGRICULTURE ADVISORY SYSTEM
Crop Recommendation System Using Machine Learning
IRJET- Smart Agriculture Assistant and Crop Price Pediction
IRJET- IOT in Agriculture
A Novel System for Recommending Agricultural Crops Using Machine Learning App...

Similar to Application Of Machine Learning in Modern Agriculture for Crop Yield Prediction and Fertilizer Suggestions Along with The Amount of Usage (20)

PDF
IRJET- Crop Yield Prediction based on Climatic Parameters
PDF
IRJET- Crop Prediction and Disease Detection
PDF
Crop Prediction System using Machine Learning
PDF
Soil Profile Based Crop Prediction System
PDF
BHARATH KISAN HELPLINE
PDF
Analysis of crop yield prediction using data mining techniques
PDF
IRJET - Agrotech: Soil Analysis and Crop Prediction
PDF
Decision support system for precision agriculture
PDF
Crop Selection Method Based on Various Environmental Factors Using Machine Le...
PDF
IRJET- Crop Prediction System using Machine Learning Algorithms
PDF
GrowFarm – Crop, Fertilizer and Disease Prediction usingMachine Learning
PDF
““Smart Crop Prediction System and Farm Monitoring System for Smart Farming””
PDF
An Overview of Crop Yield Prediction using Machine Learning Approach
PDF
Smart Irrigation System using Machine Learning and IoT
PDF
IRJET- Agricultural Data Modeling and Yield Forecasting using Data Mining...
PDF
Crop Recommendation System to Maximize Crop Yield using Machine Learning Tech...
PDF
Crop yield prediction.pdf
PDF
Agro-Farm Care – Crop, Fertilizer & Disease Prediction (Web App)
PDF
Selection of crop varieties and yield prediction based on phenotype applying ...
PPTX
Precision agriculture in maize-based cropping systems
IRJET- Crop Yield Prediction based on Climatic Parameters
IRJET- Crop Prediction and Disease Detection
Crop Prediction System using Machine Learning
Soil Profile Based Crop Prediction System
BHARATH KISAN HELPLINE
Analysis of crop yield prediction using data mining techniques
IRJET - Agrotech: Soil Analysis and Crop Prediction
Decision support system for precision agriculture
Crop Selection Method Based on Various Environmental Factors Using Machine Le...
IRJET- Crop Prediction System using Machine Learning Algorithms
GrowFarm – Crop, Fertilizer and Disease Prediction usingMachine Learning
““Smart Crop Prediction System and Farm Monitoring System for Smart Farming””
An Overview of Crop Yield Prediction using Machine Learning Approach
Smart Irrigation System using Machine Learning and IoT
IRJET- Agricultural Data Modeling and Yield Forecasting using Data Mining...
Crop Recommendation System to Maximize Crop Yield using Machine Learning Tech...
Crop yield prediction.pdf
Agro-Farm Care – Crop, Fertilizer & Disease Prediction (Web App)
Selection of crop varieties and yield prediction based on phenotype applying ...
Precision agriculture in maize-based cropping systems
Ad

More from IRJET Journal (20)

PDF
Enhanced heart disease prediction using SKNDGR ensemble Machine Learning Model
PDF
Utilizing Biomedical Waste for Sustainable Brick Manufacturing: A Novel Appro...
PDF
Kiona – A Smart Society Automation Project
PDF
DESIGN AND DEVELOPMENT OF BATTERY THERMAL MANAGEMENT SYSTEM USING PHASE CHANG...
PDF
Invest in Innovation: Empowering Ideas through Blockchain Based Crowdfunding
PDF
SPACE WATCH YOUR REAL-TIME SPACE INFORMATION HUB
PDF
A Review on Influence of Fluid Viscous Damper on The Behaviour of Multi-store...
PDF
Wireless Arduino Control via Mobile: Eliminating the Need for a Dedicated Wir...
PDF
Explainable AI(XAI) using LIME and Disease Detection in Mango Leaf by Transfe...
PDF
BRAIN TUMOUR DETECTION AND CLASSIFICATION
PDF
The Project Manager as an ambassador of the contract. The case of NEC4 ECC co...
PDF
"Enhanced Heat Transfer Performance in Shell and Tube Heat Exchangers: A CFD ...
PDF
Advancements in CFD Analysis of Shell and Tube Heat Exchangers with Nanofluid...
PDF
Breast Cancer Detection using Computer Vision
PDF
Auto-Charging E-Vehicle with its battery Management.
PDF
Analysis of high energy charge particle in the Heliosphere
PDF
Auto-Charging E-Vehicle with its battery Management.
PDF
Analysis of high energy charge particle in the Heliosphere
PDF
Wireless Arduino Control via Mobile: Eliminating the Need for a Dedicated Wir...
PDF
FIR filter-based Sample Rate Convertors and its use in NR PRACH
Enhanced heart disease prediction using SKNDGR ensemble Machine Learning Model
Utilizing Biomedical Waste for Sustainable Brick Manufacturing: A Novel Appro...
Kiona – A Smart Society Automation Project
DESIGN AND DEVELOPMENT OF BATTERY THERMAL MANAGEMENT SYSTEM USING PHASE CHANG...
Invest in Innovation: Empowering Ideas through Blockchain Based Crowdfunding
SPACE WATCH YOUR REAL-TIME SPACE INFORMATION HUB
A Review on Influence of Fluid Viscous Damper on The Behaviour of Multi-store...
Wireless Arduino Control via Mobile: Eliminating the Need for a Dedicated Wir...
Explainable AI(XAI) using LIME and Disease Detection in Mango Leaf by Transfe...
BRAIN TUMOUR DETECTION AND CLASSIFICATION
The Project Manager as an ambassador of the contract. The case of NEC4 ECC co...
"Enhanced Heat Transfer Performance in Shell and Tube Heat Exchangers: A CFD ...
Advancements in CFD Analysis of Shell and Tube Heat Exchangers with Nanofluid...
Breast Cancer Detection using Computer Vision
Auto-Charging E-Vehicle with its battery Management.
Analysis of high energy charge particle in the Heliosphere
Auto-Charging E-Vehicle with its battery Management.
Analysis of high energy charge particle in the Heliosphere
Wireless Arduino Control via Mobile: Eliminating the Need for a Dedicated Wir...
FIR filter-based Sample Rate Convertors and its use in NR PRACH
Ad

Recently uploaded (20)

PDF
R24 SURVEYING LAB MANUAL for civil enggi
PPTX
Fundamentals of safety and accident prevention -final (1).pptx
PDF
Categorization of Factors Affecting Classification Algorithms Selection
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PDF
PPT on Performance Review to get promotions
PDF
SMART SIGNAL TIMING FOR URBAN INTERSECTIONS USING REAL-TIME VEHICLE DETECTI...
PDF
BIO-INSPIRED ARCHITECTURE FOR PARSIMONIOUS CONVERSATIONAL INTELLIGENCE : THE ...
PDF
86236642-Electric-Loco-Shed.pdf jfkduklg
PPTX
Fundamentals of Mechanical Engineering.pptx
PPT
Introduction, IoT Design Methodology, Case Study on IoT System for Weather Mo...
PPTX
Safety Seminar civil to be ensured for safe working.
PPT
Occupational Health and Safety Management System
PPTX
UNIT - 3 Total quality Management .pptx
PDF
Level 2 – IBM Data and AI Fundamentals (1)_v1.1.PDF
PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
PPTX
CURRICULAM DESIGN engineering FOR CSE 2025.pptx
PPTX
Nature of X-rays, X- Ray Equipment, Fluoroscopy
PPTX
UNIT 4 Total Quality Management .pptx
PDF
737-MAX_SRG.pdf student reference guides
R24 SURVEYING LAB MANUAL for civil enggi
Fundamentals of safety and accident prevention -final (1).pptx
Categorization of Factors Affecting Classification Algorithms Selection
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PPT on Performance Review to get promotions
SMART SIGNAL TIMING FOR URBAN INTERSECTIONS USING REAL-TIME VEHICLE DETECTI...
BIO-INSPIRED ARCHITECTURE FOR PARSIMONIOUS CONVERSATIONAL INTELLIGENCE : THE ...
86236642-Electric-Loco-Shed.pdf jfkduklg
Fundamentals of Mechanical Engineering.pptx
Introduction, IoT Design Methodology, Case Study on IoT System for Weather Mo...
Safety Seminar civil to be ensured for safe working.
Occupational Health and Safety Management System
UNIT - 3 Total quality Management .pptx
Level 2 – IBM Data and AI Fundamentals (1)_v1.1.PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
CURRICULAM DESIGN engineering FOR CSE 2025.pptx
Nature of X-rays, X- Ray Equipment, Fluoroscopy
UNIT 4 Total Quality Management .pptx
737-MAX_SRG.pdf student reference guides

Application Of Machine Learning in Modern Agriculture for Crop Yield Prediction and Fertilizer Suggestions Along with The Amount of Usage

  • 1. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3262 Application Of Machine Learning in Modern Agriculture for Crop Yield Prediction and Fertilizer Suggestions Along with The Amount of Usage Unnathi Suvarna. V1, Dr. Dhananjaya . V2 1 M. Tech Student, Dept of Computer Science and Engineering, Impact College of Engineering and Applied Science, Affiliated to Visvesvaraya Technological University, Bengaluru, Karnataka, India unnathiv95@gmail.com 2 Professor, Dept of Computer Science and Engineering, Impact College of Engineering and Applied Science, Affiliated to Visvesvaraya Technological University, Bengaluru, Karnataka, India csdhananjay@gmail.com --------------------------------------------------------------------***--------------------------------------------------------------------- Abstract - The use of the internet has brought vast numbers of users online through different platforms. Unlike the old days, the internet is not just limited to email surfing, there’s so much on the internet or let’s say everything is on the internet. The Internet has solutions for almost everything, from mental health to technical issues. In this agriculture, fields cannot be untouched. The 21st Century has been the age of technology where technology has been used everywhere. So, for optimum results in each field, we use various methods which can minimize the loss and give us maximum benefits. The application of Machine learning in Crop type prediction for modern world farming is very much essential. Also, suggesting the type of fertilizer and amount can increase the usability of the application. Crop yield prediction and fertilizer suggesting application use machine learning algorithms to predict the crops yield based on various aspects: like the amount of rainfall and other different real-world parameters. Key Words: Machine Learning, Agriculture, Crop Type, Fertilizer, KNN, Logistic Regression, Random Forest, XGB Classifier. 1. INTRODUCTION A Crop Yield Prediction and Fertilizer Recommender or simply agriculture assistance application is a model or system where farmers get suggestions or assistance in various aspects. The system assists farmers by providing crop yield prediction and fertilizer suggestions. These kinds of suggestions and predictions in real-time can help farmers to plan their crops which can overall impact their livelihood including annual expenses, and other aspects. Indian farmers are majorly dependent on waterfall each year to decide what kind of crop to sow. Each year suicide of farmers has become one of the serious issues. A major reason for such cases is found to be untimely rainfall, drought, heavy rainfall, and other similar weather conditions. Due to such reasons, farmers do not get to harvest the crops after a whole struggle. If this is the case all the farmers will be forced to leave their occupations and opt for alternatives. Agriculture and associated sectors are vital to the Indian economy. More people are working in agriculture, either directly or indirectly. Because of the increase in population and the need for food, a significant amount of fertiliser is used in soil, which may result in contamination of soil and deterioration of soil quality, causing a variety of problems for future generations. It is critical to evaluate the amount of fertiliser needed for a specific crop in relation to soil fertility. The use of fertiliser has been measured using a variety of methods. Following each rainfall event, there is a correlation among rainfall intensity and nutrient loss for different fertiliser treatments. While timely and moderate rainfall can help dissolve dry fertiliser and move nutrients into the soil rooting zone, excessive rain can increase runoff and leaching of nutrients like nitrate, sulphate, chloride, and boron. 1.1 EXISTING SYSTEM The existing system suggests us the previous works done in a specific domain, where we can refer to and get ideas from. Many farming or agriculture assistance systems have been implemented or proposed focused in only a particular aspect or crop. In a research paper, the scholars proposed a system to predict the amount of fertiliser needed for a specific crop banana, as well as regression methods for future plantations using Neural Networks. Nitrogen (N), phosphorus (P), and potassium (K) are the three most important soil nutrients for crop growth. The amount of NPK in the soil varies depending on where you live. The requirements for each crop differ as well. In this paper, a model is built to recommend the amount of fertiliser needed for the banana crop [1]. In a different paper proposed system's goal is to assist farmers in cultivating crops for higher yield. The crops chosen for this work are based on important crops from the chosen location. Rice, Jowar, Wheat, Soyabean, Sunflower, Cotton, Sugarcane, Tobacco, Onion, Dry Chili, and other crops have been chosen. Crop yield data is
  • 2. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3263 compiled from various sources over the last five years. Scholars proposed the system in 3 steps: a. Soil Classification b. Crop Yield Prediction and c. Fertilizer Recommendation [2]. A paper published at IEEE predicts the yield of nearly all types of crops grown in India. This script is novel because it uses simple parameters such as state, district, season, and area to predict crop yields in whatever year the user desires. The paper predicts yield using advanced regression techniques such as Kernel Ridge, Lasso, and ENet algorithms, as well as the concept of Stacking Regression to improve the algorithms [3]. Rainfall regimes, P application rates, soil P content, and field management practices such as field bund and open ditch construction can all influence phosphorus losses in rice-wheat cropping systems. Heavy rainfalls shortly after P applications, in particular, cause significant P loss, and P loss increases with increasing P application rates and soil P content. During the rice-growing season, P concentrations in field ponding water regulate P concentrations in surface runoff. The construction of open ditches can increase phosphorus loss during the winter wheat growing season. As a result, we propose that rice-wheat cropping systems be managed to avoid heavy rain events while also balancing crop P removal (20–30 kg P ha–1 in this study). Furthermore, appropriate water management practices are recommended, such as increasing the capacity of field ponding water or using controlled irrigation in conjunction with natural drying of the field rather than open ditches during the wheat growing season [4]. 2. PROPOSED SYSTEM The previously proposed methods for predicting fertiliser type are based on crop type and crop production. The amount of fertiliser is only classified using image data. We propose in this paper a method for predicting the amount and type of fertiliser based on tabular data. To predict the amount and type of fertiliser, multiple machine learning algorithms are used. Fig- 1 : Proposed System 3. PROPOSED METHODOLOGY 3.1 System Design & Architecture Fig – 2 : System Design Dataset: A dataset containing information about fertilizer is gained from Kaggle. Pre-processing: Various preprocessing methods used in the tabular dataset are done. Different techniques are employed for preparing datasets for classification and regression. Model Creation and training: Different machine models based on operation are created. Each model is trained with the corresponding dataset. Model Tuning: Models are compared based on metric values. The best one is further tuned and used for the final prediction. Fig - 3 : Architecture 3. IMPLEMENTATION 3.1 DATASET DETAILS Crop Name Prediction Module Fig – 4 : Dataset for Crop Prediction Table for Temperature, Humidity, Moisture, and Soil Type is used as features. Crop Type is the target Label.
  • 3. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3264 Fertilizer Type Prediction Module Fig - 5 : Dataset for Fertilizer Type Prediction All the inputs from the previous module are taken. Besides that, the crop type given as output by the previous module is taken, and the Nitrogen, Potassium, and Phosphorus value is taken. Fertilizer Amount Prediction Module Fig - 6 : Fertilizer Amount Prediction Module A complex feature (Total Fertilizer) is gained from the Nitrogen, Potassium, and Phosphorus value. Since this feature can be gained from the NPK value, these features might be biased, so they are removed. The Crop Type and Fertilizer Name are gained from previous modules. 3.2 ALGORITHM USED The macro average gives each prediction a similar weight while calculating loss but there might be cases when your data might be imbalanced and you want to give importance to some predictions more (based on their proportion), there you use a 'weighted' average. So, the weighted average value for metrics is used. Fig – 7 : Comparison in Initial Result of different implementation Besides Random Forest, all other algorithms are performing good and they have similar metric values In order to increase model performance hyperparameter tuning and Isolation forest is done but there is no improvement in model performance. So, a concept of stacking multiple models is used and there is some improvement in the model performance. Fig – 8 : Comparison of the result of the implementation From the above table, it can be clearly seen that the stacked XGB and Random Forest perform the best. The table below provides the information about the second part where the fertilize type prediction is done. From the Table, it can be clearly seen that all models perform similarly in the four basic metrics used. So, cross- validation is used to check the model performance in a different split of data. Among all the classifiers, XGB Classifier performs the best. Fig – 9 : Comparison of different parameters in the different algorithms. Finally, in the third module fertilizer amount is calculated using regression models. The table provides information about model performance. Fig - 10 : Comparison of Model Performance. 4. OUTCOMES Graph – 1: Plot for Fertilizer amount
  • 4. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3265 Graph – 2: Soil type with Fertilizer comparison Fig – 11: Screenshot1 of the result in web-app Fig - 12 : Screenshot2 of the result in web-app 5. CONCLUSION When we use stacked regression, the results are far superior to when those models were used individually. This system is expected to solve modern life agriculture related problems. To make it best usable for Indian farmers we have kept the parameters according to Indian weather conditions. Also, system developed is more user- friendly since it has web app as well. Use of mobile phone is very much, so in future implementing the solution as mobile app would be better for common use. REFERENCES [1] JuhiReshma, S. R., and D. John Aravindhar. "Fertilizer Estimation using Deep Learning Approach." NVEO-NATURAL VOLATILES & ESSENTIAL OILS Journal| NVEO (2021): 5745- 5752. [2] Bondre, Devdatta A., and Santosh Mahagaonkar. "Prediction of crop yield and fertilizer recommendation using machine learning algorithms." International Journal of Engineering Applied Sciences and Technology 4.5 (2019): 371-376. [3] Potnuru Sai Nishant; Pinapa Sai Venkat; Bollu Lakshmi Avinash; B. Jabber. “Crop Yield Prediction based on Indian Agriculture using Machine Learning” IEEE 2020. [4] LIU Jian, ZUO Qiang3, ZHAI Li-mei, LUO Chun-yan, LIU Hong-bin, WANG Hong-yuan, LIU Shen, ZOU Guo-yuan, REN Tian-zhi. “Phosphorus losses via surface runoff in rice-wheat cropping systems as impacted by rainfall regimes and fertilizer applications” Science Direct, Journal of Integrative Agriculture 2016. [5] Yulong Yin, Hao Ying,Huifang Zheng, Qingsong Zhang, Yanfang Xue, Zhenling Cui. “Estimation of NPK requirements for rice production in diverse Chinese environments under optimal fertilization rates.” Science Direct: Agricultural and Forest Meteorology, Dec 2020. [6] Ananthara, M. G., Arunkumar, T., & Hemavathy, R. (2013, February). CRY—an improved crop yield prediction model using bee hive clustering approach for agricultural data sets. In 2013 International Conference on Pattern Recognition, Informatics and Mobile Engineering (pp. 473- 478). IEEE. [7] Awan, A. M., & Sap, M. N. M. (2006, April). An intelligent system based on kernel methods for crop yield prediction. In Pacific-Asia Conference
  • 5. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 05 | May 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page3266 on Knowledge Discovery and Data Mining (pp. 841-846). Springer, Berlin, Heidelberg. [8] Bang, S., Bishnoi, R., Chauhan, A. S. , Dixit, A. K., & Chawla, I. (2019,August). Fuzzy Logic based Crop Yield Prediction using Temperature and Rainfall parameters predicted through ARMA, SARIMA, and ARMAX models. In 2019 Twelfth International Conference on Contemporary Computing (IC3) (pp. 1-6). IEEE. [9] Bhosale, S. V., Thombare, R. A., Dhemey, P. G., & Chaudhari, A. N. (2018, August). Crop Yield Prediction Using Data Analytics and Hybrid Approach. In 2018 Fourth International Conference on Computing Communication Control and Automation (ICCUBEA) (pp. 1-5). IEEE. [10] Gandge, Y. (2017, December). A study on various data mining techniques for crop yield prediction. In 2017 International Conference on Electrical, Electronics, Communication, Computer, and Optimization Techniques (ICEECCOT) (pp. 420- 423). IEEE. [11] Gandhi, N., Petkar, O., & Armstrong, L. J. (2016, July). Rice crop yield prediction using artificial neural networks. In 2016 IEEE Technological Innovations in ICT for Agriculture and Rural Development (TIAR) (pp. 105-110). IEEE. [12] Gandhi, N., Armstrong, L. J., Petkar, O., & Tripathy, A. K. (2016, July). Rice crop yield prediction in India using support vector machines. In 2016 13th International Joint Conference on Computer Science and Software Engineering (JCSSE) (pp. 1- 5). IEEE [13] Gandhi, N., Armstrong, L. J., & Petkar, O. (2016, July). Proposed decision support system (DSS) for I ndian rice crop yield prediction. In 2016 IEEE Technological Innovations in ICT for Agriculture and Rural Development (TIAR) (pp. 13-18). IEEE. [14] Islam, T., Chisty, T. A., & Ch akrabarty, A. (2018, December). A Deep Neural Network Approach for Crop Selection and Yield Prediction in Bangladesh. In 2018 IEEE Region 10 Humanitarian Technology Conference (R10-HTC) (pp. 1-6). IEEE. [15] Jaikla, R., Auephanwiriyakul, S. , & Jintrawet, A. (2008, May). Rice yield prediction using a support vecto r regression method. In 2008 5th International Conference on Electrical Engineering/Electronics, Computer, Telecommunications, and Information Technology (Vol. 1, pp. 29-32). IEEE.