GithubHelp home page GithubHelp logo

sudoshivam / crop-prediction-model Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 1.0 4.37 MB

A machine learning model to recommend suitable crops based on soil health conditions.

Home Page: crop-prediction-model.vercel.app

Python 64.90% CSS 25.69% HTML 9.41%
crop-recommendation logistic-regression machine-learning

crop-prediction-model's Introduction

Crop Recommendation Model

A machine learning model to analyze soil parameters and recommend suitable crops. It uses Logistic Regression to predict crops based on the following 7 input parameters.

  1. Nitrogen (N)
  2. Phosphorus (P)
  3. Potassium (K)
  4. Temperature
  5. Humidity
  6. pH Value
  7. Rainfall
  • The N-P-K values are ratio between Nitrogen, Phosphorous and Potassium. This means if soil contains 3% nitrogen (N), 2% phosphorus (P) and 5% potassium (K) then its NPK value is 3-2-5.
  • Temperature, Humidity and Rainfall data can be acquired from weather portal or IoT sensors.
  • pH value is used to measure if soil is naturally acidic or alkaline. This data is acquired by testing soil in lab.

Dataset Sample

Dataset Sample

Usage

Enter all parameters in respective input boxes (Make sure all input values are rounded to nearest integer). Enter Parameters

Click on Predict. enter image description here The model will analyze input parameters and predict the most suitable crop for given soil condition.

Run Locally

  • Make sure git is installed.
  • Clone the project by running following command in cmd or terminal: git clone https://github.com/sudoshivam/crop-prediction-model.git or you can simply download the entire repo as zip.
  • Install Anaconda or miniconda and create an environment with Python 3.6. Refer this tutorial on how to create an environment in conda.
  • Activate environment.
  • Install required libraries by running following commands:
    • Scikit-Learn pip install -U scikit-learn.
    • NumPy pip install numpy.
    • Flask pip install Flask.
  • Open new anaconda prompt in project folder and run following command: python app.py
  • Now project will start running in the terminal. Copy the URL provided in terminal and open it into a web browser to use the application.

crop-prediction-model's People

Contributors

sudoshivam avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

abhin2002

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.