0% found this document useful (0 votes)
10 views16 pages

USER MANUAL 37

Uploaded by

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

USER MANUAL 37

Uploaded by

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

9.

USER MANUAL
8.1 Introduction to the User Manual

This manual is designed to guide you through the setup and use of the system.
The system automates attendance marking using face recognition technology,
ensuring accurate and efficient record-keeping.

By following this guide, you will learn how to install the system, register users,
manage profiles, and utilize the face recognition and reporting features
effectively.

8.2 Installation Instructions

Prerequisites:

1. Operating System: Windows

2. Python Version: Python 3.8 or above

3. Dependencies: Ensure you have the following Python libraries installed:

▪ tkinter

▪ OpenCV

▪ numpy

▪ pandas

▪ PIL (Pillow)

▪ pyttsx3

▪ Additional project-specific libraries

Steps to Install:

1. Clone the Project Files:

37
▪ Clone the project files in your system from the repository or a
provided source.

▪ Extract the files to a folder (e.g., D:\AMS).

Install Required Libraries:

1. Open a command prompt/terminal.

2. Navigate to the project directory and run: pip install -r


requirements.txt

Set Up Directories:

1. Ensure the following directories exist in the project folder:

• TrainingImage: Stores student face images.

• TrainingImageLabel: Stores trained model data.

• StudentDetails: Contains student information in a CSV file.

• Attendance: Stores attendance records.

Verify Configuration Files:

1. Check and configure file paths in the Python files as required (e.g.,
paths to Haarcascade XML and image directories).

Run the Application:

1. Launch the system by running attendance.py: python attendance.py

8.3 User Registration and Profile Management

Registering a New User:

38
1. Launch the System: Open the application interface.

2. Access the Registration Feature: Click on the "Register Student" button.

3. Enter User Details: Input the following details:

• Enrollment Number

• Name

4. Capture Face Images: The system will open the webcam. Position the user
in front of the camera, and click "Take Image".

5. Train the System: After capturing images, click "Train Image" to update the
face recognition model.

Managing Profiles:

1. To update user details, edit the studentdetails.csv file manually or


integrate an additional update feature.

8.4 Using the Face Recognition Feature

Marking Attendance:

1. Launch the Application: Start the system and click on the "Mark
Attendance" button.

2. Real-Time Recognition: The system will activate the webcam to


recognize faces. Ensure students are in front of the camera one at a
time.

3. Attendance Logging: The system will automatically match the


recognized faces with the database and log attendance into the
relevant file.

39
4. Handle Unregistered Users: For unregistered faces, ensure the student
is registered using the "Register Student" feature.

8.5 Viewing Attendance Reports

Access Attendance Data:

1. Click on "View Attendance": Navigate to the main menu and select


"View Attendance".

2. Select the Date or Student: Use filters to view attendance for a specific
date or a particular student.

3. Export Reports: Export the attendance data as a CSV or Excel file for
further use (if applicable).

4. Manual Updates: Use the "Mark Attendance Manually" feature to


correct or add attendance data in case of discrepancies.

40
10. SOURCE CODE & SYSTEM SNAPSHOTS

10.1 Source Code:

Code Structure Overview:

The project is organized into multiple Python files, each handling a specific
functionality. Below is the modular structure:

1. attendance.py

• Purpose: Handles the core logic for managing and recording


attendance.

• Key Functions:

▪ Save attendance records into a CSV file.

▪ Display attendance logs for review.

2. automaticAttendance.py

• Purpose: Automates the process of marking attendance using face


recognition.

• Key Functions:

▪ Real-time face detection using Haar cascades.

▪ Compare detected faces with trained data for attendance


marking.

3. show_attendance.py

• Purpose: Displays attendance reports.

• Key Functions:

▪ Fetch records from the CSV file.


41
▪ Filter attendance by student, date, or subject.

4. takeImage.py

• Purpose: Captures images for new student registration.

• Key Functions:

▪ Use the webcam to capture multiple face images.

▪ Save images in a structured format for training.

5. trainImage.py

• Purpose: Trains the face recognition model using captured student


images.

• Key Functions:

▪ Generate training data using OpenCV’s


cv2.face.LBPHFaceRecognizer module.

▪ Save the trained model for recognition tasks.

6. takemanually.py

• Purpose: Allows manual attendance marking.

• Key Functions:

▪ Open a form or interface to manually input attendance details.

▪ Save changes to the attendance CSV file.

Key Functional Code Snippets:

1. Face Detection Using Haar Cascade (automaticAttendance.py)

42
face_cascade =
cv2.CascadeClassifier('haarcascade_frontalface_default.xml')

gray_frame = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)

faces = face_cascade.detectMultiScale(gray_frame, scaleFactor=1.2,


minNeighbors=5)

for (x, y, w, h) in faces:

cv2.rectangle(frame, (x, y), (x+w, y+h), (255, 0, 0), 2)

2. Capturing Student Images (takeImage.py)

cap = cv2.VideoCapture(0)

count = 0

while True:

ret, frame = cap.read()

if not ret:

break

cv2.imwrite(f"TrainingImage/Student_{student_id}_{count}.jpg",
frame)

count += 1

if count > 50:

break

cap.release()

3. Training the Face Recognition Model (trainImage.py)

43
recognizer = cv2.face.LBPHFaceRecognizer_create()

faces, ids = get_images_and_labels('TrainingImage/')

recognizer.train(faces, np.array(ids))

recognizer.save('TrainingImageLabel/Trainner.yml')

4. Marking Attendance (attendance.py)

with open('Attendance.csv', 'a') as file:

writer = csv.writer(file)

writer.writerow([student_id, student_name, date, time])

5. Displaying Attendance (show_attendance.py)

data = pd.read_csv('Attendance.csv')

filtered_data = data[data['Date'] == selected_date]

print(filtered_data)

6. Error Handling for Missing Inputs (takeImage.py)

if not student_id or not student_name:

print("Error: Enrollment number and name are required!")


err_screen()

44
10.2 System Snapshots:

Front Look

Mark Attendance

45
Register Student Using Their Face

View Attendance

46
Marking Attendance in .csv File

Storing Faces a/c Er.no & Name

Filling Attendance Using Face Recognition

47
11. GANTT CHART & PERT CHART

48
12. CONCLUSION

In conclusion, the Face Recognition Attendance Management System provides


an efficient and accurate way to track attendance. By using facial recognition, the
system reduces errors and saves time compared to traditional methods. It offers
a simple and secure solution for both students and teachers, making the
attendance process faster and easier. While there are some challenges, like
ensuring good lighting and occasional recognition issues, these can be improved
in future versions. Overall, the system shows great potential for use in schools,
colleges, and workplaces, improving attendance management and security.

49
13. REFERENCES, FACE RECOGNITION ATTENDANCE MANAGEMENT SYSTEM

13.1 Books, Articles, and Research Papers

1. Books:

• Deep Learning by Ian Goodfellow, Yoshua Bengio, and Aaron Courville

• Provides a foundational understanding of neural networks and their


application in face recognition.

• Python Machine Learning by Sebastian Raschka and Vahid Mirjalili

• Covers Python libraries and machine learning techniques relevant to


face recognition.

2. Research Papers:

• Viola-Jones Object Detection Framework by Paul Viola and Michael Jones

• The foundation for Haar cascade classifiers used in face detection.

• FaceNet: A Unified Embedding for Face Recognition and Clustering by


Florian Schroff, Dmitry Kalenichenko, and James Philbin

• Discusses state-of-the-art methods in face recognition and clustering.

3. Articles

• "Face Recognition Technology: A Review" (various authors in journals such


as IEEE Access)

• "Applications of Computer Vision in Education" (available on platforms like


Springer or IEEE Xplore).

12.2 Online Resources and Tutorials

1. Python Programming for Face Recognition

50
• Real Python tutorials: realpython.com

• OpenCV documentation: docs.opencv.org

2. Face Recognition and Machine Learning

• TensorFlow tutorials: tensorflow.org

• PyImageSearch: A comprehensive blog on OpenCV and face


recognition: pyimagesearch.com

3. Haar Cascade and Image Processing

• OpenCV Python tutorial on Haar cascades: opencv-python-


tutroals.readthedocs.io

• "Face Recognition Using OpenCV": Available on Medium and other


developer blogs.

4. General Tutorials

• GeeksforGeeks tutorials on OpenCV and Python: geeksforgeeks.org

• YouTube channels like Corey Schafer, Tech With Tim, and Sentdex.

12.3 Software Tools and Libraries Used

1. Libraries and Frameworks

• OpenCV: Used for face detection and recognition.

• Pillow (PIL): For image processing and manipulation.

• NumPy: For numerical computations.

• pandas: To manage CSV files for student data and attendance logs.

• pyttsx3: For text-to-speech notifications.

51
• tkinter: For building the graphical user interface (GUI).

2. Tools and Software

• Python 3.x: The primary programming language used.

• Visual Studio Code: IDE for writing and debugging code.

• Haar Cascade Classifier: Pre-trained model for face detection.

• OS Module: For file handling and directory management.

3. Pre-Trained Models

• Haar Cascade XML Files: Provided by OpenCV for detecting faces in


images.

4. Data Formats and Storage

• CSV files for student details and attendance records.

5. YouTube

52

You might also like