How salujadivyam/indigrow works
Main Components
• Frontend: Represented by the “frontend.py” module and built using PyCutify for an engaging UI. This includes the homepage (with the Indigrow logo) and the dashboard where farmers input information.
• Backend: Denoted by “backend.py”. This is the central processing unit that handles data from the frontend, invokes machine learning models (using Scikit-learn, Pandas, NumPy), and integrates various services.
• Geolocation & Satellite Imagery Module: The “Shreyansh” directory contains “latitude.py” and “reference.py”, likely responsible for handling geospatial data using tools like Geopy, Selenium, and Folium to retrieve satellite imagery.
• Data and Information Sources: CSV files (e.g., “updated_india_agriculture_dataset.csv” in the Shreyansh folder and “sources/backend_dataset.csv”) serve as databases for crop, soil, fertilizer, and perhaps historical yield data.
• Weather Integration: The “weather.py” module interfaces with the OpenWeatherMap API to fetch real-time weather data and rain probability analysis.
• Additional Utilities: “text_to_speech.py” may add an accessibility or notification layer by converting text-based advice into speech.
Relationships and Interactions
• Frontend ↔ Backend: Detail how the user interface captures input (e.g., state, district, soil type, current crop) and sends it to the backend for processing.
• Backend Processing: Show that the backend calls on geolocation modules (latitude.py and reference.py) to determine the precise location, utilizes the weather API via weather.py for relevant updates, and then engages machine learning libraries to generate recommendations.
• Integration with External APIs: Illustrate connections from the backend to the OpenWeatherMap API (for weather information) and possibly to satellite imagery services through Selenium and Folium mechanisms.
• Utility Services: Optionally include the text-to-speech component, highlighting how processed recommendations can be converted to audio output for user accessibility.
Architectural Patterns and Design Principles
• Layered Architecture: The separation between presentation (frontend) and business logic (backend) should be evident. You might also represent the data access layer (CSV datasets and any internal data structures).
• Modular Design: The presence of separate modules (e.g., for geolocation, weather, machine learning) indicates a modular and maintainable structure.
• Reusability and Extensibility: The file structure suggests that components (especially those in the Shreyansh directory) are reusable, which ties in with the project’s future intent to integrate IoT and mobile applications.
• From the “Frontend” to the “Backend” (user inputs submission).
• From “Backend” to external services like “Weather API” and geolocation functions.
• From “CSV Data Sources” to “Backend” for analytical processes.
• From “Backend” back to the “Frontend” for displaying recommendations.
• For detailed clarity, include sub-components inside the Backend area to denote modules responsible for machine learning, geolocation and satellite imagery retrieval, weather data processing, and eventually text-to-speech conversion.