Me and 2 of my uni colleagues made this project for AI in medicine subject because we thought the given topics were too easy. (It's just a proof of concept version. Maybe someday I'll find some time to improve it)
This project combines hardware and software to create a system that can detect lies by analyzing physiological signals. Here's a quick overview of what this project entails and how everything fits together.
This project develops a lie-detection system using a combination of hardware and software. The system is integrated with an app that displays questions and records the answers.
- Arduino UNO
- Pulse oximeter sensor (Infrared + Red LEDs)
- Galvanic skin resistance sensor
- Desktop Application:
- Collects training data by asking questions and prompting the person whether they have lied.
The sensors are connected to an Arduino UNO, which sends data via a serial connection. The app serves as the project interface, prompting users with questions at 10-second intervals, recording serial data for analysis, and saving answers in separate CSV files.
A specially designed and 3D-printed piece holds a finger using an elastic sleeve, providing a dark backdrop for the LED lights to measure resistance accurately. This setup ensures reliable sensor readings.
- Data collection is done through Arduino via a serial connection using PySide6 for handling data collection.
- Used Python3 with libraries like SciPy, Matplotlib, Pandas, NumPy, and PyKalman for scientific computing.
- Processed the raw GSR and PPG signals to obtain 9-second signals from each question interval, resulting in 90 samples per recording for training.
The CSV data obtained after processing looks like this:
Timestamps,GSR_Data,Red_PPG_Data,IR_PPG_Data,Processed_PPG_Data,SpO2,BPM
2.0,0.916,249217,195520,-81.629503,103.36753940548783,78.94736
2.075,0.937,249303,195525,-117.22019,101.36651055170812,78.94736
- Consists of around 300 questions from 4 difficulty categories.
- Initial training with 91 recordings showed an accuracy of about 73.68%.
- The model's accuracy could be improved by collecting more data and refining the training dataset.
- Occasionally, the pulse oximeter sensor stops working due to cable issues, requiring a reconnection of the Arduino.