MoodZik is a web app that utilizes Machine Learning to analyze a user's face through the webcam, identify their current emotions, and generate music from scratch based on how they are feeling.
The technologies / libraries used in this project are:
- Tensorflow & Keras
- Convolutional Neural Networks (Face / Emotion detection)
- Recurrent Neural Networks (Music generation)
- Pandas
- OpenCV
- NumPy
- Flask
Moodzik builds fine on Ubuntu 20.04.1
using Python 3.8.5
git clone https://github.com/Belhoussine/Moodzik.git
./Moodzik/setup
cd ./Moodzik/WebApp/
python3 app.py
firefox http://127.0.0.1:5000/
- Get input from camera
- Use Haar_Cascade model
- Capture face:
- Capture frame
- Crop frame to identify face only
- Process captured face
- Feed to CNN_02
-
Get face image from CNN_01
-
Build CNN_02:
- Design network architecture:
- Convolution layers.
- Fully connected Neural Network.
- Define activation functions.
- Define output labels.
- Define optimizer / loss function.
- Design network architecture:
-
Train CNN_02:
- Dataset:
- Pre-processing:
- Normalize data
- Image processing:
- Convert to grayscale
- Pre-processing:
- Train model
- Save model as JSON
- Dataset:
-
Predict mood from image
-
Display mood
- Get mood from CNN_02
- Train Music generator Neural Network:
- Use Magenta
- Use primers to generate music from
- Generate music based on mood:
- Provide mood primers
- Generate MIDI file based on mood
- Use Pygame.mixer on generated midi file
- Desing GUI
- Use flask to serve app
- Host in a remote server
- Purchase domain name
- Deploy