Code Monkey home page Code Monkey logo

farmml's Introduction

A revolutionary way to farm crops.

A machine learning model for crop recommendation.

https://youtu.be/nAfO0CTmQ1s

alt text

alt text

Developed during hackTX 2022.

To run the app:

  • download al the files and keep the same folder structure.
  • in your terminal, go to the folder that contains these files
  • run export FLASK_APP=app.py
  • run flask run
  • copy the URL that is printed in the terminal, and paste it into a browser

Inspiration

Recently, there has been a trend of lower agricultural engagement: lower employment over time (here) combined with increasing urbanization and a changing climate has led to stress on food production and farmers' livelihoods. Its in this way, we want to help farmers maximize the efficiency of their land use, allowing food production to be continued more sustainably in a changing, challenging future.

alt text

What it does

Farmers can input baseline indicators of their soil quality--ratio of nitrogen, phosphorous, potassium, pH--as well as their regional temperature, humidity, and average rainfall. Then, farmers receive a recommendation for a crop type most suitable to maximize productivity and profitability for the farmer.

How we built it

We primarily utilized a K-nearest-neighbor model as the machine learning algorithm to learn from our training data. For the web-application, we used HTML and CSS as well as Flask to create our tool.

Challenges we ran into

Initially, we experienced a lot of trouble identifying the right dataset to fit our problem scope. On the World In Data (website), there were many potential datasets, but they failed to provide us with the right input variables or were very hard to use. In the end, we used Crop Recommendation Dataset on Kaggle.

Another issue we ran into was connecting the front end and back end (a.k.a. transmitting inputs from the user to python script and getting the return value to the web app). However, this challenge was also where our group learned the most, and we eventually implemented a full-stack design.

Accomplishments that we're proud of

We have 97.7% accuracy for our KNN model (validated for the testing data split).

What we learned

  • Front end and full-stack implementation
  • Strengths and weaknesses of several machine learning algorithms
  • Evaluating the quality of different datasets

What's next for FarmML

We plan on branching out to a more diverse selection of crops and using region-specific crop data/availability of crops to farmers for a more customized recommendation.

We could also factor in the sustainability of each crop to the environment, or recommend sustainable farm practices such as crop rotation for predicting crop types in concurrent years.

Built With

css flask html5 javascript keras machine-learning python tensorflow

farmml's People

Contributors

adi-panda avatar

Stargazers

Harshit Singh avatar  avatar

Watchers

 avatar

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.