IoT enabled mushroom farm automation to classify toxic mushrooms
IoT enabled mushroom farm automation to classify toxic mushrooms
Weather monitoring and management is a significant feature for mushroom growth, especially the impact of temperature and humidity. This paper reflects an architectural design of IoT & Machine Learning (ML)-based Smart Mushroom Farming. The proposed system introduces Remote Monitoring and Management (RMM), Farm Automation, and Mushroom classification. The Internet of Things (IoT), the microcontroller ESP32, and some agriculture-related sensors enable smart monitoring and farm automation. Machine Learning (ML) technology has been adopted to classify edible mushrooms to avoid poisonous mushrooms. To investigate the efficiency of the proposed system, several experiments have been enumerated and interpreted. The highest accuracy gained with the ensemble model is 100% which outperforms each individual classifier. However, the system will be efficient for real-time farm automation and cultivation in the mushroom industry.
Proposed methodology and working principles
The section provides the overall methodology and working principles of the proposed model. The methodology of the proposed solution is classified into three-part as follows: (1) Smart Monitoring System, (2) Farm automation, and (3) Mushroom classification with Machine Learning (ML). The IoT integration is used for monitoring and automation and controlled by a SoC as the heart of the whole configuration. The proposed model also has several temperature and humidity monitoring modules connected to the main ESP32 to ensure proper automation in the farm. The proposed model will also include a camera module and raspberry pi. Both ESP32 and raspberry pi send data to the cloud to provide the remote monitoring facility in this system.
Working principle of the smart monitoring system
For mushroom farms, room temperature and humidity are the major factors for mushroom growth. This is very crucial to monitor the temperature and humidity inside the farm from any remote places. A sensor (BME280) inside the farm is a microcontroller to sense the temperature and humidity. Each sensing module will consist of one BME280 and one ESP8266. The ESP32 SoC has been used to read the sensor data from the sensing modules for data plotting; the received data will then send to the cloud with the help of WebSockets. The users need to send a request to visualize the data in real-time from the cloud through a smart application, and the data will appear on the screen simultaneously. Any user associated with the user end application can monitor the farm status from any remote place.
Working principle of farm automation
This section covers the automation part of the proposed system. This system automates the temperature controller (air cooler), humidifier, and watering sprinkler inside the mushroom farm. The ESP32 includes real-time sensor data from sensing modules and the user’s predefined input data to automate all these types of machinery. For example, to automate the temperature inside the mushroom farm, a user sets the idle temperature. The microcontroller will compare the user’s predefined value with real-time sensor temperature data and then manipulates the air cooler. Similarly, the integration compares the value of humidity provided by the users and real-time sensor data to make decisions for manipulating humidifiers. Suppose mycelium forms a mushroom’s fruit body in the mushroom farm. In that case, the microcontroller schedules times for watering. Then, according to the schedule, the watering system will be activated for a specific period to keep the fruit body wet.
Methodology and working principles with Machine Learning (ML)- based system
This section presents the Machine Learning (ML)-based mushroom system. In the first section, the system performs image acquisition through a camera module connected with raspberry pi. As a dark environment is needed to grow up mushrooms properly, so it is hard to capture mushroom’s images in dark or low light conditions. That’s why we used some AC light bulbs as a camera flash, and the Raspberry pi controls these bulbs through relay modules. These bulbs flush only for a few seconds while capturing images. After images acquisition, the system processes the image data, and then the processed data is fed to the Machine Learning (ML)-based model. After successfully retrieving the data from the farm, the data cleaning approaches will be applied to clean the dataset’s null values. After that, the data will be sent for testing. The prebuilt model will provide the decision based on the tested data. The model provided the dataset into two significant classes such as edible and poisonous.
In the first stage, the corresponding dataset will be adopted to work with mushrooms. The data set will be cleaned with a set of data preprocessing methods. After a feature selection method will be applied to find the significant features from the dataset with Feature Important (FI) scheme. After that, the model will be trained with some conventional classifiers and an ensemble classifier. This research utilizes a set of classifiers such as Decision Tree (DT), Logistic Regression (LR), K-nearest Neighbor (KNN), Support Vector Machine (SVM), Naive Bayes (NB), and Random Forest (RF) classifier. These classifiers then merged with a voting ensemble method to find the highest accuracy of the proposed solution. After successfully establishing the classifier, a cross-validation method will be applied to evaluate the classification results and the respective experimental data. At last, a decision will be retrieved from the corresponding model to perform the mushroom classification. The Machine Learning (ML) model is built with six conventional classifiers such as: Decision Tree (DT), Logistic Regression (LR), K-nearest Neighbor (KNN), Support Vector Machine (SVM), Naive Bayes (NB), and Random Forest (RF) and an ensemble of six classifiers
Moreover, equally and adequately watering each mushroom bag is still a challenging part of mushroom farm automation. Still need to improve for makes it more efficient in the future and can be very impactful to real-life mushroom farm automation.
Reference:
Rahman, H., Faruq, M.O., Hai, T.B.A., Rahman, W., Hossain, M.M., Hasan, M., Islam, S., Moinuddin, M., Islam, M.T. and Azad, M.M., 2022. IoT enabled mushroom farm automation with Machine Learning to classify toxic mushrooms in Bangladesh. Journal of Agriculture and Food Research, 7, p.100267.