SlideShare a Scribd company logo
1 of 5
Download to read offline
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1247
Food Quality Detection And Calorie Estimation Using Machine Learning
Prakash R1, Vadlapatla Sathvik2, Potru Teja Sri Venkata Satya Sai3 , Pothireddy Gopichand
Reddy4
1Assitant Professor Sr.Grade1, SENSE, Vellore Institute Of Technology, Katpadi, Tamil Nadu-632014
2,3,4 Student, SENSE, Vellore Institute Of Technology, Katpadi, Tamil Nadu-632014
---------------------------------------------------------------------***---------------------------------------------------------------------
Abstract - Many states in India lack proper food supply to
the poor. Many NGOs and non-profitable organizations
work towards feeding the homeless and needy. But they lack
funding and hence proper food storage facilities and
maintenance is scarce. This project mainly focuses on
helping these organizations to keep the food in check and
serve unspoiled food. It also keeps track of the calories so a
well-balanced diet food is given.
Key Words: food safety, calorie estimation, machine
learning, oxygen sensor, MQ3 sensor, IOT.
1. INTRODUCTION
In this modern era of science of technology, the food
sector is facing one of the major problems that is food
spoilage. food items such as fruits, vegetables and meat
are going stale .The bigger problem is these spoiled items
going undetected and onto the hands of the consumer .
Hence, there is a need for an automated process that
would not only increase the accuracy of spoiled food
detection, but also estimating calories present in it.
This project mainly focuses on helping NGO’s and
organizations to keep their food in check and serve
unspoiled food. It also aims at keeping track of the calories
so a wellbalanced diet food is given. We are also designing
a mobile app which can be used to fetch data about
calories of different vegetables and fruits for the users by
uploading the image of any vegetables or fruits so as to
keep track of their calories and maintain a healthy
balanced diet.
In details, to automate this process, we are planning on
using a collection of smart sensors like temperature
sensor, MQ3 sensor with microcontroller like the Node
MCU. On detection of a spoiled or stale food item, a sound
buzzer will ring and a
LED light will glow to draw attention, we developed an
app, as an application of IoT. This enables consumers to
view the name of fruit or vegetable and also with the help
of developing app we can estimate the amount of calories
present in it.
In addition, the app classifies the image, predicts the
name of the fruit or the vegetable and gives the calories
associated with it. The frontend-backend is handled by the
Streamlit. The user can visit the application by URL. The
user can use the upload button upload button to upload
the image.
2. LITERAUTRE SURVEY
There have been previous papers on different fields on
food spoilage and calorie estimation.[1] An Arduino
sensor-based approach for detecting the food spoilage A
project on monitoring temperature in a small server room
have been implemented previously. The data is sent online
and if the values exceed a limit, the system turns the
conditioning systems on and makes the temperature in the
threshold values This paper is an IOT based consisting of a
microcontroller Arduino Uno, Bluetooth module, electrical
and biosensor like pH sensor, dampness sensor, and gas
sensors. DHT- 11 is used to measure temperature and
moistness, MQ2 to distinguish liquor content is linked with
Arduino board. This is an IoT based system, sends
necessary information to user through ESP8266 Wi-Fi.
Here they focus on keeping the food storage surrounding
to the optimal conditions [2] Iot based smart weighing
system for crate in agriculture. [3] A new deep learning
based food recognition system for dietary assessment on
an edge computing service infrastructure.
Chang Liu, Yu Cao , Senior Member, IEEE, Yan Luo,
Member, IEEE, Guanling Chen, Member, IEEE, Vinod
Vokkarane, Senior Member, IEEE, Ma Yunsheng, Song qing
Chen, Member, IEEE, This paper focuses on nutritional
estimation of food using the visual based food recognition
algorithms using edge computing. The project uses a visual
sensor for capturing the food image, the mobile phone for
the image preprocessing and segmentation and the server
(cloud layer) with the pre trained CNN model and image
classification. The multiple-stage food recognition system
includes Image preprocessing in the front-end component
and the Image segmentation in the front-end component
(CNN based food image analysis) Every living being on
earth is essentially dependent on nutrition to stay alive.
Each individual cell needs energy to continue its vital
activities such as growth, development and renewal of
damages. Environmental conditions, for instance humidity
and temperature allow organisms to spread inside food,
these bacterial activities cause unwanted food spoilage
which may be harmful for human health. [1].In India Data
analysis showed that states of West Bengal (31.22),
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1248
Karnataka (29.11) and Gujarat (22.67) reported maximum
average outbreaks and contributed to 31.5% illnesses and
8.7% deaths. Detecting food spoilage from production to
consumption stages is very crucial. There is indeed an
urgent need for fast and accurate systems, while
conventional spoilage detection techniques are slow and
time consuming [2]. As a result, new vision based
techniques and algorithmic approaches have been
proposed in the last decades. The most recently developed
methods for detecting. Food spoilage are based on digital
image processing, by using nano technology and state-of-
the-art machine learning, which have already proven their
high potential in the food industry. Here for food spoilage
detection we are using nanotechnology,[3].
Nanotechnology based sensing approaches are capable of
providing selective and specific information on the
presence and amount of pathogens and toxins.in this
project we are using MQ3 sensor [4].This MQ3 sensor that
is used to detect the presence of toxic gas acetone and
ethanol in the spoiled food. And also we are using oxygen
sensor which tells us that [5] if food item is inhabited by
germs ,the oxygen levels in the immediate surrounding is
going to be lower than it normally is .The introduction of
these sensors into food detection technology has paved the
way for smart food detection. These sensors will be
integrated with [6]Arduino uno board which is a popular
prototyping board measures and sends data to iot
platform.
3. PROPOSED MODEL DESCRIPTION
In our proposed work, we aim at detecting spoilage in
food items as a part of hardware and estimating calories in
food as a part of software. With the help of sensor nodes
placed near food items methane range and temperature
data can be collected at regular intervals. In this project
we have used industrial MQ3 and temperature sensors.
NodeMCU is with Arduino Uno boards.
In the block diagram, MQ3 and oxygen/temperature
sensor is connected to the Arduino boards and hence gets
connected to the Node MCU. Finally the data is shown on
the blynk app and at the same time the buzzers are turned
on to indicate spoilage of food if the values exceed the
threshold.
For the software part, it is a simple web application in
which the user needs to upload the Image of any fruit or
vegetable. The system next automatically classifies the
Image and gives the prediction about the name of the fruit
or vegetable, and also gives the calories of the object. The
frontend-backend will be handled by the Streamlit. The
user can visit the application by URL. There will be upload
button for the user to upload the image.
Fig -1: Process Flowchart
4. TECHINCAL SPECIFICATIONS
Our proposed work consists of 2 parts – hardware and
software The hardware consists of a MQ3 sensor along
with temperature for methane extent and temperature
measurement respectively, Arduino UNO and nodeMCU
for acquiring data from sensors and sending to the
Arduino IDE. A buzzer and two LED, s are connected to the
Arduino UNO for indicating the spoilage of the food and
blynk app for displaying the methane and temperature
data.
The frontend and backend of the web app is handled by
the StreamLit. It is a simple web application in which the
user needs to upload the Image of any fruit or vegetable.
The system next automatically classifies the Image and
gives the prediction about the name of the fruit or
vegetable, and also about their respective calories.
The user will first upload the Image. That image Will be
stored into the local system. Then pillow will resize the
image according to our model shape, it will convert into
vector. Now this vector will be passed to our model, our
model will classify the class of category. We will get the ID
of category, now we need to map the labels according to
the ID. Now our system will do web-scrap the calories for
predicted object. Our application will display the Result
and Calories into our application.
Fig -2: Flowchart
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1249
5.HARDWARE
5.1. Arduino UNO
Arduino is an open source platform used for building
electronic projects.it is a company.it is basically a
microcontroller. generally a microcontroller is difficult to
use and programming needs some experience. whereas it
comes as module with necessary pins and sockets
connected with microcontroller along with IDE in easy
programming language making it easier for small project
applications.
5.2. MQ3 sensor
MQ standards for having sensitivity towards gas. It is
made up of metal oxide semiconductors. MQ sensor are
called chemo resistor because sensor values change
according to change in resistance of gas. Specifications of
MQ3 sensor are it operates 5V dc and draw 800 Mw,
sensor resistance from 1M to 8MΩ, load resistance is
200kΩ. This module has 4 pins Analog Output (A0), Digital
Output (D0), VCC, GND pins. The A0 pin output will be
varied according to concentration of gas, when
concentration of gas is high, output of A0 pin is high and
vice versa for low concentration of gas.
5.3. ESP8266 Node MCU
NodeMCU is a low-cost open source IoT platform. It
initially included firmware which runs on the ESP8266
Wi-Fi SoC from Espressif Systems, and hardware which
was based on the ESP-12 module. Later, support for the
ESP32 32bit MCU was added.
5.4. Piezoelectric Buzzer
A piezoelectric speaker is a loudspeaker that uses the
piezoelectric effect for generating sound. The initial
mechanical motion is created by applying a voltage to a
piezoelectric material.
5.5. Temperature sensor
A temperature sensor is a device used to measure
temperature. This can be air temperature, liquid
temperature or The temperature of solid matter. The basic
principle of working of the temp. sensors is the voltage
across the diode terminals. If the voltage increases, the
temperature also rises, followed by a voltage drop
between the transistor terminals of base and emitter in a
diode. Here we have used a thermistor in this project
model.
Fig -3: Hardware Circuit
6.SOFTWARE
6.1.PyCharm
PyCharm is an integrated development environment used
in computer programming, specifically for the Python
programming language. It provides code analysis, a
graphical debugger, an integrated unit tester, integration
with version, and supports web development with Django
as well as data science.
6.2.Kaggle
Kaggle is world’s largest data set community with powerful
tools and resources to help to achieve one’s data science
goals. It allows users to find and publish data sets, explore
and build models in a web-based data-science
environment, work with other data scientists and machine
learning engineers, and enter.
6.3.Web App
The web app contains a signup, login and main webpage.
which the user needs to upload the Image of any fruit or
vegetable. The system next automatically classifies the
the Image and gives the prediction about the name of the
competitions to solve data science challenges. Fruit or
vegetable and also about their respective calories.
Fig -4: Calorie estimation Web App
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1250
7. RESULTS
7.1.Hardware
All the connections are successfully made and Arduino and
nodeMCU is turned on. The sensors are brought close to a
sample of food. The sensors connected to the Arduino
polls data from both the sensors. This data is sent to the
nodeMCU which the sends the data to the blynk app via
IDE code. On detection of a spoiled or stale food item a
buzzer sound will ring and a LED light will glow, notified
through blynk app via the Arduino.
Fig -5: Arduino IDE code
Fig -6: Methane And Temperature data values
Fig -7: Food Spoil Alert
Fig -8: Blynk App output reading
7.2.Software
The user will first upload the Image. That image Will be
stored into the local system. Then pillow will resize the
image according to our model shape, it will convert into
vector. Now this vector will be passed to our model, our
model will classify the class of category. We will get the ID
of category, now we need to map the labels according to
the ID. Now our system will do web-scrap the calories for
predicted object. Our application will display the Result
and Calories into our website.
Fig -9: Prediction and calories estimation of banana
The user will first upload the Image. That image Will be
stored into the local system. Then pillow will resize the
International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056
Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072
© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1251
image according to our model shape, it will convert into
vector. Now this vector will be passed to our model, our
model will classify the class of category. We will get the ID
of category, now we need to map the labels according to
the ID. Now our system will do web-scrap the calories for
predicted object. Our application will display the Result
and Calories into our application.
Fig -10: Prediction and calories estimation of carrot
8. CONCLUSION AND FUTURE SCOPE
We were able to detect spoilt food with the help of the
proposed hardware model and also able to predict and
calculate calories of different fruits and vegetables with
the help of the software model. We can further detect
spoilage of food for wider range of food items by
increasing the number and types of sensors used in the
project. For the software model we can further make it
accurate for detection spoilage of food when uploaded a
real time picture of a spoilt or stale food.
9. REFERENCES
[1] A surveillance of food borne disease outbreaks in
India
https://www.sciencedirect.com/science/article/abs/p
i i/S0956713520305466?via%3 Dihub
[2] B. Fletcher and et al., “Advances in meat spoilage
detection: A short focus on rapid methods and
technologies,” J. Food, vol. 16(1), pp. 1037– 1044,
2018.
https://doi.org/10.1080/19476337.2018.1525432
[3] Mustafa F., Hassan R.Y., Andreescu S. Multifunctional
nanotechnology- enabled sensors for rapid capture
and detection of pathogens. Sensors. 2017;17:2121.
https://doi.org/10.3390/s17092121
[4] “Automatic Food Spoilage Detection”, International
Journal of Emerging Technologies and Innovative
Research UG C and issn Approved), March 2018,
http://www.jetir.org/papers/JETIREP06022.pdf
Cruz-Romero, Malco & Santovito, Elisa & Kerry, Joe
[5] & Papkovsky, Dmitri. (2019). Oxygen Sensors for Food
Packaging. 10.1016/B978-0-12-815781- 7.22944-
https://www.researchgate.net/publication/34402033
5_Ox ygen_Sensors_for_Food_Packaging
[6] “FOOD QUALITY SYSTEM BY USING ARDUINO”,
St.Martin’s Engineering college, B.Ravi Chander,
https://jespublication.com/upload/2020-110485.pdf
[7] Hu, H., Zhang, Z., & Song, Y. (2020), Image based food
caloriesestimation
https://arxiv.org/pdf/2106.11776.pdf
[8] Y. Liang and J. Li, (2017). “Deep learning-based food
calorie estimation method in dietary assessment”,
[online] Available: https://arxiv.org/abs/1706.04062.
[9] Krizhevsky, A., Sutskever, I., & Hinton, G. E. (2017).
ImageNet classification with deep convolutional neural
networks. Communications of the ACM, 60(6), pp. 84–
90. https://doi.org/10.1145/3065386
[10] Simonyan, K., & Zisserman, A. (2015). “Very Deep
Convolutional Networks for Large-Scale Image
Recognition”, CoRR, abs/1409.1556. Retrieved from
http://arxiv.org/abs/1409.1556
[11] World Health Organization (2020). “Obesity and
overweight.” Accessed: April 1, 2020. [Online].
Available: https://www.who.int/news-
room/facthttps://www.who.int/news-room/fact-
sheets/detail/obesity-
andoverweightsheets/detail/obesity-andoverweight

More Related Content

Similar to Food Quality Detection And Calorie Estimation Using Machine Learning

Similar to Food Quality Detection And Calorie Estimation Using Machine Learning (20)

IRJET- Soil, Water and Air Quality Monitoring System using IoT
IRJET- Soil, Water and Air Quality Monitoring System using IoTIRJET- Soil, Water and Air Quality Monitoring System using IoT
IRJET- Soil, Water and Air Quality Monitoring System using IoT
 
IoT Based Patient Biomedical Signal Tracking System
IoT Based Patient Biomedical Signal Tracking SystemIoT Based Patient Biomedical Signal Tracking System
IoT Based Patient Biomedical Signal Tracking System
 
IOT – Based Health Monitoring System
IOT – Based Health Monitoring SystemIOT – Based Health Monitoring System
IOT – Based Health Monitoring System
 
IRJET- Remotely Monitoring Health of the Solar Power System using Arduino
IRJET-  	  Remotely Monitoring Health of the Solar Power System using ArduinoIRJET-  	  Remotely Monitoring Health of the Solar Power System using Arduino
IRJET- Remotely Monitoring Health of the Solar Power System using Arduino
 
IRJET - Prevention of Crop Disease in Plants (Groundnut) using IoT and Ma...
IRJET -  	  Prevention of Crop Disease in Plants (Groundnut) using IoT and Ma...IRJET -  	  Prevention of Crop Disease in Plants (Groundnut) using IoT and Ma...
IRJET - Prevention of Crop Disease in Plants (Groundnut) using IoT and Ma...
 
AI Based Smart Agriculture – Leaf Disease Prediction Using Optimized CNN Model
AI Based Smart Agriculture – Leaf Disease Prediction Using Optimized CNN ModelAI Based Smart Agriculture – Leaf Disease Prediction Using Optimized CNN Model
AI Based Smart Agriculture – Leaf Disease Prediction Using Optimized CNN Model
 
IRJET - Calorie Detector
IRJET -  	  Calorie DetectorIRJET -  	  Calorie Detector
IRJET - Calorie Detector
 
Android application for detection of leaf disease (Using Image processing and...
Android application for detection of leaf disease (Using Image processing and...Android application for detection of leaf disease (Using Image processing and...
Android application for detection of leaf disease (Using Image processing and...
 
IOT Based Monitoring of Fruit Freshness Using Arduino Nano
IOT Based Monitoring of Fruit Freshness Using Arduino NanoIOT Based Monitoring of Fruit Freshness Using Arduino Nano
IOT Based Monitoring of Fruit Freshness Using Arduino Nano
 
Plant Disease Detection Using InceptionV3
Plant Disease Detection Using InceptionV3Plant Disease Detection Using InceptionV3
Plant Disease Detection Using InceptionV3
 
An effective identification of crop diseases using faster region based convol...
An effective identification of crop diseases using faster region based convol...An effective identification of crop diseases using faster region based convol...
An effective identification of crop diseases using faster region based convol...
 
IoT Based Smart Ventilator & Patient Monitoring System
IoT Based Smart Ventilator & Patient Monitoring SystemIoT Based Smart Ventilator & Patient Monitoring System
IoT Based Smart Ventilator & Patient Monitoring System
 
IRJET- Design and Implementation of Aquaculture Monitoring and Controlling Sy...
IRJET- Design and Implementation of Aquaculture Monitoring and Controlling Sy...IRJET- Design and Implementation of Aquaculture Monitoring and Controlling Sy...
IRJET- Design and Implementation of Aquaculture Monitoring and Controlling Sy...
 
WEB BASED NUTRITION AND DIET ASSISTANCE USING MACHINE LEARNING
WEB BASED NUTRITION AND DIET ASSISTANCE USING MACHINE LEARNINGWEB BASED NUTRITION AND DIET ASSISTANCE USING MACHINE LEARNING
WEB BASED NUTRITION AND DIET ASSISTANCE USING MACHINE LEARNING
 
IRJET - Remote Health Monitoring System using IoT
IRJET - Remote Health Monitoring System using IoTIRJET - Remote Health Monitoring System using IoT
IRJET - Remote Health Monitoring System using IoT
 
Eating Habit and Health Monitoring System using Android Based Machine Learning
Eating Habit and Health Monitoring System using Android Based Machine LearningEating Habit and Health Monitoring System using Android Based Machine Learning
Eating Habit and Health Monitoring System using Android Based Machine Learning
 
IRJET - Poultry Farm Controlling based on IoT
IRJET -  	  Poultry Farm Controlling based on IoTIRJET -  	  Poultry Farm Controlling based on IoT
IRJET - Poultry Farm Controlling based on IoT
 
Solar Powered Smart Agriculture Systems Using WSN Via IoT
Solar Powered Smart Agriculture Systems Using WSN Via IoTSolar Powered Smart Agriculture Systems Using WSN Via IoT
Solar Powered Smart Agriculture Systems Using WSN Via IoT
 
IRJET - Smart Yoga Instructor
IRJET - Smart Yoga InstructorIRJET - Smart Yoga Instructor
IRJET - Smart Yoga Instructor
 
Smart system for Milk quality analysis and billing system
Smart system for Milk quality analysis and billing systemSmart system for Milk quality analysis and billing system
Smart system for Milk quality analysis and billing system
 

More from IRJET Journal

More from IRJET Journal (20)

TUNNELING IN HIMALAYAS WITH NATM METHOD: A SPECIAL REFERENCES TO SUNGAL TUNNE...
TUNNELING IN HIMALAYAS WITH NATM METHOD: A SPECIAL REFERENCES TO SUNGAL TUNNE...TUNNELING IN HIMALAYAS WITH NATM METHOD: A SPECIAL REFERENCES TO SUNGAL TUNNE...
TUNNELING IN HIMALAYAS WITH NATM METHOD: A SPECIAL REFERENCES TO SUNGAL TUNNE...
 
STUDY THE EFFECT OF RESPONSE REDUCTION FACTOR ON RC FRAMED STRUCTURE
STUDY THE EFFECT OF RESPONSE REDUCTION FACTOR ON RC FRAMED STRUCTURESTUDY THE EFFECT OF RESPONSE REDUCTION FACTOR ON RC FRAMED STRUCTURE
STUDY THE EFFECT OF RESPONSE REDUCTION FACTOR ON RC FRAMED STRUCTURE
 
A COMPARATIVE ANALYSIS OF RCC ELEMENT OF SLAB WITH STARK STEEL (HYSD STEEL) A...
A COMPARATIVE ANALYSIS OF RCC ELEMENT OF SLAB WITH STARK STEEL (HYSD STEEL) A...A COMPARATIVE ANALYSIS OF RCC ELEMENT OF SLAB WITH STARK STEEL (HYSD STEEL) A...
A COMPARATIVE ANALYSIS OF RCC ELEMENT OF SLAB WITH STARK STEEL (HYSD STEEL) A...
 
Effect of Camber and Angles of Attack on Airfoil Characteristics
Effect of Camber and Angles of Attack on Airfoil CharacteristicsEffect of Camber and Angles of Attack on Airfoil Characteristics
Effect of Camber and Angles of Attack on Airfoil Characteristics
 
A Review on the Progress and Challenges of Aluminum-Based Metal Matrix Compos...
A Review on the Progress and Challenges of Aluminum-Based Metal Matrix Compos...A Review on the Progress and Challenges of Aluminum-Based Metal Matrix Compos...
A Review on the Progress and Challenges of Aluminum-Based Metal Matrix Compos...
 
Dynamic Urban Transit Optimization: A Graph Neural Network Approach for Real-...
Dynamic Urban Transit Optimization: A Graph Neural Network Approach for Real-...Dynamic Urban Transit Optimization: A Graph Neural Network Approach for Real-...
Dynamic Urban Transit Optimization: A Graph Neural Network Approach for Real-...
 
Structural Analysis and Design of Multi-Storey Symmetric and Asymmetric Shape...
Structural Analysis and Design of Multi-Storey Symmetric and Asymmetric Shape...Structural Analysis and Design of Multi-Storey Symmetric and Asymmetric Shape...
Structural Analysis and Design of Multi-Storey Symmetric and Asymmetric Shape...
 
A Review of “Seismic Response of RC Structures Having Plan and Vertical Irreg...
A Review of “Seismic Response of RC Structures Having Plan and Vertical Irreg...A Review of “Seismic Response of RC Structures Having Plan and Vertical Irreg...
A Review of “Seismic Response of RC Structures Having Plan and Vertical Irreg...
 
A REVIEW ON MACHINE LEARNING IN ADAS
A REVIEW ON MACHINE LEARNING IN ADASA REVIEW ON MACHINE LEARNING IN ADAS
A REVIEW ON MACHINE LEARNING IN ADAS
 
Long Term Trend Analysis of Precipitation and Temperature for Asosa district,...
Long Term Trend Analysis of Precipitation and Temperature for Asosa district,...Long Term Trend Analysis of Precipitation and Temperature for Asosa district,...
Long Term Trend Analysis of Precipitation and Temperature for Asosa district,...
 
P.E.B. Framed Structure Design and Analysis Using STAAD Pro
P.E.B. Framed Structure Design and Analysis Using STAAD ProP.E.B. Framed Structure Design and Analysis Using STAAD Pro
P.E.B. Framed Structure Design and Analysis Using STAAD Pro
 
A Review on Innovative Fiber Integration for Enhanced Reinforcement of Concre...
A Review on Innovative Fiber Integration for Enhanced Reinforcement of Concre...A Review on Innovative Fiber Integration for Enhanced Reinforcement of Concre...
A Review on Innovative Fiber Integration for Enhanced Reinforcement of Concre...
 
Survey Paper on Cloud-Based Secured Healthcare System
Survey Paper on Cloud-Based Secured Healthcare SystemSurvey Paper on Cloud-Based Secured Healthcare System
Survey Paper on Cloud-Based Secured Healthcare System
 
Review on studies and research on widening of existing concrete bridges
Review on studies and research on widening of existing concrete bridgesReview on studies and research on widening of existing concrete bridges
Review on studies and research on widening of existing concrete bridges
 
React based fullstack edtech web application
React based fullstack edtech web applicationReact based fullstack edtech web application
React based fullstack edtech web application
 
A Comprehensive Review of Integrating IoT and Blockchain Technologies in the ...
A Comprehensive Review of Integrating IoT and Blockchain Technologies in the ...A Comprehensive Review of Integrating IoT and Blockchain Technologies in the ...
A Comprehensive Review of Integrating IoT and Blockchain Technologies in the ...
 
A REVIEW ON THE PERFORMANCE OF COCONUT FIBRE REINFORCED CONCRETE.
A REVIEW ON THE PERFORMANCE OF COCONUT FIBRE REINFORCED CONCRETE.A REVIEW ON THE PERFORMANCE OF COCONUT FIBRE REINFORCED CONCRETE.
A REVIEW ON THE PERFORMANCE OF COCONUT FIBRE REINFORCED CONCRETE.
 
Optimizing Business Management Process Workflows: The Dynamic Influence of Mi...
Optimizing Business Management Process Workflows: The Dynamic Influence of Mi...Optimizing Business Management Process Workflows: The Dynamic Influence of Mi...
Optimizing Business Management Process Workflows: The Dynamic Influence of Mi...
 
Multistoried and Multi Bay Steel Building Frame by using Seismic Design
Multistoried and Multi Bay Steel Building Frame by using Seismic DesignMultistoried and Multi Bay Steel Building Frame by using Seismic Design
Multistoried and Multi Bay Steel Building Frame by using Seismic Design
 
Cost Optimization of Construction Using Plastic Waste as a Sustainable Constr...
Cost Optimization of Construction Using Plastic Waste as a Sustainable Constr...Cost Optimization of Construction Using Plastic Waste as a Sustainable Constr...
Cost Optimization of Construction Using Plastic Waste as a Sustainable Constr...
 

Recently uploaded

electrical installation and maintenance.
electrical installation and maintenance.electrical installation and maintenance.
electrical installation and maintenance.
benjamincojr
 
21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx
rahulmanepalli02
 
Artificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdfArtificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdf
Kira Dess
 

Recently uploaded (20)

Seismic Hazard Assessment Software in Python by Prof. Dr. Costas Sachpazis
Seismic Hazard Assessment Software in Python by Prof. Dr. Costas SachpazisSeismic Hazard Assessment Software in Python by Prof. Dr. Costas Sachpazis
Seismic Hazard Assessment Software in Python by Prof. Dr. Costas Sachpazis
 
electrical installation and maintenance.
electrical installation and maintenance.electrical installation and maintenance.
electrical installation and maintenance.
 
21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx
 
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
NO1 Best Powerful Vashikaran Specialist Baba Vashikaran Specialist For Love V...
 
handbook on reinforce concrete and detailing
handbook on reinforce concrete and detailinghandbook on reinforce concrete and detailing
handbook on reinforce concrete and detailing
 
21scheme vtu syllabus of visveraya technological university
21scheme vtu syllabus of visveraya technological university21scheme vtu syllabus of visveraya technological university
21scheme vtu syllabus of visveraya technological university
 
Involute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdf
Involute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdfInvolute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdf
Involute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdf
 
Independent Solar-Powered Electric Vehicle Charging Station
Independent Solar-Powered Electric Vehicle Charging StationIndependent Solar-Powered Electric Vehicle Charging Station
Independent Solar-Powered Electric Vehicle Charging Station
 
Circuit Breakers for Engineering Students
Circuit Breakers for Engineering StudentsCircuit Breakers for Engineering Students
Circuit Breakers for Engineering Students
 
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdfInstruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
 
CLOUD COMPUTING SERVICES - Cloud Reference Modal
CLOUD COMPUTING SERVICES - Cloud Reference ModalCLOUD COMPUTING SERVICES - Cloud Reference Modal
CLOUD COMPUTING SERVICES - Cloud Reference Modal
 
NEWLETTER FRANCE HELICES/ SDS SURFACE DRIVES - MAY 2024
NEWLETTER FRANCE HELICES/ SDS SURFACE DRIVES - MAY 2024NEWLETTER FRANCE HELICES/ SDS SURFACE DRIVES - MAY 2024
NEWLETTER FRANCE HELICES/ SDS SURFACE DRIVES - MAY 2024
 
analog-vs-digital-communication (concept of analog and digital).pptx
analog-vs-digital-communication (concept of analog and digital).pptxanalog-vs-digital-communication (concept of analog and digital).pptx
analog-vs-digital-communication (concept of analog and digital).pptx
 
The Entity-Relationship Model(ER Diagram).pptx
The Entity-Relationship Model(ER Diagram).pptxThe Entity-Relationship Model(ER Diagram).pptx
The Entity-Relationship Model(ER Diagram).pptx
 
Filters for Electromagnetic Compatibility Applications
Filters for Electromagnetic Compatibility ApplicationsFilters for Electromagnetic Compatibility Applications
Filters for Electromagnetic Compatibility Applications
 
Research Methodolgy & Intellectual Property Rights Series 1
Research Methodolgy & Intellectual Property Rights Series 1Research Methodolgy & Intellectual Property Rights Series 1
Research Methodolgy & Intellectual Property Rights Series 1
 
Artificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdfArtificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdf
 
Adsorption (mass transfer operations 2) ppt
Adsorption (mass transfer operations 2) pptAdsorption (mass transfer operations 2) ppt
Adsorption (mass transfer operations 2) ppt
 
Maximizing Incident Investigation Efficacy in Oil & Gas: Techniques and Tools
Maximizing Incident Investigation Efficacy in Oil & Gas: Techniques and ToolsMaximizing Incident Investigation Efficacy in Oil & Gas: Techniques and Tools
Maximizing Incident Investigation Efficacy in Oil & Gas: Techniques and Tools
 
SLIDESHARE PPT-DECISION MAKING METHODS.pptx
SLIDESHARE PPT-DECISION MAKING METHODS.pptxSLIDESHARE PPT-DECISION MAKING METHODS.pptx
SLIDESHARE PPT-DECISION MAKING METHODS.pptx
 

Food Quality Detection And Calorie Estimation Using Machine Learning

  • 1. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1247 Food Quality Detection And Calorie Estimation Using Machine Learning Prakash R1, Vadlapatla Sathvik2, Potru Teja Sri Venkata Satya Sai3 , Pothireddy Gopichand Reddy4 1Assitant Professor Sr.Grade1, SENSE, Vellore Institute Of Technology, Katpadi, Tamil Nadu-632014 2,3,4 Student, SENSE, Vellore Institute Of Technology, Katpadi, Tamil Nadu-632014 ---------------------------------------------------------------------***--------------------------------------------------------------------- Abstract - Many states in India lack proper food supply to the poor. Many NGOs and non-profitable organizations work towards feeding the homeless and needy. But they lack funding and hence proper food storage facilities and maintenance is scarce. This project mainly focuses on helping these organizations to keep the food in check and serve unspoiled food. It also keeps track of the calories so a well-balanced diet food is given. Key Words: food safety, calorie estimation, machine learning, oxygen sensor, MQ3 sensor, IOT. 1. INTRODUCTION In this modern era of science of technology, the food sector is facing one of the major problems that is food spoilage. food items such as fruits, vegetables and meat are going stale .The bigger problem is these spoiled items going undetected and onto the hands of the consumer . Hence, there is a need for an automated process that would not only increase the accuracy of spoiled food detection, but also estimating calories present in it. This project mainly focuses on helping NGO’s and organizations to keep their food in check and serve unspoiled food. It also aims at keeping track of the calories so a wellbalanced diet food is given. We are also designing a mobile app which can be used to fetch data about calories of different vegetables and fruits for the users by uploading the image of any vegetables or fruits so as to keep track of their calories and maintain a healthy balanced diet. In details, to automate this process, we are planning on using a collection of smart sensors like temperature sensor, MQ3 sensor with microcontroller like the Node MCU. On detection of a spoiled or stale food item, a sound buzzer will ring and a LED light will glow to draw attention, we developed an app, as an application of IoT. This enables consumers to view the name of fruit or vegetable and also with the help of developing app we can estimate the amount of calories present in it. In addition, the app classifies the image, predicts the name of the fruit or the vegetable and gives the calories associated with it. The frontend-backend is handled by the Streamlit. The user can visit the application by URL. The user can use the upload button upload button to upload the image. 2. LITERAUTRE SURVEY There have been previous papers on different fields on food spoilage and calorie estimation.[1] An Arduino sensor-based approach for detecting the food spoilage A project on monitoring temperature in a small server room have been implemented previously. The data is sent online and if the values exceed a limit, the system turns the conditioning systems on and makes the temperature in the threshold values This paper is an IOT based consisting of a microcontroller Arduino Uno, Bluetooth module, electrical and biosensor like pH sensor, dampness sensor, and gas sensors. DHT- 11 is used to measure temperature and moistness, MQ2 to distinguish liquor content is linked with Arduino board. This is an IoT based system, sends necessary information to user through ESP8266 Wi-Fi. Here they focus on keeping the food storage surrounding to the optimal conditions [2] Iot based smart weighing system for crate in agriculture. [3] A new deep learning based food recognition system for dietary assessment on an edge computing service infrastructure. Chang Liu, Yu Cao , Senior Member, IEEE, Yan Luo, Member, IEEE, Guanling Chen, Member, IEEE, Vinod Vokkarane, Senior Member, IEEE, Ma Yunsheng, Song qing Chen, Member, IEEE, This paper focuses on nutritional estimation of food using the visual based food recognition algorithms using edge computing. The project uses a visual sensor for capturing the food image, the mobile phone for the image preprocessing and segmentation and the server (cloud layer) with the pre trained CNN model and image classification. The multiple-stage food recognition system includes Image preprocessing in the front-end component and the Image segmentation in the front-end component (CNN based food image analysis) Every living being on earth is essentially dependent on nutrition to stay alive. Each individual cell needs energy to continue its vital activities such as growth, development and renewal of damages. Environmental conditions, for instance humidity and temperature allow organisms to spread inside food, these bacterial activities cause unwanted food spoilage which may be harmful for human health. [1].In India Data analysis showed that states of West Bengal (31.22),
  • 2. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1248 Karnataka (29.11) and Gujarat (22.67) reported maximum average outbreaks and contributed to 31.5% illnesses and 8.7% deaths. Detecting food spoilage from production to consumption stages is very crucial. There is indeed an urgent need for fast and accurate systems, while conventional spoilage detection techniques are slow and time consuming [2]. As a result, new vision based techniques and algorithmic approaches have been proposed in the last decades. The most recently developed methods for detecting. Food spoilage are based on digital image processing, by using nano technology and state-of- the-art machine learning, which have already proven their high potential in the food industry. Here for food spoilage detection we are using nanotechnology,[3]. Nanotechnology based sensing approaches are capable of providing selective and specific information on the presence and amount of pathogens and toxins.in this project we are using MQ3 sensor [4].This MQ3 sensor that is used to detect the presence of toxic gas acetone and ethanol in the spoiled food. And also we are using oxygen sensor which tells us that [5] if food item is inhabited by germs ,the oxygen levels in the immediate surrounding is going to be lower than it normally is .The introduction of these sensors into food detection technology has paved the way for smart food detection. These sensors will be integrated with [6]Arduino uno board which is a popular prototyping board measures and sends data to iot platform. 3. PROPOSED MODEL DESCRIPTION In our proposed work, we aim at detecting spoilage in food items as a part of hardware and estimating calories in food as a part of software. With the help of sensor nodes placed near food items methane range and temperature data can be collected at regular intervals. In this project we have used industrial MQ3 and temperature sensors. NodeMCU is with Arduino Uno boards. In the block diagram, MQ3 and oxygen/temperature sensor is connected to the Arduino boards and hence gets connected to the Node MCU. Finally the data is shown on the blynk app and at the same time the buzzers are turned on to indicate spoilage of food if the values exceed the threshold. For the software part, it is a simple web application in which the user needs to upload the Image of any fruit or vegetable. The system next automatically classifies the Image and gives the prediction about the name of the fruit or vegetable, and also gives the calories of the object. The frontend-backend will be handled by the Streamlit. The user can visit the application by URL. There will be upload button for the user to upload the image. Fig -1: Process Flowchart 4. TECHINCAL SPECIFICATIONS Our proposed work consists of 2 parts – hardware and software The hardware consists of a MQ3 sensor along with temperature for methane extent and temperature measurement respectively, Arduino UNO and nodeMCU for acquiring data from sensors and sending to the Arduino IDE. A buzzer and two LED, s are connected to the Arduino UNO for indicating the spoilage of the food and blynk app for displaying the methane and temperature data. The frontend and backend of the web app is handled by the StreamLit. It is a simple web application in which the user needs to upload the Image of any fruit or vegetable. The system next automatically classifies the Image and gives the prediction about the name of the fruit or vegetable, and also about their respective calories. The user will first upload the Image. That image Will be stored into the local system. Then pillow will resize the image according to our model shape, it will convert into vector. Now this vector will be passed to our model, our model will classify the class of category. We will get the ID of category, now we need to map the labels according to the ID. Now our system will do web-scrap the calories for predicted object. Our application will display the Result and Calories into our application. Fig -2: Flowchart
  • 3. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1249 5.HARDWARE 5.1. Arduino UNO Arduino is an open source platform used for building electronic projects.it is a company.it is basically a microcontroller. generally a microcontroller is difficult to use and programming needs some experience. whereas it comes as module with necessary pins and sockets connected with microcontroller along with IDE in easy programming language making it easier for small project applications. 5.2. MQ3 sensor MQ standards for having sensitivity towards gas. It is made up of metal oxide semiconductors. MQ sensor are called chemo resistor because sensor values change according to change in resistance of gas. Specifications of MQ3 sensor are it operates 5V dc and draw 800 Mw, sensor resistance from 1M to 8MΩ, load resistance is 200kΩ. This module has 4 pins Analog Output (A0), Digital Output (D0), VCC, GND pins. The A0 pin output will be varied according to concentration of gas, when concentration of gas is high, output of A0 pin is high and vice versa for low concentration of gas. 5.3. ESP8266 Node MCU NodeMCU is a low-cost open source IoT platform. It initially included firmware which runs on the ESP8266 Wi-Fi SoC from Espressif Systems, and hardware which was based on the ESP-12 module. Later, support for the ESP32 32bit MCU was added. 5.4. Piezoelectric Buzzer A piezoelectric speaker is a loudspeaker that uses the piezoelectric effect for generating sound. The initial mechanical motion is created by applying a voltage to a piezoelectric material. 5.5. Temperature sensor A temperature sensor is a device used to measure temperature. This can be air temperature, liquid temperature or The temperature of solid matter. The basic principle of working of the temp. sensors is the voltage across the diode terminals. If the voltage increases, the temperature also rises, followed by a voltage drop between the transistor terminals of base and emitter in a diode. Here we have used a thermistor in this project model. Fig -3: Hardware Circuit 6.SOFTWARE 6.1.PyCharm PyCharm is an integrated development environment used in computer programming, specifically for the Python programming language. It provides code analysis, a graphical debugger, an integrated unit tester, integration with version, and supports web development with Django as well as data science. 6.2.Kaggle Kaggle is world’s largest data set community with powerful tools and resources to help to achieve one’s data science goals. It allows users to find and publish data sets, explore and build models in a web-based data-science environment, work with other data scientists and machine learning engineers, and enter. 6.3.Web App The web app contains a signup, login and main webpage. which the user needs to upload the Image of any fruit or vegetable. The system next automatically classifies the the Image and gives the prediction about the name of the competitions to solve data science challenges. Fruit or vegetable and also about their respective calories. Fig -4: Calorie estimation Web App
  • 4. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1250 7. RESULTS 7.1.Hardware All the connections are successfully made and Arduino and nodeMCU is turned on. The sensors are brought close to a sample of food. The sensors connected to the Arduino polls data from both the sensors. This data is sent to the nodeMCU which the sends the data to the blynk app via IDE code. On detection of a spoiled or stale food item a buzzer sound will ring and a LED light will glow, notified through blynk app via the Arduino. Fig -5: Arduino IDE code Fig -6: Methane And Temperature data values Fig -7: Food Spoil Alert Fig -8: Blynk App output reading 7.2.Software The user will first upload the Image. That image Will be stored into the local system. Then pillow will resize the image according to our model shape, it will convert into vector. Now this vector will be passed to our model, our model will classify the class of category. We will get the ID of category, now we need to map the labels according to the ID. Now our system will do web-scrap the calories for predicted object. Our application will display the Result and Calories into our website. Fig -9: Prediction and calories estimation of banana The user will first upload the Image. That image Will be stored into the local system. Then pillow will resize the
  • 5. International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056 Volume: 09 Issue: 08 | Aug 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page 1251 image according to our model shape, it will convert into vector. Now this vector will be passed to our model, our model will classify the class of category. We will get the ID of category, now we need to map the labels according to the ID. Now our system will do web-scrap the calories for predicted object. Our application will display the Result and Calories into our application. Fig -10: Prediction and calories estimation of carrot 8. CONCLUSION AND FUTURE SCOPE We were able to detect spoilt food with the help of the proposed hardware model and also able to predict and calculate calories of different fruits and vegetables with the help of the software model. We can further detect spoilage of food for wider range of food items by increasing the number and types of sensors used in the project. For the software model we can further make it accurate for detection spoilage of food when uploaded a real time picture of a spoilt or stale food. 9. REFERENCES [1] A surveillance of food borne disease outbreaks in India https://www.sciencedirect.com/science/article/abs/p i i/S0956713520305466?via%3 Dihub [2] B. Fletcher and et al., “Advances in meat spoilage detection: A short focus on rapid methods and technologies,” J. Food, vol. 16(1), pp. 1037– 1044, 2018. https://doi.org/10.1080/19476337.2018.1525432 [3] Mustafa F., Hassan R.Y., Andreescu S. Multifunctional nanotechnology- enabled sensors for rapid capture and detection of pathogens. Sensors. 2017;17:2121. https://doi.org/10.3390/s17092121 [4] “Automatic Food Spoilage Detection”, International Journal of Emerging Technologies and Innovative Research UG C and issn Approved), March 2018, http://www.jetir.org/papers/JETIREP06022.pdf Cruz-Romero, Malco & Santovito, Elisa & Kerry, Joe [5] & Papkovsky, Dmitri. (2019). Oxygen Sensors for Food Packaging. 10.1016/B978-0-12-815781- 7.22944- https://www.researchgate.net/publication/34402033 5_Ox ygen_Sensors_for_Food_Packaging [6] “FOOD QUALITY SYSTEM BY USING ARDUINO”, St.Martin’s Engineering college, B.Ravi Chander, https://jespublication.com/upload/2020-110485.pdf [7] Hu, H., Zhang, Z., & Song, Y. (2020), Image based food caloriesestimation https://arxiv.org/pdf/2106.11776.pdf [8] Y. Liang and J. Li, (2017). “Deep learning-based food calorie estimation method in dietary assessment”, [online] Available: https://arxiv.org/abs/1706.04062. [9] Krizhevsky, A., Sutskever, I., & Hinton, G. E. (2017). ImageNet classification with deep convolutional neural networks. Communications of the ACM, 60(6), pp. 84– 90. https://doi.org/10.1145/3065386 [10] Simonyan, K., & Zisserman, A. (2015). “Very Deep Convolutional Networks for Large-Scale Image Recognition”, CoRR, abs/1409.1556. Retrieved from http://arxiv.org/abs/1409.1556 [11] World Health Organization (2020). “Obesity and overweight.” Accessed: April 1, 2020. [Online]. Available: https://www.who.int/news- room/facthttps://www.who.int/news-room/fact- sheets/detail/obesity- andoverweightsheets/detail/obesity-andoverweight