:warning: This project is not maintained anymore :warning:
Recognizing human activities using Deep Learning
View the project notebook here - Link to Jupyter Notebook
There are a total of 599 videos, with each category having 100 videos (with the exception of Handclapping
having 99 videos).
All the videos were captured at 25fps frame rate. Each video has a spatial resolution of 160x120 pixels.
Clone the repository and navigate to the downloaded folder.
git clone https://github.com/MrinalJain17/Human-Activity-Recognition.git
cd Human-Activity-Recognition
Unzip the compressed data files and store in the format as mentioned here
download_files()
present in data_utils.py
as follows to do this in your current working directory automatically. (The function will delete the compressed files after they are successfully extracted) import data_utils
data_utils.download_files()
The following file is corrupted which gives an error when being loaded. Delete it before proceeding.
'person01_boxing_d4_uncomp.avi'
(present in Data/Boxing/
)
In order to read the videos, there is a helper class Videos
in utils.py
.
import numpy as np
from utils import Videos
reader = Videos(target_size=(128, 128),
to_gray=True,
max_frames=40,
extract_frames='first',
required_fps=5,
normalize_pixels=(-1, 1))
videos = reader.read_videos(video_absolute_paths)
Refer the code for a detailed documentation.
This utility is being maintained in a seperate repository here
Run the following command to view the project notebook:
jupyter notebook human_activity_recognition.ipynb
Python 3.x
(preferably from the Anaconda Distribution)
Install FFmpeg
on your machine
For Linux:
$ sudo apt-get update
$ sudo apt-get install libav-tools
For Windows or MAC/OSX:
Download the required binaries from here. Extract the zip file and add the location of binaries to the PATH
variable
pip install sk-video
pip install tensorflow
For GPU support or a custom installation, follow the instructions given on the Tensorflow website.
pip install keras
tqdm - Required for displaying the progress bar.
pip install tqdm
These libraries will be required for successful execution of the project files.