0% found this document useful (0 votes)
4 views63 pages

Track Your Calories Using of ML Algorithm

The 'Track Your Calories' application is a machine learning-based tool designed to help users monitor and manage their daily calorie intake by logging food items and tracking meals. It offers personalized experiences through user accounts, a comprehensive food database, and various modules for goal setting, progress tracking, and community engagement. The app aims to promote healthier lifestyles by providing users with insights into their nutritional habits and facilitating informed dietary choices.

Uploaded by

maina.metam
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views63 pages

Track Your Calories Using of ML Algorithm

The 'Track Your Calories' application is a machine learning-based tool designed to help users monitor and manage their daily calorie intake by logging food items and tracking meals. It offers personalized experiences through user accounts, a comprehensive food database, and various modules for goal setting, progress tracking, and community engagement. The app aims to promote healthier lifestyles by providing users with insights into their nutritional habits and facilitating informed dietary choices.

Uploaded by

maina.metam
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 63

ABSTRACT

The "Track Your Calories” is a used by machine learning designed to help


users monitor and manage their daily calorie intake. The application allows
users to log their consumed food items, track meals, and view summaries of
their nutritional habits over time.

Users can create accounts and log in securely.

Personalized experiences are provided through user-specific data storage.


Users can add, edit, and delete food items.

Each food item includes information such as name and calorie content.
Users can log meals by selecting food items from the database.
Meals are associated with specific dates and times.

Users can view historical data, allowing them to track their calorie intake
trends over time.

The "Track Your Calories" app aims to provide users with a comprehensive
tool to manage and optimize their nutritional choices, fostering healthier life-
styles.

i
Contents
ABSTRACT..........................................................................................................................................................i
1. INTRODUCTION.......................................................................................................................................1
1.1 SYSTEM SPECIFICATIONS...................................................................................................................2
1.2 SOFTWARE REQUIREMENTS:.............................................................................................................2
1.3 HARDWARE REQUIREMENTS:...........................................................................................................2
1.4 EXISTING SYSTEM:...............................................................................................................................3
1.5 PROPOSED SYSTEM:.............................................................................................................................3
1.6 FEASIBILITY STUDY:............................................................................................................................3
1.7 MODULES:...............................................................................................................................................6
2. SYSTEM DESIGN...................................................................................................................................10
2.1 INPUT DESIGN:.....................................................................................................................................10
2.2 OUTPUT DESIGN:.................................................................................................................................13
3. SYSTEM ARCHITECTURE:..................................................................................................................17
3.1 UML DIAGRAMS:.................................................................................................................................19
3.2 USE CASE DIAGRAM:..........................................................................................................................21
3.3 ACTIVITY DIAGRAM:.........................................................................................................................23
3.4 SEQUENCE DIAGRAM:.......................................................................................................................25
3.5 COLLABORATION DIAGRAM:..........................................................................................................27
3.6 CLASS DIAGRAM:................................................................................................................................29
4. TESTING AND DEBUGGING................................................................................................................29
4.1 INTRODUCTION:..................................................................................................................................29
4.2 TYPES OF TESTS:..........................................................................................................................31
4.2.1 UNIT TESTING:..............................................................................................................................31
4.2.2 INTEGRATION TESTING:....................................................................................................32
4.2.3 FUNCTIONAL TEST:............................................................................................................33
4.2.4 SYSTEM TEST:......................................................................................................................34
4.2.5 WHITE BOX TESTING:.........................................................................................................34
4.2.6 BLACK BOX TESTING:........................................................................................................35
4.3 TEST CASES...................................................................................................................................36
5. CODE & OUTPUT SCREENS.................................................................................................................38
6. FUTURESCOPE........................................................................................................................................47
7. REFERENCES...........................................................................................................................................48
8. APPENDIX-A............................................................................................................................................49

ii
TRACK YOUR CALORIES

1. INTRODUCTION

In an era where health and wellness are paramount, the "Track Your Calories" app
emerges as a powerful tool to empower individuals on their journey towards a health-
ier lifestyle. This Django-based web application is meticulously designed to assist
users in monitoring and managing their daily calorie intake. By seamlessly integrating
modern web technologies with nutrition science, the app aims to revolutionize how
individuals engage with their dietary habits.

The primary goal of the "Track Your Calories" app is to provide users with a user-
friendly and efficient platform for monitoring their nutritional intake. It addresses the
need for a comprehensive tool that enables individuals to make informed decisions
about their diet, fostering a culture of health-consciousness.

The "Track Your Calories" app is designed for individuals of all ages and back-
grounds who seek a practical and effective way to manage their dietary habits. It
caters to health enthusiasts, fitness enthusiasts, and anyone committed to making in-
formed choices about their nutrition.

Major health problems that are faced by most of the people nowadays are due to
obesity. One of the reasons for obesity is unbalanced food. Therefore, we have to
consume good food for healthy life. Good nutrition is important to maintain our
health. Many people prefer dieting to overcome from obesity. Success of dieting and
weight loss is based on the food what we intake in a day. So counting calorie is one of
the important roles in part of healthy lifestyle. Calorie is a unit of measurement
for the energy value of food. Calorie counter calculates the required calorie and
consumed calorie. Then provides the dietary plans and workout suggestion for
the user. Hence it helps them to stay fit and healthy.

11
1
1.1 SYSTEM SPECIFICATIONS

The project involved analysing the design of few applications to make the appli-
cation more users friendly. To make the application more accessible, the
browser version had to be chosen so that it is compatible with most of the
Browsers.
1.2 SOFTWARE REQUIREMENTS:

For developing the applications, the following are the Software Requirements:

• Anaconda
• Jupiter
• Kaggle

1.3 HARDWARE REQUIREMENTS:

• Hard Disk
• System (8GB RAM and 1TB Hard Disk)
• Forms (To collect data from the customer in malls

2
1.4 EXISTING SYSTEM:

The existing system contains the following drawbacks:

• All the segmentations are search based

• Difficult to gather the data and segment them accordingly

• The results are not really accurate as the clustering is not close enough to de-
termine accurate centroids

1.5 PROPOSED SYSTEM:

Our proposed system has the following features:


• Develop the system to get easy visualization techniques
• Increase the data set to accommodate many data points so that results will
be more accurate
• Segment the products directly according to the customer group
• Use different methods to collect the customer data instead of physical forms

1.6 FEASIBILITY STUDY:

A feasibility study for the "Track Your Calories" application using Django involves
assessing the technical, economic, and operational aspects to determine whether the
project is viable and worth pursuing.
Key considerations involved in the feasibility analysis are:

 ECONOMICAL FEASIBILITY
11
3
 TECHNICAL FEASIBILITY
 OPERATIONAL FEASIBILITY

ECONOMICAL FEASIBILITY:

This study is carried out to check the economic impact that the system will have
on the organization. The amount of fund that the company can pour into the re-
search and development of the system is limited. The expenditures must be jus-
tified. Thus, the developed system as well within the budget and this was
achieved because most of the technologies used are freely available. Only the
customized products had to be purchased.
TECHNICAL FEASIBILITY:

This study is carried out to check the technical feasibility, that is, the technical
requirements of the system. Any system developed must not have a high de-
mand on the available technical resources. This will lead to high demands on
the available technical resources. This will lead to high demands being placed
on the client. The developed system must have a modest requirement, as only
minimal or null changes are required for implementing this system.

4
OPERATIONAL FEASIBILITY

Operational feasibility refers to the assessment of whether a proposed project,


such as the development of the "Track Your Calories" application using Django,
is viable and practical from an operational standpoint. In other words, it evalu-
ates whether the project can be successfully integrated into the existing organi-
zational processes, systems, and workflows. Here's an introduction to opera-
tional feasibility.

Operational feasibility is a critical aspect of evaluating the viability of any


project, as it directly impacts its successful implementation and adoption. For
the "Track Your Calories" application, operational feasibility involves assessing
various operational aspects to ensure that the application can effectively meet its
objectives and fulfill user needs within the organizational context.

11
5
1.7 MODULES:
There are four modules can be divided here for this project they are listed as be-
low:

• User Authentication and Management Module

• Food Database Module

• Food Logging Module

• Calorie Calculation Module

• Goal Setting Module

• Progress Tracking Module

• Meal Planning and Recipes Module

• Social Sharing and Community Module

• Admin Panel Module

• API Module (Optional):

User Authentication and Management Module


• Handles user registration, login, and authentication.
• Manages user profiles and settings.

Food Database Module:


The Food Database Module is a crucial component of the "Track Your Calo-
ries" application developed using Django. This module serves as the repository
for comprehensive information about various food items, including their names,
descriptions, serving sizes, and nutritional content. By maintaining a rich and
up-to-date database of food items, users can accurately track their calorie intake
and make informed decisions about their dietary habits.

6
Key Features of the Food Database Module:
Comprehensive Food Catalog:
• The module provides a comprehensive catalog of food items, covering a
wide range of categories such as fruits, vegetables, grains, meats, dairy
products, and packaged foods.
• Each food item entry includes detailed information such as the name of
the food, description, serving size, and nutritional content per serving.
Nutritional Information:
• Users can access detailed nutritional information for each food item, in-
cluding macronutrient composition (carbohydrates, proteins, fats) and mi-
cronutrient content (vitamins, minerals).
• Nutritional values are provided in standard units (e.g., grams, milligrams)
per specified serving size to facilitate accurate calorie tracking.
Search and Filtering Capabilities:
• The module offers robust search and filtering capabilities, allowing users
to easily find specific food items based on keywords, categories, or nutri-
tional criteria.
• Users can filter food items by categories (e.g., fruits, vegetables, proteins)
or dietary preferences (e.g., vegetarian, gluten-free, low-carb) to meet
their individual needs.
User-Friendly Interface:
• The module features a user-friendly interface that enables seamless navi-
gation and interaction with the food database.
• Users can browse food items, view nutritional information, and perform
search and filtering operations effortlessly through the intuitive interface.
Customization and Personalization:
• Users have the flexibility to customize and personalize their food choices
based on dietary preferences, nutritional goals, and lifestyle requirements.
• The module supports user-specific preferences and settings, allowing
users to tailor their food selections to meet their unique needs.
Integration with Tracking Functionality:
11
7
• The food database seamlessly integrates with calorie tracking and meal
logging functionalities within the "Track Your Calories" application.
• Users can easily select and log food items from the database to track their
calorie intake and monitor their nutritional consumption in real-time.
Data Accuracy and Reliability:
• The module ensures the accuracy and reliability of food item data through
regular updates and validation checks.
• Nutritional information is sourced from reputable sources such as nutri-
tion databases, government agencies, and food manufacturers to provide
users with reliable data.
Overall, the Food Database Module plays a pivotal role in empowering users to
make informed dietary choices and achieve their health and wellness goals by
providing access to a comprehensive and accurate repository of food item infor-
mation within the "Track Your Calories" application.

Calorie Calculation Module:


This module is responsible for accurately calculating the total calorie intake for
users based on the food items they log into the system. By leveraging nutritional
information stored in the food database and user input, the module provides
users with insights into their calorie consumption, enabling them to monitor
their dietary habits and make informed decisions about their nutrition.

Food Logging Module:


This module enables users to record and track their daily food consumption, al-
lowing them to monitor their calorie intake and make informed dietary choices.
By providing a convenient platform for logging food items and meals, the mod-
ule empowers users to maintain awareness of their eating habits and achieve
their health and fitness goals.

Goal Setting Module:


This module empowers users to set personalized calorie goals based on various
factors such as age, gender, weight, activity level, and dietary preferences. By
providing users with the ability to establish realistic and achievable goals, the
8
module facilitates effective calorie management and supports users in their jour-
ney towards health and wellness.

Progress Tracking Module:


The Progress Tracking Module is a vital component. This module allows users
to monitor their progress towards health and wellness goals by tracking various
metrics related to their calorie intake, weight management, and overall fitness
journey. By providing users with insights into their progress over time, the mod-
ule facilitates accountability, motivation, and informed decision-making.

Meal Planning and Recipes Module:


This module empowers users to plan nutritious meals, discover new recipes, and
maintain a balanced diet that aligns with their health and wellness goals. By
providing access to a diverse range of recipes and meal planning tools, the mod-
ule aims to simplify the process of meal preparation and support users in mak-
ing informed dietary choices.
Social Sharing and Community Module:
This module aims to foster a supportive and engaging community environment
where users can connect, share experiences, and motivate each other on their
health and wellness journeys. By facilitating social interaction and knowledge
sharing, the module enhances user engagement and promotes a sense of belong-
ing within the application.

Admin Panel Module:


This module provides administrators and authorized personnel with a powerful
interface for managing and controlling various aspects of the application's func-
tionality, content, and user data. With intuitive administrative tools and features,
the module streamlines administrative tasks, enhances operational efficiency,
and ensures smooth day-to-day management of the application.

API Module (Optional):

The API (Application Programming Interface) Module serves as a bridge between the
"Track Your Calories" application and external systems, allowing developers to ac-
cess and interact with the application's functionality and data programmatically.
While the API module is optional, implementing it can extend the reach and versatil -
11
9
ity of the application by enabling integration with third-party services, mobile apps.

10
2. SYSTEM DESIGN

2.1 INPUT DESIGN:

Input design for the "Track Your Calories" application involves creating intuitive
and user-friendly interfaces for users to input various types of data related to
their dietary intake, fitness activities, and health goals.
Here are some key elements of input design tailored for the application:

Food Logging Interface:

• Provide a form or interface for users to log their daily food consumption.
• Include fields for entering details such as food name, serving size, meal cate-
gory (e.g., breakfast, lunch, dinner, snacks), and time of consumption.
• Offer autocomplete suggestions or a searchable database of food items to
streamline the input process.
• Allow users to specify portion sizes and serving measurements (e.g., grams,
ounces, cups) for accurate calorie tracking.

Physical Activity Logging:


• Create a dedicated section for users to log their physical activities and work-
outs.
• Include fields for recording activity type, duration, intensity level, and any ad-
ditional notes or descriptions.
• Provide options for selecting from a predefined list of activities or allowing
users to input custom activities.
• Integrate with fitness tracking devices or apps to import activity data automati-
cally.

Weight Tracking Interface:


• Design a user-friendly interface for users to track changes in their body weight
and composition.
• Include fields for entering weight measurements, along with date and time
stamps.
• Offer visualization tools such as charts or graphs to display weight trends over
time.
• Provide options for users to set weight loss/gain goals and track progress to-
11
11
wards those goals.
Goal Setting Form:
• Develop a form for users to set personalized calorie goals and health objectives.
• Include fields for entering demographic information (e.g., age, gender), weight,
height, activity level, and weight management goals.
• Provide guidance and recommendations for setting realistic and achievable
goals based on user inputs.
• Allow users to customize calorie targets based on their dietary preferences and
lifestyle factors.
Recipe Submission Form:
• Allow users to submit their own recipes or culinary creations to the applica-
tion's recipe database.
• Include fields for entering recipe name, ingredients, preparation instructions,
cooking time, and serving size.
• Provide options for categorizing recipes by meal type, cuisine, dietary prefer-
ences, and special occasions.
• Enable users to upload photos or images to accompany their recipe submis-
sions.
Community Interaction Forms:

• Design forms or interfaces for users to interact with the application's commu-
nity features, such as posting updates, sharing recipes, or joining discussions.
• Include fields for entering text-based updates, comments, or replies.
• Offer options for attaching images, videos, or links to shared content.
• Implement features for liking, commenting, and sharing community posts to en-
courage engagement.
User Profile Management:
• Create a profile management interface for users to update their account infor-
mation and preferences.
• Include fields for editing profile details such as username, email address, pro-
file picture, bio, and privacy settings.
• Provide options for users to customize notification preferences, language set-
tings, and other account settings.
Accessibility and Usability Considerations:
• Ensure that input forms and interfaces are accessible to users with disabilities,
including support for screen readers, keyboard navigation, and alternative input
methods.
• Use clear and concise labels, instructions, and error messages to guide users
12
through the input process.
• Design interfaces with responsive layouts and adaptable designs to accommo-
date users accessing the application from different devices and screen sizes.
OBJECTIVES:

1. User-Friendly Interface: The primary objective of the input design is to create


a user-friendly interface that allows users to input their dietary information eas-
ily and intuitively. This includes designing forms, fields, and input methods
that are simple to understand and navigate.

2. Efficient Data Entry: The input design aims to facilitate efficient data entry by
minimizing the number of steps required to input information. This includes us-
ing dropdown menus, auto-complete suggestions, and pre-filled fields wherever
possible to streamline the input process.

3. Accurate Input Validation: Ensuring the accuracy and validity of user input is
a key objective of the input design. This involves implementing input valida-
tion mechanisms to prevent users from entering incorrect or invalid data, such
as enforcing constraints on numerical fields (e.g., restricting calorie intake to
positive integers).

4. Customization and Personalization: The input design should allow users to


customize and personalize their input experience based on their individual pref-
erences and requirements. This includes providing options for users to set their
dietary goals, preferences, and restrictions, and tailoring input fields accord-
ingly.

5. Real-Time Feedback: Providing real-time feedback to users as they input data


is an important objective of the input design. This includes displaying error
messages or validation warnings immediately when invalid data is entered, as
well as dynamically updating input fields based on user selections.

6. Support for Various Input Methods: The input design should accommodate
various input methods to cater to different user preferences and accessibility
needs. This includes support for keyboard input, mouse interaction, touch-
screens, voice input, and assistive technologies for users with disabilities.

7. Integration with Data Sources: The input design should seamlessly integrate
11
13
with data sources such as the Food Database Module and external APIs to
provide users with access to comprehensive and up-to-date information when
inputting dietary data. This ensures that users can easily find and select the
foods they consume from a vast database of options.

8. Consistency and Standardization: Maintaining consistency and standardiza-


tion across input forms and fields is an essential objective of the input design.
This includes using uniform styling, layout, and labeling conventions to ensure
a cohesive and familiar input experience throughout the application.

9. Scalability and Flexibility: The input design should be scalable and flexible to
accommodate future growth and changes in user requirements. This involves
designing input forms and fields in a modular and extensible manner, allowing
for easy addition of new features and functionalities as needed.

10.Security and Privacy: Protecting user data and ensuring privacy are para-
mount objectives of the input design. This includes implementing measures to
secure sensitive information entered by users, such as encryption of data trans-
mission and storage, as well as adherence to data privacy regulations and best
practices.

2.2 OUTPUT DESIGN:

User Dashboard:

• Provides users with a personalized dashboard displaying key metrics such as


daily calorie intake, progress towards goals, and recent activity.
• Offers visualizations such as charts or graphs to illustrate calorie consumption
trends and nutritional breakdown.

Meal Logging Interface:


• Offers a user-friendly interface for logging meals and snacks, allowing users to
easily search and select food items from the database.
• Provides options for specifying serving sizes, meal categories, and custom en-
tries for homemade dishes.

Nutritional Information Display:


14
• Displays detailed nutritional information for logged food items, including calo-
rie count, macronutrient distribution, and micronutrient content.
• Presents nutritional data in a clear and organized format for easy comprehen-
sion.

Calorie Calculation Summary:


• Provides users with a summary of their total calorie intake for each meal and
the entire day, along with recommendations for adjusting dietary habits if nec-
essary.
• Highlights areas where users may exceed or fall short of their calorie goals.

Progress Tracking Tools:


• Offers tools for users to track their progress towards health and fitness goals,
including weight management, physical activity, and adherence to nutritional
targets.
• Displays progress charts, graphs, and reports to visualize trends and milestones
over time.

Recipe Discovery and Meal Planning:


• Facilitates recipe discovery and meal planning by providing a searchable data-
base of recipes, meal ideas, and cooking inspiration.
• Allows users to create customized meal plans, generate shopping lists, and
schedule meals for the week ahead.

Social Sharing and Community Engagement:


• Integrates social sharing features to allow users to share their progress, achieve-
ments, and favorite recipes with friends and followers on social media.
• Encourages community engagement through forums, discussion boards, and
user-generated content sharing.

Admin Panel Interface:


• Provides administrators with a comprehensive interface for managing user ac-
counts, content, data, and system configurations.
• Offers tools for user management, content moderation, analytics, and reporting.

Responsive Design:
• Ensures that the application is accessible and user-friendly across various de-
vices and screen sizes, including desktops, laptops, tablets, and smartphones.
• Adapts the layout and functionality to provide an optimal viewing and interac-
11
15
tion experience on different devices.

Customization Options:
• Allows users to customize their experience by adjusting settings such as calorie
goals, dietary preferences, meal plans, and notification preferences.
• Provides options for personalizing the interface, themes, and user preferences
to suit individual preferences and needs.

OBJECTIVES:

1. Clarity and Readability: Ensure that the output design presents information
clearly and is easily readable for users of all levels. Use appropriate fonts, font
sizes, colors, and formatting to enhance readability and comprehension.

2. Accuracy and Precision: Aim for accurate representation of calorie and nutri-
tional information in the output design. Ensure that calculations are precise and
that there are no errors or inconsistencies in the displayed data.

3. Relevance and Context: Present output in a manner that is relevant and con-
textually meaningful to the user's goals and preferences. Tailor the display of
information based on the user's dietary objectives, such as weight loss, muscle
gain, or maintenance.

4. Interactivity and User Engagement: Incorporate interactive elements into the


output design to enhance user engagement and encourage exploration. Provide
options for users to interact with the data, such as filtering, sorting, and custom-
ization features.

5. Visualization and Graphical Representation: Utilize visual elements such as


charts, graphs, and diagrams to present data in a visually appealing and intuit-
ive manner. Visual representations can help users quickly grasp trends, pat-
terns, and insights from the data.

6. Consistency and Branding: Maintain consistency in the output design across


different screens and sections of the application. Use consistent design ele-
ments, branding guidelines, and layout principles to create a cohesive and uni-
fied user experience.
7. Accessibility and Inclusivity: Ensure that the output design is accessible to
users with diverse needs and abilities. Consider factors such as color contrast,
16
screen reader compatibility, and keyboard navigation to make the output design
inclusive and accessible to all users.

8. Flexibility and Customization: Provide options for users to customize the out-
put design based on their preferences and requirements. Allow users to adjust
settings such as display preferences, unit measurements, and language options
to tailor the output to their needs.

9. Feedback and Guidance: Incorporate feedback mechanisms and guidance


prompts into the output design to assist users in interpreting and understanding
the displayed information. Provide contextual help tooltips, explanatory text,
and error messages as needed to guide users through the output.

10.Performance and Responsiveness: Ensure that the output design is optimized


for performance and responsiveness across different devices and screen sizes.
Prioritize fast loading times, smooth transitions, and seamless navigation to de-
liver a positive user experience.

11
17
3. SYSTEM ARCHITECTURE:

18
• A deaf person signs through the sign language keyboard displayed in
an application.

• The Hearing person read it or view the sign language through hand speak.

• The Deaf and Dumb people can learn the sigh language.

• The Normal people can also learn the sign language so that, they can
also easily communicate with them.

• Software translates signs into text and speech.

• The concept of a camera-based sign language recognition system for the


deaf, which would transform sign language gestures to text and speech.

• It creates a user-friendly and straightforward solution.

• Dumb individuals communicate via hand signs, thus normal folks have a
hard time to understand what they are saying .As a result, systems that
recognize various signs and deliver information to ordinary people are
required.

11
19
3.1 UML DIAGRAMS:
The Unified Modelling Language (UML) It is a way to visually represent the
architecture, design, and implementation of complex software system they are
again divided into subcategories: UML is an acronym that stands for Unified
Modelling Language. Simply put, UML is a modern approach to modelling and
documenting software. In fact, it’s one of the most popular techniques. It is
based on diagrammatic representations of software components.

UML was created because of the chaos revolving around software development
and documentation. In the 1990s, there were several different ways to represent
and document software systems. The need arose for a more unified way to vis-
ually represent those systems and as a result, in 1994-1996, the UML was de-
veloped by three software engineers working at Rational Software. It was later
adopted as the standard in 1997 and has remained the standard ever since, re-
ceiving only a few updates.

GOALS:

The Primary goals in the design of the UML are as follows:

o Provide users a ready-to-use, expressive visual modelling Lan-


guage so that they can develop and exchange meaningful models.
o Provide extendibility and specialization mechanisms to extend the
core concepts.
o Be independent of programming languages and development
process.
o Provide a formal basis for understanding the modelling language.

o Encourage the growth of OO tools market.

20
o Support higher level development concepts such as collaborations,
framework, patterns and components.
o Integrate best practices.

The Unified Modelling Language (UML) It is a way to visually represent the


architecture, design, and implementation of complex software system they are
again divided into subcategories:

1. Behavioral Diagrams

2. Structural Diagrams
Behavioral Diagrams:

Behavioral Diagrams basically capture the dynamic aspect of a system. Dy-


namic aspects can be further described as the changing/moving parts of a sys-
tem.
1. Use case diagram

2. Activity diagram

3. Sequence diagram
Structural Diagrams:

The Structural Diagrams represent the static aspect of the system. These static
parts are representation by classes, interface, object, components, and nodes.
1. Class diagram

2. Component diagram

11
21
3.2 USE CASE DIAGRAM:

A use case diagram is the high-level functions and scopes of as system. These
diagrams also identify the interactions between the system and its actors. The
use case and actors in use-case diagrams describe what the system does and
how the actors use it, but not how the system operates internally. Its purpose is
to present a graphical overview of the functionality provided by a system in
terms of actors, their goals (represented as use cases), and any dependencies be-
tween those use cases. The main purpose of a use case diagram is to show what
system functions are performed for which actor. Roles of the actors in the sys-
tem can be depicted.

There are 3 major components in a use case diagram:


Functional requirements:

Represented as use cases or a verb describing an action.


Actors:

These are entities that interacts with the system. An actor can be a human being,
an organisation or an internal or external application.
Relationships:

Between actors and use cases represented using straight arrows Due to their
simplistic nature, use case diagrams can be good communication tool for stake-
holders. The drawings attempt to mimic the real world and provide a view for
the stakeholders to understand how the system is going to be designed.

22
11
23
3.3 ACTIVITY DIAGRAM:

Activity diagram is basically a flowchart to represent the flow from one activity
to another activity. The activity can be described as an operation of the system.
In the Unified Modelling Language, Activity diagrams are intended to model
both computational and organizational processes (i.e., workflows), as well as
the data flows intersecting with the related activities. Although activity dia-
grams primarily show the overall flow of control, they can also include elements
showing the flow of data between the activities through one or more data stores.
Basic components of an activity diagram:

 Action:

A step in the activity wherein the users or software perform a given


task. In Lucidchart, actions are symbolized with round-edged rectan-
gles.

 Decision node:

A conditional branch in the flow that is represented by a diamond. It in-


cludes a single input and two or more outputs.

 Control flows:

Another name for the connectors that show the flow between steps in the di-
agram.

 Start node:

Symbolizes the beginning of the activity. The start node is represented


by a black circle.

 End node:

Represents the final step in the activity. The end node is represented by
an outlined black circle.

24
11
25
26
3.4 SEQUENCE DIAGRAM:

Sequence diagram from the name, the diagram deals with some sequences,
which are the sequence of messages flowing from one object to another.A se-
quence diagram shows object interactions arranged in time sequence. A se-
quence diagram shows object interaction arranged in time sequence. It shows as
parallel vertical lines(lifeline), different objects that live simultaneously, and as
horizontal arrows, the messages exchanged between them in order in which they
occur. This allows the specification of simple runtime scenarios in graphical
manner. I depict the objects and classes involved in the scenario and the se-
quence of messages exchanged between the objects needed to carry out the
functionality of the scenario. Sequence diagrams are typically associated with
the use case realizations in the logical view of the system under development.
Benefits of sequence diagrams:

Sequence diagrams can be useful references for businesses and other organiza-
tions.

• Represent the details of a UML use case.

• Model the logic of a sophisticated procedure, function, or operation.

• See how objects and components interact with each other to complete a
process.

• Plan and understand the detailed functionality of an existing or future


scenario.

11
27
28
3.5 COLLABORATION DIAGRAM:

The collaboration diagram is used to show the relationship between the objects
in a system. An object consists of several features. Multiple objects present in
the system are connected to each other. It is used to portray the object’s archi-
tecture in the system. It represents the interaction of the objects to perform the
behaviour of a particular use case or a part of use case. The designers use the
Sequence diagram and Collaboration Diagrams to define and clarify the roles of
the objects that perform a particular flow of events of a use case.
Notations of Collaboration Diagram:

Objects
 Each object in the collaboration is named and has its class specified.

 Not all classes need to appear.

 There may be more than one object of a class.


Actors
 Each Actor is named and has a role.

 One actor will be the initiator of the use case.


Links
A link is a relationship among objects across which messages can be sent.
In collaboration diagrams, a link is shown as a solid line between two ob-
jects.
Messages
 The message is directed from sender to receiver. A message is a commu-
nication between objects that conveys information with the expectation
that activity will ensure.

11
29
30
3.6 CLASS DIAGRAM:

Class diagram consists of classes, interface, association, and collaboration.


Class diagrams basically represent the object-oriented view of a system, which
is static in nature. The class diagram also referred as object modelling is the
main static analysis diagram. The main task of object modelling is to graphi-
cally show what each object will do in the problem domain. The problem do-
main describes the structure and the relationships among objects.
Class Notation
A class notation consists of three parts:

Class Name

 The name of the class appears in the first partition.


Class Attributes

 Attributes are shown in the second partition.


 The attribute type is shown after the colon.
 Attributes map onto member variables (data members) in code.
Class Operations (Methods)

 Operations are shown in the third partition. They are servicing the
class provides.
 The return type of a method is shown after the colon at the end of
the method signature.
 The return type of method parameters is shown after the colon
following the parameter name.
 Operations map onto class methods in code.

4. TESTING AND DEBUGGING


4.1 INTRODUCTION:
Testing is the process of evaluating a system or its component(s) with the intent
to find whether it satisfies the specified requirements or not. In simple words,
testing is executing a system to identify any gaps, errors, or missing require-
ments in contrary to the actual requirements. Testing is a method to check
whether the actual software product matches expected requirements and to en-
sure that software product is Defect free. It involves execution of software/sys-
11
31
tem components using manual or automated tools to evaluate one or more prop-
erties of interest.
The purpose of testing is to discover errors. Testing is the process of trying to
discover every conceivable fault or weakness in a work product. It provides a
way to check the functionality of components, sub-assemblies, or a finished
product. It is the process of exercising software with the intent of ensuring that
the Software system meets its requirements and user expectations and does not
fail in an unacceptable manner. There are various types of tests. Each test type
addresses a specific testing requirement.
Testing is Important because if there are any bugs or errors in the software, it
can be identified early and can be solved before delivery of the software prod-
uct. Properly tested software product ensures reliability, security and high per-
formance which further results in time saving, cost effectiveness and customer
satisfaction. The benefits of testing include preventing bugs, reducing develop-
ment costs and improving performance.

32
4.2TYPES OF TESTS:
4.2.1 UNIT TESTING:
A Unit test is a way of testing a unit the smallest piece of code that can be logi-
cally isolated in a system. Unit testing involves the design of test cases that vali-
date that the internal program logic is functioning properly, and that program in-
puts produce valid outputs. All decision branches and internal code flow should
be validated. It is the testing of individual software units of the application .It is
done after the completion of an individual unit before integration. This is a
structural testing, that relies on knowledge of its construction and is invasive.
Unit tests perform basic tests at component level and test a specific business
process, application, or system configuration. Unit tests ensure that each unique
path of a business process performs accurately to the documented specifications
and contains clearly defined inputs and expected results.

The purpose of unit testing is to validate that each unit of the software works as
intended and meets the requirements. Unit tests are automated and are run each
time the code is changed to ensure that new code does not break existing func-
tionality. Unit tests are designed to validate the smallest possible unit of code,
such as a function or a method, and test it in isolation from the rest of the sys -
tem. This allows developers to quickly identify and fix any issues early in the
development process, improving the overall quality of the software and reduc-
ing the time required for later testing.

11
33
4.2.2 INTEGRATION TESTING:

Integration tests are designed to test integrated software components to deter-


mine if they run as one program. Testing is event driven and is more concerned
with the basic outcome of screens or fields. Integration tests demonstrate that al-
though the components were individually satisfaction, as shown by successfully
unit testing, the combination of components is correct and consistent. Integra-
tion testing is specifically aimed at exposing the problems that arise from the
combination of components.

Integration testing is the process of testing the interface between two software
units or modules. It focuses on determining the correctness of the interface.
The purpose of integration testing is to expose faults in the interaction between
integrated units. Once all the modules have been unit tested, integration testing
is performed. The goal of integration testing is to identify any problems or bug
that arise when different components are combined and interact with each
other.

Integration testing can be done by picking module by module. This can


be done so that there should be proper sequence to be followed. And, if you
don’t want to miss out on any integration scenarios then you must follow the
proper sequence. Exposing the defects is the major focus of the integration
testing and the time of interaction between the integrated units.

34
4.2.3 FUNCTIONAL TEST:
Functional tests provide systematic demonstrations that functions tested are
available as specified by the business and technical requirements, system docu-
mentation, and user manuals.
Functional testing is based on the following items:

Valid Input: identified classes of valid input must be accepted.


Invalid Input: identified classes of invalid input must be rejected.
Functions: identified functions must be exercised.
Output : identified classes of application outputs must be exercised.
Systems/Procedures: interfacing systems or procedures must be invoked.
Organization and preparation of functional tests is focused on requirements, key
functions, or special test cases. In addition, systematic coverage pertaining to
identify Business process flows; data fields, predefined processes, and succes-
sive processes must be considered for testing. Before functional testing is com-
plete, additional tests are identified and the effective value of current tests is de-
termined.

11
35
4.2.4 SYSTEM TEST:
System testing ensures that the entire integrated software system meets require-
ments. It tests a configuration to ensure known and predictable results. An ex-
ample of system testing is the configuration-oriented system integration test.
System testing is based on process descriptions and flows, emphasizing pre-
driven process links and integration points.
This type of testing is performed after the integration testing and before the ac-
ceptance testing. In system testing, integration testing passed components are
taken as input. The goal of integration testing is to detect any irregularity be-
tween the units that are integrated together. System testing detects defects
within both the integrated units and the whole system. System testing is carried
out on the whole system in the context of either system requirement specifica-
tions or functional requirement specifications or in the context of both.

4.2.5 WHITE BOX TESTING:


White Box Testing is a testing in which in which the software tester has knowl-
edge of the inner workings, structure, and language of the software, or at least
its purpose. It is used to test areas that cannot be reached from a black box level.
White box testing involves testing the internal structure and workings of a soft-
ware application. The tester has access to the source code and uses this knowl-
edge to design test cases that can verify the correctness of the software at the
code level. White box testing is also known as structural testing or code- based
testing, and it is used to test the software’s internal logic, flow, and structure.
The tester creates test cases to examine the code paths and logic flows to ensure
that they meet the specified requirements.

36
4.2.6 BLACK BOX TESTING:
Black Box Testing is testing the software without any knowledge of the inner
workings, structure or language of the module being tested. Black box tests, as
most other kinds of tests, must be written from a definitive source document,
such as specification or requirements document, such as specification or re-
quirements document. It is a testing in which the software under test is treated,
as a black box testing. You cannot “see” into it. The test provides inputs and re-
sponds to outputs without considering how the software works. Black Box Test-
ing mainly focuses on input and output of software applications and it is entirely
based on software requirements and specifications. It is also known as Be-
havioural Testing. In this method, tester selects a function and gives input value
to examine its functionality and checks whether the function is giving expected
output or not. If the function produces correct output, then it is passed in testing,
otherwise failed. The test team reports the result to the development team and
then tests the next function. After completing testing of all functions if there are
severe problems, then it is given back to the development team for correction.

11
37
4.3TEST CASES
Test strategy and approach:

Field testing will be performed manually, and functional tests will be written in de-
tail.
Test objectives:

• All field entries must work properly.

• Pages must be activated from the identified link.

• The entry screen, messages and responses must not be delayed.

Features to be tested:

• Verify that the entries are in the correct format.

• No duplicate entries should be allowed.

• All links should take the user to the correct page.

38
Integration Testing:

Software integration testing is the incremental integration testing of two or


more integrated software components on a single platform to produce failures
caused by interface defects. The task of the integration test is to check that
components or software applications, e.g. components in a software system
or– one step up–software applications at the company level – interact without
error.
Test Results:

All the test cases mentioned above passed successfully. No defects encountered.

Acceptance Testing:

User Acceptance Testing is a critical phase of any project and requires signifi-
cant participation by the end user. It also ensures that the system meets the
functional requirements.
Test Results:

All the test cases mentioned above passed successfully. No defects encountered.

11
39
5. CODE & OUTPUT SCREENS

40
11
41
42
11
43
44
11
45
46
11
47
6. CONCLUSION

Maintaining a healthy lifestyle has been one of the main concerns of this century. Ac-
cording to WHO in 2016, more than 1.9 billion adults, 18 years and older, were over-
weight. Of these over 650 million were obese. With the covid-19 outbreak this year it
has been proved that covid-19 is more fatal to people with obesity. So regular exercise
and healthy diet is an important thing people are looking into. With this in mind, I
thought how about I make a calorie tracker with python Django. I have been learning
Django by myself for a while now so I thought it would be a good project to skill up
my Django than following project tutorials. Enough about other things, lets get to the
coding part. This might be a little hard for absolute django beginner, so basic knowl-
edge of django will be helpful in understanding.

48
6. FUTURESCOPE

For a calorie tracking application, you'll likely want users to be able to log their
meals, specify the number of calories in each meal, and possibly track their physi-
cal activities to calculate the net calorie intake. You might also want to provide
features for setting goals, viewing reports, and analyzing trends over time.

Remember to consider scalability, security, and user experience throughout the


development process. Django provides powerful tools for building web applica-
tions, so take advantage of its features to create a robust and user-friendly calorie
tracking app.

11
49
7. REFERENCES

[1] Benjarat Tirasirichai, Worapan Kusakunniran, Peeraya Thanomboon Pim-


paknat Soontorntham, “Bloom Balance: Calorie Balancing Application with
scientific Validation” 15th International Joint Conference on Computer Sci-
ence and Software Engineering(JCSSE), 2018.
[2] Nor Aziah Amirah Nor Muhammad, Chin Poo Lee, Kian Ming Lim, Siti Fa-
timah Abdul Razak “Malaysian Food Recognition and Calorie Counter Ap-
plication” 2017 IEEE 15th Student Conference on Research and Develop-
ment (SCOReD), 2017.
[3] Md. Nasfikur R. Khan*, W. Faarhin Durdana, Robin Roy, Gobinda Poddar,
Sabrina Ferdous, A K Ehsanul Haque Mashuk “Health Guardian – A Sub-
sidiary Android Application For Maintaining Sound Health” International
Conference on Recent Innovations in Electrical, Electronics & Communi-
cation Engineering(ICRIEECE), 2018.
[4] Shirmohammadi, "Food calorie measurement using deep learning neural net-
work,“ in Instrumentation and Measurement Technology Conference Pro-
ceedings (I2MTC), pp. 1-6: IEEE, 2016.
[5] R Pawan Sai, Suma Bapanapalle and Praveen K, Sunil MP, “Pedometer
and Calorie Calculator for Fitness Tracking Using MEMS Digital Ac-
celerometer” International Conference on Inventive Computation Technolo-
gies (ICICT), 2016.
[6] P. Parisa, S. Shervin, Rana Al-Maghrabi, "MeasuringCalorie and Nutrition
From Food Image," IEEE Transactionson Instrumentation and Measure-
ment, Volume: 63, Issue: 8, pp.1947-1956: IEEE, Feb. 2014.
[7] McAllister, H. Zheng, R. Bond, and A. Moorhead, "Semi-automated system for
predicting calories in photographs of meals," in Engineering, Technology
and Innovation International Technology Management Conference (ICE/
ITMC) pp. 1-6: IEEE, 2015.
[8] Shahreen Kasim, Faten Azmira Zakaria “Daily Calorie Third International
50
[9] Manager for Basic daily use”Conference on Innovative Computing Technol-
ogy (INTECH), 2015.

8. APPENDIX-A

Technologies used:
PYTHON
Python is an interpreted high-level programming language for general-purpose
programming. Created by Guido van Rossum and first released in 1991, Python
has a design philosophy that emphasizes code readability, notably using signifi-
cant whitespace.
Python features a dynamic type of system and automatic memory management.
It supports multiple programming paradigms, including object-oriented, impera-
tive, functional, and procedural, and has a large and comprehensive standard li-
brary.
 Python is Interpreted − Python is processed at runtime by the interpreter.
You do not need to compile your program before executing it. This is similar to
PERL and PHP.
 Python is Interactive − you can actually sit at a Python prompt and inter-
act with the interpreter directly to write your programs.
Python also acknowledges that speed of development is important. Readable
and terse code is part of this, and so is access to powerful constructs that avoid
tedious repetition of code. Maintainability also ties into this may be an all but
useless metric, but it does say something about how much code you have to
scan, read and/or understand to troubleshoot problems or tweak behaviours.
This speed of development, the ease with which a programmer of other lan-
guages can pick up basic Python skills and the huge standard library is key to
another area where Python excels.

11
51
Python is a general-purpose interpreted, interactive, object-oriented, and high-
level programming language. An interpreted language, Python has a design
philosophy that emphasizes code readability (notably using whitespace inden-
tation to delimit code blocks rather than curly brackets or keywords), and a
syntax that allows programmers to express concepts in fewer lines of code than
might be used in languages such as C++or Java. It provides constructs that en-
able clear programming on both small and large scales. Python interpreters are
available for many operating systems. CPython, the reference implementation
of Python, is opensource software and has a community-based development
model, as do nearly all of its variant implementations. CPython is managed by
the non-profit Python Software Foundation. Python features a dynamic type
system and automatic memory management. It supports multiple programming
paradigms, including object-oriented, imperative, functional and procedural,
and has a large and comprehensive standard library.
The biggest strength of Python is huge collection of standard libraries which
can be used for the following –
 Machine Learning
 GUI Applications (like Kivy, Tkinter, PyQt etc.)
 Web frameworks like Django (used by YouTube, Instagram)
 Image processing (like OpenCV, Pillow)
 Web scraping (like Scrapy, BeautifulSoup, Selenium)
 Test frameworks
 Multimedia

52
Advantages of Python: -

Extensive Libraries

Python downloads with an extensive library and it contain code for various pur-
poses like regular expressions, documentation-generation, unit-testing, web
browsers, threading, databases, CGI, email, image manipulation, and more. So,
we don’t have to write the complete code for that manually.
Extensible

As we have seen earlier, Python can be extended to other languages. You can
write some of your code in languages like C++ or C. This comes in handy, es-
pecially in projects.
Embeddable

Complimentary to extensibility, Python is embeddable as well. You can put


your Python code in your source code of a different language, like C++. This
lets us add scripting capabilities to our code in the other language.

Improved Productivity

The language’s simplicity and extensive libraries render programmers more


productive than languages like Java and C++ do. Also, the fact that you need to
write less and get more things done.
IOT Opportunities

Since Python forms the basis of new platforms like Raspberry Pi, it finds the fu-
ture bright for the Internet Of Things. This is a way to connect the language
with the real world.

11
53
Simple and Easy

When working with Java, you may have to create a class to print ‘Hello
World’. But in Python, just a print statement will do. It is also quite
easy to learn, understand, and code. This is why when people pick up
Python, they have a hard time adjusting to other more verbose languages like
Java.
Readable

Because it is not such a verbose language, reading Python is much like reading
English. This is the reason why it is so easy to learn, understand, and code. It
also does not need curly braces to define blocks, and indentation is manda-
tory. This further aids the readability of the code.
Object-Oriented

This language supports both the procedural and object-oriented programming


paradigms. While functions help us with code reusability, classes and objects let
us model the real world. A class allows the encapsulation of data and func-
tions into one.
Free and Open-Source

Like we said earlier, Python is freely available. But not only can you down-
load Python for free, but you can also download its source code, make changes
to it, and even distribute it. It downloads with an extensive collection of li-
braries to help you with your tasks.
Portable

When you code your project in a language like C++, you may need to make
some changes to it if you want to run it on another platform. But it isn’t the
same with Python. Here, you need to code only once, and you can run it any-
where. This is called Write Once Run Anywhere (WORA). However, you
need to be careful enough not to include any system-dependent features.

54
Interpreted

Lastly, we will say that it is an interpreted language. Since statements are exe-
cuted one by one, debugging is easier than in compiled languages.

Machine Learning:

Machine learning is often categorized as a subfield of artificial intelligence, but


I find that categorization can often be misleading at first brush. The study of
machine learning certainly arose from research in this context, but in the data
science application of machine learning methods, it's more helpful to think of
machine learning as a means of building models of data.

Fundamentally, machine learning involves building mathematical models to


help understand data. "Learning" enters the fray when we give these models
tuneable parameters that can be adapted to observed data; in this way the pro-
gram can considered to be "learning" from the data.
Definition of learning is a computer program is said to learn from experience
E with respect to some class of tasks T and performance measure P , if its per -
formance at tasks T, as measured by P , improves with experience E.
Once these models have been fit to previously seen data, they can be used to
predict and understand aspects of newly observed data. I'll leave to the reader
the more philosophical digression regarding the extent to which this type
of mathematical, model-based "learning" is like the "learning" exhibited by
the human brain.

Machine learning is a subfield of artificial intelligence that involves the devel-


opment of algorithms and statistical models that enable computers to improve
their performance in tasks through experience. These algorithms and models are
designed to learn from data and make predictions or decisions without explicit
instructions.

11
55
Machine learning is programming computers to optimize a performance crite-
rion using example data or past experience. We have a model defined up to
some parameters, and learning is the execution of a computer program to opti-
mize the parameters of the model using the training data or past experience. The
model may be predictive to make predictions in the future, or descriptive to gain
knowledge from data.

Types of Machine Learning

 Supervised Learning:
This involves learning from a training dataset with labelled data using classifi-
cation and regression models. This learning process continues until the required
level of performance is achieved.
Unsupervised Learning:
This involves using unlabelled data and then finding the underlying structure in
the data in order to learn more and more about the data itself using factor and
cluster analysis models.
Semi-supervised Learning:
This involves using unlabelled data like Unsupervised Learning with a small
amount of labeled data. Using labeled data vastly increases the learning accu-
racy and is also more cost-effective than Supervised Learning.
Reinforcement Learning:
This involves learning optimal actions through trial and error. So the next ac-
tion is decided by learning behaviors that are based on the current state and that
will maximize the reward in the future.

56
Advantages of Machine learning:-

Easily identifies trends and patterns -

Machine Learning can review large volumes of data and discover specific
trends and patterns that would not be apparent to humans. For instance, for an e-
commerce website like Amazon, it serves to understand the browsing behav-
iours and purchase histories of its users to help cater to the right products, deals,
and reminders relevant to them. It uses the results to reveal relevant advertise-
ments to them.
No human intervention needed (automation)

With ML, you don’t need to babysit your project every step of the way. Since it
means giving machines the ability to learn, it lets them make predictions and
also improve the algorithms on their own. A common example of this is anti-
virus softwares; they learn to filter new threats as they are recognized. ML is
also good at recognizing spam.
Continuous Improvement

As ML algorithms gain experience, they keep improving in accuracy and effi-


ciency. This lets them make better decisions. Say you need to make a weather
forecast model. As the amount of data you have keeps growing, your algorithms
learn to make more accurate predictions faster.
Handling multi-dimensional and multi-variety data

Machine Learning algorithms are good at handling data that are multi- dimen-
sional and multi-variety, and they can do this in dynamic or uncertain environ-
ments.

11
57
Wide Applications

You could be an e-tailer or a healthcare provider and make ML work for you.
Where it does apply, it holds the capability to help deliver a much more per-
sonal experience to customers while also targeting the right customers.
Module Libraries Used in Project :- TensorFlow
TensorFlow is a free and open-source software library for dataflow and differ-
entiable programming across a range of tasks. It is a symbolic math library, and
is also used for machine learning applications such as neural networks. It is
used for both research and production at Google. TensorFlow was developed by
the Google Brain team for internal Google use. It was released under the
Apache
2.0 open-source license on November 9, 2015.

NumPy

NumPy is a general-purpose array-processing package. It provides a high- per-


formance multidimensional array object, and tools for working with these ar-
rays. It is the fundamental package for scientific computing with Python. It con-
tains various features including these important ones:

 A powerful N-dimensional array object


 Sophisticated (broadcasting) functions
 Useful linear algebra, Fourier transform, and random number capabilities.
Besides its obvious scientific uses, NumPy can also be used as an efficient
multi- dimensional container of generic data. Arbitrary datatypes can be defined
using NumPy which allows NumPy to integrate with a wide variety of data-
bases seamlessly and speedily.

58
Pandas

Pandas is an open-source Python Library providing high-performance data ma-


nipulation and analysis tool using its powerful data structures. Python was ma-
jorly used for data munging and preparation. It had very little contribution to-
wards data analysis. Pandas solved this problem. Using Pandas, we can accom-
plish five typical steps in the processing and analysis of data, regardless of the
origin of data load, prepare, manipulate, model, and analyze. Python with Pan-
das is used in a wide range of fields including academic and commercial do-
mains including finance, economics, Statistics, analytics, etc.
OpenCV

OpenCV is an open-source software library for computer vision and machine


learning. The OpenCV full form is Open-Source Computer Vision Library. It
was created to provide a shared infrastructure for applications for computer vi-
sion and to speed up the use of machine perception in consumer products.
OpenCV, as a BSD-licensed software, makes it simple for companies to use and
change the code.
Tkinter
Tkinter is the de facto way in Python to create Graphical user interface and it
included in all standard Python Distributions. In fact, it’s the only framework
built into the Python standard library.
Imutils

A series of convenience functions to make basic image processing functions


such as translation, rotation, resizing, skeletonization, displaying Matplotlib im-
ages, sorting contours, detecting edges, and much easier with OpenCV and both
Python

11
59
Keras

Keras is a high-level, deep learning API developed by Google for implementing


neural networks. It is used to make the implementation of neural networks easy.
It also supports multiple backend neural network computation. Keras is rela-
tively easy to learn and work with because it provides a python frontend with a
high level of abstraction while having the option of multiple back-ends for
computation purposes. This makes Keras slower than other deep learning
frameworks, but extremely beginner friendly.

Scikit – learn

Scikit-learn provides a range of supervised and unsupervised learning algo-


rithms via a consistent interface in Python. It is licensed under a permissive sim-
plified BSD license and is distributed under many Linux distributions, encour-
aging academic and commercial use.

Matplotlib

Matplotlib is a Python 2D plotting library which produces publication quality figures in a va-
riety of hardcopy formats and interactive environments across platforms. Matplotlib can be
used in Python scripts, the Python and IPython shells, the Jupyter Notebook, web application
servers, and four graphical user interface toolkits. Matplotlib tries to make easy things easy
and hard things possible. You can generate plots, histograms, power spectra, bar charts, error
charts, scatter plots, etc., with just a few lines of code. For examples, see the sample
plots and thumbnail gallery.
For simple plotting the pyplot module provides a MATLAB-like interface, particularly when
combined with IPython. For the power user, you have full control of line styles, font proper-
ties, axes properties, etc, via an object oriented interface or via a set of functions familiar to
MATLAB users.

60
Playsound
 The playsound module contains only a single function
named playsound().
 It requires one argument: the path to the file with the sound we have
to play. It can be a local file, or a URL.
 There’s an optional second argument, block, which is set to True by
default. We can set it to False for making the function
run asynchronously.
 It works with both WAV and MP3 files.

11
61

You might also like