You are on page 1of 32

SGPA CALCULATOR USING PYTHON

Acknowledgements

The author is highly grateful to Dr. Akshay Girdhar, Professor, Guru Nanak Dev Engineering
College, Ludhiana, for encouraging the author to take up the project.

Apart from the efforts of ourselves, the success of our project depends largely on the
encouragement and guidelines of many others. We take this opportunity to express our gratitude
to the people have been instrumental in the successful completion of this project. We would like
to show the greatest appreciation to our Project Coordinator Ms. Hanit Kaur, Assistant Professor,
Guru Nanak Dev Engineering College, Ludhiana, who helped us in accomplishing this goal. We
can’t say thank you enough for her tremendous support and help. We feel motivated and
encouraged every time we attend her meeting. Without her encouragement and guidance this
project would not have materialized.

The guidance and support received from all the members who contributed and who are
contributing to this project, was vital for the success of the project. We are grateful for their
constant support and help.

1
SGPA CALCULATOR USING PYTHON

Abstract

India’s higher education system is highly centralized and undergoing large changes since 1947.
University education is overseen by the University Grants Commission (UGC), which is a
statutory body set up by the Indian Union government in accordance to the UGC Act
1956 under Ministry of Human Resource Development, and is charged with coordination,
determination and maintenance of standards of higher education. It provides recognition to
universities in India, and disbursements of funds to such recognised universities and colleges.

As per the guidelines of the University Grants Commission (UGC), I. K. Gujral Punjab Technical
University (IKGPTU) implements the Choice Based Credit System (CBCS) and Grading System
for the Academic Evaluation of their students. The Choice Based Credit System (CBCS) enables
a student to obtain a degree by accumulating required number of credits prescribed for that
degree. The CBCS enables the students to earn credits across departments and provides flexibility
in duration to complete a Program of study.

The performance of a student is evaluated in terms of two indices, semester grade point average
(SGPA) and cumulative grade point average (CGPA) for the completed semesters at any point
in time. SGPA and CGPA are calculated up to two decimal places rounding off 0.005 to 0.01

Manual Processing of SGPA is subject to human errors. Manual Academic Evaluation and
calculation of student results is too complex and involves lot of time and effort. SGPA Calculator
not only reduces the need to perform the cumbersome process manually but also helps analyse
the results and assess the students in the College or University.

2
SGPA CALCULATOR USING PYTHON

Chapter 1
Introduction

1.1 Introduction to Project

SGPA calculator is a desktop-based and performance-based application. This application


is used to calculate the SGPA (Semester Grade Point Average) of students. It is build
using Python programming language and its GUI (Graphical User Interface) library
Tkinter.

Due to its automation, it saves user’s time and effort. This technology is very useful in
the autonomous and affiliated colleges/institutions of I.K. Gujral Punjab Technical
University, Jalandhar where marks per semester of the students need to be calculated on
the basis of Choice Based Credit System(CBCS). The SGPA calculated will be absolute
according to the guidelines of I.K. Gujral Punjab Technical University.

The Choice Based Credit System (CBCS) enables a student to obtain a degree by
accumulating required number of credits prescribed for that degree. Under CBCS, the
requirement for awarding a degree is prescribed in terms of number of credits and
students are given choices from the pool of elective courses. The CBCS facilitates
transfer of credits earned in different Departments/Centres of other recognized/accredited
universities or institutions of higher education in India and abroad.

1.2 Project Category


SGPA Calculator is a desktop-based application. A desktop-based application can run on
a PC Operating System and has a graphical user interface. A desktop-based application
does not require the need of Internet connection and can be accessed at any part of the
world since it does not run inside the web browser. It can run stand-alone in a desktop or
laptop computer. The project has been programmed in the Python language and certain

3
SGPA CALCULATOR USING PYTHON

Python libraries which have been used include Tkinter and PyInstaller. These libraries
provide a wide range of facilities and help in performing multiple operations.

SGPA Calculator is a performance-based application. A performance-based Application


is aligned to offer high performance, availability and better user experience of the
software application. Performance-based applications provide a robust application for
continuous usage without affecting its speed and performance over the time. It gives us
the resultant Semester Grade Point Average of the concerned student.

1.3 Objectives
The main objectives behind the development of this project are:
 To assist the workforce of the Examination Department in the calculation and
management of Semester Grade Point Average of the students.
 To reduce the paperwork involved for the record generation and verification.
 To ensure timely generation of the students’ Semester-wise SGPA.
 To regulate efficiency and motivation amongst the workforce as well as the
students.

1.4 Existing System


The Existing system has many drawbacks. In the existing system, Excel sheets are
generated for every class and every students’ batch for the year. This is highly tedious
and cumbersome to manually enter the details of thousands of students, followed by
applying Excel functions to them. This also requires a large workforce to be involved for
a long period of time in the compilation of the final SGPA of the students. Such a system
is prone to tremendous errors of Data Entry and Function generation. Following such a
system is hectic for the Examination Department.

1.5 Proposed System


 The proposed system is concerned with reducing the manual workload of
Documentation as well as eliminating the need to perform complex calculations for
each student.
 It will provide timely awareness to the students about their performances in the
Academics and encourage them to perform better in the future.
 It will also reduce the workload of the Examination Department.

4
SGPA CALCULATOR USING PYTHON

1.6 Unique features of the System


The unique features of the SGPA Calculator are as follows:
 The project offers a decent and subtle interface, appropriate for the use at
professional levels.
 The interface is compatible with syllabus formats of both the odd as well as the even
semesters.
 There is no need for separate portals for the different Departments of the University.
 The system will not get obsolete even on the introduction of newer Branches or
Subjects in the curriculum.
 The system can also be used to find the SGPA of students with Backlogs, thereby
giving them a rough estimate of their SGPA. This is very helpful in quick decision
making and filtration of students at the time of Placement Drivese.

5
SGPA CALCULATOR USING PYTHON

Chapter 2
Requirement Analysis and System Specification

2.1 Feasibility Study

Preliminary investigation involves examining the project feasibility, the likelihood the
system will be useful to the organization. The main objective of the feasibility study is to
test the Technical, Operational and Economical feasibility for adding new modules and
debugging old running system. All system is feasible if they are unlimited resources and
infinite time.

Feasibility Study basically involves the study, which determines whether it’s practically
and financially feasible to develop the project. SGPA Calculator helps Examination Head
Officials in calculating overall result of students with ease. They only need to add total
number of theory and practical subjects, their respective credits and marks obtained by
students.

There are aspects in the feasibility study portion of the preliminary investigation:
 Technical Feasibility
 Economic Feasibility
 Operational Feasibility

2.1.1 Technical Feasibility


The technical issue usually raised during the feasibility stage of the investigation includes
the following:

 Does the necessary technology exist to do what is suggested?


 Do the proposed equipment’s have the technical capacity to hold the data required
to use the new system?
 Will the proposed system provide adequate response to inquiries, regardless of the
number or location of users?
6
SGPA CALCULATOR USING PYTHON

 Can the system be upgraded if developed?

SGPA Calculator helps Examination Head Officials in calculating overall result of


students with ease. They only need to add total number of theory and practical subjects,
their respective credits and marks obtained by students.

2.1.2 Economic Feasibility


A system can be developed technically and that will be used if installed must still be a
good investment for the organization. In the economic feasibility, the development cost
in creating the system is evaluated against the ultimate benefit derived from the new
systems. Financial benefits must equal or exceed the costs.

The proposed system tends to reduce the amount of time required to be invested on the
SGPA calculation, which reduces the use of papers and manual labour.

2.1.3 Operational Feasibility


It is mainly related to human organization and political aspects. The points to be
considered are:

 What changes will be brought with the system?


 What organization structures are disturbed?
 What new skills will be required?
 Do the existing staff members have these skills?
 If not, can they be trained in due course of time?

The system is operationally feasible as it very easy for end users to operate. Also, it will
replace the traditional way of using Excel for the computation of Semester Grade Point
Average (SGPA) of the students.

2.2 Software Requirements


The software requirements for the given project to run successfully on a system are:
 Operating System (Windows XP or above/Macintosh)
 Python
 Python IDE like PyCharm, Spyder etc.
 Anaconda Navigator

7
SGPA CALCULATOR USING PYTHON

2.3 Hardware Requirements


The Hardware requirements for successfully running the given project are as follows:
 2GB RAM or above
 500GB Hard Disk or more
 I3 Processor or higher

8
SGPA CALCULATOR USING PYTHON

Chapter 3
System Design

3.1 Design Approach


The project is based upon the functional design approach. A function-oriented design
strategy relies on decomposing the system into a set of interacting functions with a
centralized system state shared by these functions. Functions may also maintain local
state information but only for the duration of their execution.

Function-oriented design has been practiced informally since programming began.


Programs were decomposed into subroutines which were functional in nature. Function-
oriented design conceals the details of an algorithm in a function but system state
information is not hidden. This can cause problems because a function can change the
state in a way which other functions do not expect. Changes to a function and the way in
which it uses the system state may cause unanticipated changes in the behavior of other
functions.

A functional approach to design is therefore most likely to be successful when the amount
of system state information is minimized and information sharing is explicit. Systems
whose responses depend on a single stimulus or input and which are not affected by input
histories are naturally functionally-oriented. Many transaction-processing systems and
business data-processing systems fall into this class. In essence, they are concerned with
record processing where the processing of one record is not dependent on any previous
processing.

3.2 Detailed Design


The process of refining and expanding the preliminary design of a system or component
is enough to the extent that the design is sufficiently complete to begin implementation.
The project design must contain the following features:

9
SGPA CALCULATOR USING PYTHON

• Flexibility: The staff of the Examination Department should be able to use the project
at any time during the day, night or morning (24 hours).

• Command Buttons: Certain operations in screen should carried out using the
command buttons. Every button should carry out the task as the text inscribed in them
e.g. Cancel, Generate SGPA, OK etc. The names of buttons should indicate the task
related to them.
• User Friendly: The system should be user friendly. Even a layman with little
knowledge of computer should be able to work easily on the software.
• Security: The proposed system must be fully secured by a password facility so that
no one can use the system without permission.

3.3 System Design


System Design is the process of defining the architecture, modules, interfaces,
and data for a system to satisfy specified requirements. Systems design could be seen as
the application of systems theory to product development. There is some overlap with the
disciplines of systems analysis, systems architecture and systems engineering.

In the 1990s, standardization of hardware and software resulted in the ability to


build modular systems. The increasing importance of software running on generic
platforms has enhanced the discipline of software engineering.

System designs are essentially of the following types:


• Architectural Design: The architectural design of a system emphasizes the design
of the system architecture that describes the structure, behavior and more viewsof
that system and analysis.
• Logical Design: The logical design of a system pertains to an abstract representation
of the data flows, inputs and outputs of the system. This is often conducted via
modelling, using an over-abstract (and sometimes graphical) model of the actual
system. In the context of systems, designs are included. Logical design includes
entity-relationship diagrams.
• Physical Design: The physical design relates to the actual input and output processes
of the system. This is explained in terms of how data is input into a system, how it
is verified/authenticated, how it is processed, and how it is displayed. In physical
design, the following requirements about the system are decided.

10
SGPA CALCULATOR USING PYTHON

3.3.1 Flowchart
A flowchart is a diagram that represents an algorithm, workflow or process. The
flowchart shows the steps of various kinds and their order by connecting them with
arrows.

Start

Input number
of subjects

Input marks
and Credits

Calculating SGPA

SGPA

Display SGPA

Stop

Figure 3.1 Flowchart of the SGPA Calculator

The flowchart for the SGPA Calculator is as shown in the above figure. The user starts
by entering the number of subjects for the given semester. Here the user also chooses the
type of semester; Training Semester or General Fitness Semester. Next, the user enters
Internal marks and Credits corresponding to each subject. On hitting the OK button, the
SGPA of the student is calculated and displayed on the screen.
11
SGPA CALCULATOR USING PYTHON

3.3.2 Data Flow Diagram


A Data Flow Diagram (DFD) is a graphical representation of the flow of data through an
information system, modelling its process aspects. A DFD is often used as a preliminary
step to create an overview of the system without going into great detail, which can later
be elaborated. DFDs can also be used for the visualization of data processing (structured
design).

SGPA Calculator

User Interface

End-user

Figure 3.2 Basic Data Flow Diagram for SGPA Calculator

The basic data flow diagram for the SGPA Calculator invloves three major components:
The Calculator backend which computes the SGPA; the User Interface that takes the input
from the user; and the End-user thata enters the subjects, credits and the obtained marks
on the interface.

The complete Data Flow Diagram for the SGPA Calculator can be depicted as follows.

Enter no. of subjects


Enter type of semester
Submit
Enter marks & credits
SGPA
End user Calculator Submit Backend
Interface
Returns SGPA
Displays SGPA

Figure 3.3 Complete Data Flow Diagram of SGPA Calculator

The end user initially enters the number of Theory subjects, number of Practical subjects
and the type of semester: Training Semester in case of the odd semester; General fitness
Semester for the even semester.

12
SGPA CALCULATOR USING PYTHON

On clicking the ‘Submit’ button, the data goes to the Backend, from where the appropriate
number of columns are generated for Theory and Practical subjects along with the
Training or General fitness marks. The credits for the same can also be entered.
When the ‘Submit’ button is clicked, the SGPA is calculated and displayed in an alert
box to the user.

3.3.3 UML Diagram

The Unified Modeling Language (UML) is a standard visual modeling language intended
to be used for
 modeling business and similar processes,
 analysis, design, and implementation of software-based systems

UML is a common language for business analysts, software architects and developers
used to describe, specify, design, and document existing or new business processes,
structure and behavior of artifacts of software systems.

The UML Diagram for the SGPA Calculator is as shown follows.

Figure 3.4 UML Diagram for the SGPA Calculator

First, the student or the teacher, i.e. the end-user, enters the number of Theory and
Practical subjects and the type of semester for which the SGPA is to be calculated.
Next, the marks for the different subjects are entered along with their corresponding
credits.
Finally, the system returns the SGPA for the required marks obtained.

3.3.4 Sequence Diagram


A sequence diagram shows object interactions arranged in time sequence. It depicts the
objects and classes involved in the scenario and the sequence of messages exchanged

13
SGPA CALCULATOR USING PYTHON

between the objects needed to carry out the functionality of the scenario. Sequence
diagrams are typically associated with use case realizations in the Logical View of the
system under development. Sequence diagrams are sometimes called event
diagrams or event scenarios.

A sequence diagram shows, as parallel vertical lines (lifelines), different processes or


objects that live simultaneously, and, as horizontal arrows, the messages exchanged
between them, in the order in which they occur. This allows the specification of simple
runtime scenarios in a graphical manner.

The Sequence Diagram for SGPA Calculator is shown as follows.

End User Interface Back End

1: Enter no. of Theory subjects

2: Enter no. of Practical subjects

3: Enter type of semester

4: Click the Submit button


5: Data goes to the Back end

6: Input box for Subjects returned


7: Displays Input box for marks

8: Enters the marks for the subjects

9: Enters the credits for each subject

10: Enters semester-based subject marks

11: Click the Submit button


12: Navigates the data to the back end

13: Returns the calculated SGPA

14: Displays the calculated SGPA

Figure 3.5 Sequence Diagrams for SGPA Calculator

The diagram is quite self-explanatory for the complete understanding of the Project.

14
SGPA CALCULATOR USING PYTHON

3.4 User Interface Design


User Interface Design (UI) or user interface engineering is the design of user
for machines and software, such as computers, home appliances, mobile devices, and
other electronic devices, with the focus on maximizing usability and the user experience.
The goal of user interface design is to make the user's interaction as simple and efficient
as possible, in terms of accomplishing user goals (user-centred design).

Good user interface design facilitates finishing the task at hand without drawing
unnecessary attention to itself. Graphic design and typography are utilized to support
its usability, influencing how the user performs certain interactions and improving the
aesthetic appeal of the design; design aesthetics may enhance or detract from the ability
of users to use the functions of the interface. The design process must balance technical
functionality and visual elements (e.g., mental model) to create a system that is not only
operational but also usable and adaptable to changing user needs.

The key features of the project that comply to the User friendly Interface design are as
follows:
 The color scheme used for the project is solid grey color. This color not only looks
professional but also instill enthusiasm in the workforce and is soothing to the
eyes.
 The font size is neither too large nor too small, thereby ensuring proper readability
as well as focused view of the application.
 The font style used is simple and black in color that enables clear readability of
the text.
 The names of the subjects do not need to be entered for calculating the SGPA.
This reduces the data to be entered by the used and ensures quick results.

15
SGPA CALCULATOR USING PYTHON

Chapter 4
Implementation, Testing and Maintenance

4.1 Implementation
Implementation simply means carrying out the activities described in your work plan.
Implementation gives the opportunity to see the plans become a reality. Execution of
plans not only allow end-users to have access to better services and living environment,
but the success stories also encourage others to adopt similar approaches. On the other
hand, poor planning may not result in the desired outputs.

4.1.1 Introduction to the tools used


The tools required to build the project are the basic foundation for the successful
completion of the project besides the efforts of the developers.

4.1.1.1 Python
Python is an object-oriented, high-level
programming language with integrated dynamic
semantics primarily for web and app development. It
is extremely attractive in the field of Rapid
Application Development because it offers dynamic
typing and dynamic binding options. Figure 4.1 Python Logo

Python is relatively simple, so it's easy to learn since it requires a unique syntax that
focuses on readability. Developers can read and translate Python code much easier
than other languages. In turn, this reduces the cost of program maintenance and
development because it allows teams to work collaboratively without significant
language and experience barriers.

Additionally, Python supports the use of modules and packages, which means that
programs can be designed in a modular style and code can be reused across a variety

16
SGPA CALCULATOR USING PYTHON

of projects. Once you've developed a module or package you need, it can be scaled
for use in other projects, and it's easy to import or export these modules.

4.1.1.1.1 Features of Python

The basic features of Python are as follows:


 Easy to learn and use: Python is easy to learn and use. It is developer-
friendly and high level programming language.
 Expressive Language: Python language is more expressive means that it is
more understandable and readable.
 Interpreted Language: Python is an interpreted language i.e. interpreter
executes the code line by line at a time. This makes debugging easy and thus
suitable for beginners
 Cross-platform Language: Python can run equally on different platforms
such as Windows, Linux, Unix and Macintosh etc. So, we can say that
Python is a portable language.
 Free and Open source: Python language is freely available at official web
address. The source-code is also available. Therefore, it is open source.
 Object-Oriented language: Python supports object oriented language and
concepts of classes and objects come into existence.
 Extensible: It implies that other languages such as C/C++ can be used to
compile the code and thus it can be used further in our python code.
 Large Standard Library: Python has a large and broad library and
provides rich set of module and functions for rapid application development.
 GUI Programming Support: Graphical user interfaces can be developed
using Python.
 Integrated: It can be easily integrated with languages like C, C++, JAVA
etc.

4.1.1.1.2 Advantages of Python


There are many advantages of using Python. Some of these are given below:
 Extensive Support Libraries: It provides large standard libraries that
include the areas like string operations, Internet, web service tools, operating
system interfaces and protocols. Most of the highly used programming tasks

17
SGPA CALCULATOR USING PYTHON

are already scripted into it that limits the length of the codes to be written in
Python.
 Integration Feature: Python integrates the Enterprise Application
Integration that makes it easy to develop Web services by invoking COM or
COBRA components. It has powerful control capabilities as it calls directly
through C, C++ or Java via Jython. Python also processes XML and other
markup languages as it can run on all modern operating systems through
same byte code.

 Improved Programmer’s Productivity: The language has extensive


support libraries and clean object-oriented designs that increase two to ten-
fold of programmer’s productivity while using the languages like Java, VB,
Perl, C, C++ and C#.

 Productivity: With its strong process integration features, unit testing


framework and enhanced control capabilities contribute towards the
increased speed for most applications and productivity of applications. It is
a great option for building scalable multi-protocol network applications.

4.1.1.1.3 Disadvantages of Python


A few disadvantages of Python are as follows:
 Difficulty in Using Other Languages: The Python lovers become so
accustomed to its features and its extensive libraries, so they face problem in
learning or working on other programming languages. Python experts may
see the declaring of cast “values” or variable “types”, syntactic requirements
of adding curly braces or semi colons as an onerous task.

 Weak in Mobile Computing: Python has made its presence on many


desktop and server platforms, but it is seen as a weak language for mobile
computing. This is the reason very few mobile applications are built in it like
Carbonnelle.

 Gets Slow in Speed: Python executes with the help of an interpreter instead
of the compiler, which causes it to slow down because compilation and
execution help it to work normally. On the other hand, it can be seen that it
is fast for many web applications too.

18
SGPA CALCULATOR USING PYTHON

 Run-time Errors: The Python language is dynamically typed so it has many


design restrictions that are reported by some Python developers. It is even
seen that it requires more testing time, and the errors show up when the
applications are finally run.

 Underdeveloped Database Access Layers: As compared to the popular


technologies like JDBC and ODBC, the Python’s database access layer is
found to be bit underdeveloped and primitive. However, it cannot be applied
in the enterprises that need smooth interaction of complex legacy data.

4.1.1.2 Tkinter

Python offers multiple options for developing GUI (Graphical User Interface). Out of
all the GUI methods, tkinter is most commonly used method. It is a standard Python
interface to the Tk GUI toolkit shipped with Python. Python with tkinter outputs the
fastest and easiest way to create the GUI applications. Creating a GUI using tkinter is
an easy task.

4.1.1.2.1 Creating tkinter


To create a tkinter, the following steps need to be followed:
1. Importing the module – tkinter
2. Create the main window (container)
3. Add any number of widgets to the main window
4. Apply the event Trigger on the widgets.
Importing tkinter is same as importing any other module in the python code. Note
that the name of the module in Python 2.x is ‘Tkinter’ and in Python 3.x is
‘tkinter’.

import tkinter

There are two main methods used you the user need to remember while creating
the Python application with GUI.

1. Tk(screenName=None, baseName=None, className=’Tk’, useTk=1)


: In order to create a main window, tkinter offers a method
‘Tk(screenName=None, baseName=None, className=’Tk’, useTk=1)’.
To change the name of the window, you can change the className to the

19
SGPA CALCULATOR USING PYTHON

desired one. The basic code used to create the main window of the
application is:
m=tkinter.Tk()

Here, m is the name of the main window object.

2. mainloop(): There is a method known by the name mainloop() is used when


you are ready for the application to run. mainloop() is an infinite loop used
to run the application, wait for an event to occur and process the event till
the window is not closed.

m.mainloop()

4.1.1.2.2 Methods in tkinter

tkinter also offers access to the geometric configuration of the widgets which can
organize the widgets in the parent windows. There are mainly three geometry
manager classes class.
1. pack() method: It organizes the widgets in blocks before placing in the
parent widget.
2. grid() method: It organizes the widgets in grid (table-like structure) before
placing in the parent widget.
3. place() method: It organizes the widgets by placing them on specific
positions directed by the programmer.

4.1.1.2.3 Widgets in tkinter


There are a number of widgets which you can put in your tkinter application.
Some of the major widgets are explained below:

Button: To add a button in your application, this widget is used. The general
syntax is:
w=Button(master, option=value)

Canvas: It is used to draw pictures and other complex layout like graphics, text
and widgets. The general syntax is:
w=Canvas(master, option=value)

20
SGPA CALCULATOR USING PYTHON

CheckButton: To select any number of options by displaying a number of


options to a user as toggle buttons. The general syntax is:
w=CheckButton(master, option=value)

Entry: It is used to input the single line text entry from the user. For multi-line
text input, Text widget is used. The general syntax is:
w=Entry(master, option=value)

Frame: It acts as a container to hold the widgets. It is used for grouping and
organizing the widgets. The general syntax is:
w=Frame(master, option=value)

Label: It refers to the display box where you can put any text or image which can
be updated any time as per the code. The general syntax is:
w=Label(master, option=value)

Listbox: It offers a list to the user from which the user can accept any number of
options. The general syntax is:
w=Listbox(master, option=value)

MenuButton: It is a part of top-down menu which stays on the window all the
time. Every menuButton has its own functionality. The general syntax is:
w=MenuButton(master, option=value)

Menu: It is used to create all kinds of menus used by the application.


The general syntax is:
w=Menu(master, option=value)

Message: It refers to the multi-line and non-editable text. It works same as that of
Label. The general syntax is:
w=Message(master, option=value)

RadioButton: It is used to offer multi-choice option to the user. It offers several


options to the user and the user has to choose one option. The general syntax is:
w=RadioButton(master, option=value)

21
SGPA CALCULATOR USING PYTHON

Scale: It is used to provide a graphical slider that allows to select any value from
that scale. The general syntax is:
w=Scale(master, option=value)

Scrollbar: It refers to the slide controller which will be used to implement listed
widgets. The general syntax is:
w=Scrollbar(master, option=value)

Text: To edit a multi-line text and format the way it has to be displayed. The
general syntax is:
w=Text(master, option=value)

TopLevel: This widget is directly controlled by the window manager. It don’t


need any parent window to work on. The general syntax is:
w=TopLevel(master, option=value)

SpinBox: It is an entry of ‘Entry’ widget. Here, value can be input by selecting a


fixed value of numbers. The general syntax is:
w=SpinBox(master, option=value)

PannedWindow: It is a container widget which is used to handle number of panes


arranged in it. The general syntax is:
w=PannedWindow(master, option=value)

4.1.1.3 PyInstaller
The main goal of PyInstaller is to be compatible with 3rd-party packages out-of-the-
box. This means that, with PyInstaller, all the required tricks to make external
packages work are already integrated within PyInstaller itself so that there is no user
intervention required. You’ll never be required to look for tricks in wikis and apply
custom modification to your files or your setup scripts. As an example, libraries like
PyQt, Django or matplotlib are fully supported, without having to handle plugins or
external data files manually. Check our compatibility list of Supported Packages for
details.

22
SGPA CALCULATOR USING PYTHON

4.1.1.3.1 Requirements
PyInstaller runs in Windows XP or newer. It can create graphical windowed apps
(apps that do not need a command window). PyInstaller requires two Python
modules in a Windows system. It requires either the PyWin32 or pypiwin32
Python extension for Windows. If you install PyInstaller using pip, and PyWin32
is not already installed, pypiwin32 is automatically installed. PyInstaller also
requires the pefile package. The pip-Win package is recommended, but not
required.

4.1.1.3.2 Installation
PyInstaller is a normal Python package. You can download the archive from PyPi,
but it is easier to install using pip where is is available, for example:
pip install pyinstaller
Or upgrade to a newer version:
pip install –upgrade pyinstaller
To install the current development version:
pip install https://github.com/pyinstaller/pyinstaller/tarball/develop

For Windows, PyWin32 or the more recent pypiwin32, is a prerequisite. The latter
is installed automatically when you install PyInstaller using pip or easy_install. If
necessary, follow the pypiwin32 link to install it manually. It is particularly easy
to use pip-Win to install PyInstaller along with the correct version of PyWin32.
pip-Win also provides virtualenv, which makes it simple to maintain multiple
different Python interpreters and install packages such as PyInstaller in each of
them.
 Once it is installed, to use PyInstaller,
 Start pip-Win
 In the Command field enter venv pyi-env-name. Click Run
 Then you have a command shell window in which commands such as
pyinstaller execute in that Python environment.

4.1.2 Project Scheduling using various tools


Project scheduling is a mechanism to communicate what tasks need to get done and which
organizational resources will be allocated to complete those tasks in what timeframe. A

23
SGPA CALCULATOR USING PYTHON

project schedule is a document collecting all the work needed to deliver the project on
time.

The project has been scheduled as per the following steps:

 Basic calculator on Command Line Interface (CLI).


 Testing on real Data.
 Building Graphical User Interface.
 Checking errors and fixing them.

4.2 Testing
Software Testing is evaluation of the software against requirements gathered from users
and system specifications. Testing is conducted at the phase level in software
development life cycle or at module level in program code. Software testing comprises
of Validation and Verification.

Validation is process of examining whether or not the software satisfies the user
requirements. It is carried out at the end of the SDLC. If the software matches
requirements for which it was made, it is validated.

Verification is the process of confirming if the software is meeting the business


requirements, and is developed adhering to the proper specifications and methodologies.

The most important activity at the implementation stage is the system testing with the
objective of validating the system against the designed criteria. During the development
cycle, user was involved in all the phases that are analysis, design and coding. After each
phase the user was asked whether he was satisfied with the output and the desired
rectification was done at the moment.

The testing phase consists of the following steps:


 Unit Testing
 Integration Testing
 Parallel Testing

4.2.1 Unit Testing


In the bottom of coding technique, each module is tested individually. Firstly, the module
is tested with some test data that covers all the possible paths and then the actual data
was fed to check for results.
24
SGPA CALCULATOR USING PYTHON

4.2.2 Integration Testing


After all the modules are ready and duly tested, these have to be integrated into the
application. This integrated application was again tested first with the test data and then
with the actual data.

4.2.3 Parallel Testing


The third in the series of tests before handling over the system to the user is the parallel
processing of the old and the new system. At this stage, complete and thorough testing is
done and supports out the event that goes wrong. This provides the better practical support
to the persons using the system for the first time who may be uncertain or even nervous
using it.

4.3 Maintenance
The project is highly cost-effective and requires basic knowledge of python to
troubleshoot any forms of discrepancies that may arise in the future. Also, the project is
compatible with the ever-changing nature of the academic curriculum of the students and
does not stand obsolete in case of changes with the course, since the procedure involved
for the calculation of the Semester Grade Point Average remains the same.

25
SGPA CALCULATOR USING PYTHON

Chapter 5
Results and Discussion

5.1 User Interface Representation


User interface modelling is a development technique used by computer application
programmers. Today’s user interfaces (UIs) are complex software components, which
play an essential role in the usability of an application. The development of UI requires
therefore, not only guidelines and best practice reports, but also a development process
including the elaboration of visual models and a standardized notation for this
visualization.

The interface design is kept simple for its use in the Examination Department in order
to suit the daily use routines. The Colors applied are subtle and professional, and are of
Universal Acceptance so that the colors emphasize on what kind of action should be
performed by the user.

5.2 Results
The resultant Project meets all the requirements of the SGPA Calculation process in order
to replace the traditional Excel spreadsheets.

5.2.1 Snapshots
The snapshots of the project that depict its successful functioning are shown below:

5.2.1.1 Snapshots for normal Test Case


The main interface includes two input boxes that take as input the number of Theory
subjects as well as the number of Practical subjects. The third option is a Radio button
that decides the type of semester for which the Semester Grade Point Average is to
be evaluated.

26
SGPA CALCULATOR USING PYTHON

Figure 5.1 Main interface of the SGPA Calculator

On entering the data in the input boxes, the Application looks as follows:

Figure 5.2 Snapshot of the main interface on entering the details

After clicking the submit button, the following interface arises:

Figure 5.3 Snapshot of the Interface followed by the main interface

The subject wise marks and credits can be entered here. The process has been
performed on a test data and the snapshot has been captured.

27
SGPA CALCULATOR USING PYTHON

Figure 5.4 Snapshot of the entered test data

On hitting the Submit button, the SGPA is obtained at the output as follows.

Figure 5.5 Snapshot of SGPA output

Clicking the OK button navigates back to the main interface.

5.2.1.2 Snapshots for Test Case with backlogs


The SGPA Calculator works even for students with backlogs. For example:

Figure 5.6 Snapshot of main interface for student with backlog

28
SGPA CALCULATOR USING PYTHON

Entering the test sample of marks, the snapshot is captured as follows:

Figure 5.7 Snapshot of marks for test case with backlog

On clicking the Submit button, the output SGPA is as shown.

Figure 5.8 Snapshot of SGPA output

Hence, the SGPA Calculator works in wide range of constraints in order to give a
better insight of the academic performance of students with or without backlog.

29
SGPA CALCULATOR USING PYTHON

Chapter 6
Conclusion, Summary and Future Scope

6.1 Conclusion

The Choice Based Credit System (CBCS) enables a student to obtain a degree by
accumulating required number of credits prescribed for that degree. The student also has
choice in selecting courses out of those offered by various departments. The grade points
earned for each course reflects the student's proficiency in that course. The CBCS enables
the students to earn credits across departments and provides flexibility in duration to
complete a Program of study. The CBCS facilitates transfer of credits earned in different
Departments and Centres of other recognized or accredited universities and institutions
of higher education in India and abroad.

Providing Graphical User Interface (GUI) through the SGPA Calculator Project enable
the students and teachers to interact with the application more off-hand from calculating
everything on calculator to just providing marks and their respective credits to application
and let it calculated for you. The biggest benefit of the project lies in the fact that the
students can know their Academic standing irrespective of the fact that whether they
could earn the complete credits for the semester or not.

6.2 Summary

The Examination Departments of the I. K. Gujral Punjab Technical Universities rely upon
the traditional approach for calculating the Semester Grade Point Average of each student
using the Excel spreadsheets that require a large time investment and also crash at times
while handling huge databases as large as that of a college with around 5000 students
currently studying.
The SGPA Calculator built in Python is a step forward towards the use of modern
technology in the Examination Departments of the colleges affiliated to Punjab technical
University and following the Choice Based Credits System religiously.
30
SGPA CALCULATOR USING PYTHON

The Project reduces the need to use a complex interface and eliminates the need to
manually enter complex formulae for each entry of the database.

This project can be easily extended to generate the Detailed Marks certificates (DMCs)
of the students along with the calculation of their Semester Grade Point Average (SGPA).

6.3 Future Scope

The SGPA Calculator Project is modern and can withstand the proposed changes in the
Curriculum in the upcoming years. It is compatible with the future guidelines of UGC.
Yet, many modifications can be made to the project in the following years.
 The project can be extended for use in calculating the Semester Grade Point Average
of all the students in a single go.

 The project can be extended as a Detailed Mark Certificate generator by using other
versatile libraries of python by helping in generating and storing the Detailed Marks
Certificate (DMC) of every student.

 Since, python can easily provide the database compatibility using SQLite, the
project can be used to store the marks of the students and maintaining student
records in the future.

 The project can provide the facility of sending the softcopies of the Detailed Mark
Certificates to the students on their respective e-mail IDs and also provide other
forms of email facilities

 With the project in use, the errors can also be minimised by analysing the working
of the Project and observing the errors closely.

 Since the project is made in Python, by inculcating the values of different Machine
Learning algorithms and analysing years of student data, predictions can be made
regarding the quality of curriculum decided, student results can be predicted and
target-oriented approach can be applied to improve the standards of the institution.

31
SGPA CALCULATOR USING PYTHON

References
 https://docs.python.org/2/library/tkinter.html
 https://en.wikibooks.org/wiki/Introduction_to_Software_Engineering/Architecture/Desi
gn
 https://en.wikipedia.org/wiki/Data_flow_diagram
 https://en.wikipedia.org/wiki/Flowchart
 https://en.wikipedia.org/wiki/Sequence_diagram
 https://en.wikipedia.org/wiki/Systems_design
 https://en.wikipedia.org/wiki/University_Grants_Commission_(India)
 https://en.wikipedia.org/wiki/User_interface_design
 https://en.wikipedia.org/wiki/User_interface_modeling
 https://ifs.host.cs.st-andrews.ac.uk/Resources/Notes/Design/FunctionDesign.pdf
 https://media.readthedocs.org/pdf/pyinstaller/stable/pyinstaller.pdf
 https://medium.com/@mindfiresolutions.usa/advantages-and-disadvantages-of-python-
programming-language-fd0b394f2121
 https://smartbear.com/learn/performance-monitoring/what-is-application-performance-
management/
 https://sswm.info/index.php/humanitarian-crises/urban-settings/planning-process-
tools/implementation-tools/project-implementation
 https://www.evirtualservices.com/technical-feasibility
 https://www.geeksforgeeks.org/python-gui-tkinter/
 https://www.iitms.co.in/blog/how-to-implement-choice-based-credit-system.html
 https://www.javatpoint.com/python-features
 https://www.ptu.ac.in/credit%20based%20system/cbs.pdf
 https://www.pyinstaller.org/
 https://www.python.org/doc
 https://www.pythonforbeginners.com/learn-python/what-is-python/
 https://www.quora.com/What-are-desktop-applications
 https://www.researchgate.net/figure/Login-Flowchart_fig6_313708001
 https://www.scholaro.com/pro/Countries/India/Education-System
 https://www.sketchappsources.com/resources/source-image/python-logo.png
 https://www.tutorialspoint.com/software_engineering/software_testing_overview.htm

32

You might also like