Role Breakdown
| Responsibility | Lead |
|---|---|
| Data Collection & Preprocessing | Anupam Patil |
| Text Model Development | Nandini Soni |
| Image Model Development | Anupam Patil |
| Fusion Model & Report | Nandini Soni |
An end-to-end project leveraging movie plots, posters, and metadata to predict movie genres.
Explore our data pipelines, deep learning models, and fusion strategies.
| Responsibility | Lead |
|---|---|
| Data Collection & Preprocessing | Anupam Patil |
| Text Model Development | Nandini Soni |
| Image Model Development | Anupam Patil |
| Fusion Model & Report | Nandini Soni |
We used genre-wise filtering to equalize the number of samples across all 12 selected genres. Undersampled dominant genres to reduce label imbalance. Removing 3625 rows with no genres. Cleaned file saved (23645 rows remain).
Dataset Overview:
| movie_id | title | overview | poster_path | poster_file | genres | title_length | overview_length | num_genre | source_genre | Drama | Comedy | Documentary | Romance | Action | Thriller | Horror | Crime | Music | Animation | TV Movie | Family |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 86497 | Wide Open | A philandering cab driver decides to help his girlfriend's attractive sister, who is in trouble with drug dealers. | /uzIFp9Wu4QPyTJ1eqgkcIVYud7S.jpg | /content/drive/MyDrive/Tmdb_posters_custom/movie_posters/86497.jpg | ['Comedy', 'Drama'] | 9 | 114 | 2 | ['Drama', 'Comedy'] | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 16219 | Gladiator | Tommy Riley has moved with his dad to Chicago from a 'nice place'. He keeps to himself, goes to school... | /w0YjBWVfu689txEXZG3xa4Aev3i.jpg | /content/drive/MyDrive/Tmdb_posters_custom/movie_posters/16219.jpg | ['Drama', 'Action'] | 9 | 236 | 2 | ['Drama', 'Action'] | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 512062 | Vinayapoorvam Vidyadharan | Vidyadharan is a bank employee, who loses his job due to his wife's extravagant lifestyle... | /t4P0xquN818fyhMdsCsGR5BecV5.jpg | /content/drive/MyDrive/Tmdb_posters/movie_posters/512062.jpg | ['Comedy', 'Family', 'Drama'] | 25 | 172 | 3 | ['Drama', 'Comedy', 'Family'] | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 |
| 43089 | Roadgames | A truck driver plays a cat-and-mouse game with a mysterious serial killer in a van... | /zj3eE1lNkp3oWWnOHu4Aj7Gkqj2.jpg | /content/drive/MyDrive/Tmdb_posters_custom/movie_posters/43089.jpg | ['Thriller', 'Mystery', 'Horror'] | 9 | 158 | 2 | ['Thriller', 'Horror'] | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 |
| 270016 | Elvis by the Presleys | Priscilla Presley, her daughter, their family and their friends open their hearts in the backdrop of Graceland... | /rdYML6V994npU7RKcnjijLIJ8Fj.jpg | /content/drive/MyDrive/Tmdb_posters_custom/movie_posters/270016.jpg | ['Music', 'Documentary'] | 21 | 152 | 2 | ['Documentary', 'Music'] | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 |
The NLTK library is used to preprocess movie overviews by tokenizing, removing stopwords, and lemmatizing text to create clean, standardized inputs for the model.
Cleaned and Tokenized Movie Overviews:
word_tokenize.<unk> for unknown tokens.<unk> as needed.
GloVe embeddings are used to provide pre-trained, static word vectors for representing movie overviews as numerical inputs to the LSTM model for genre classification.
nn.Embedding.from_pretrained() used to load embedding matrix.batch_first=True, dropout=0.3 applied inside the LSTM.
bert-base-uncased tokenizer.tokenizer(text, max_length=..., padding='max_length', truncation=True) for uniform shape.MultiLabelBinarizer.nn.Embedding layer initialized randomly.freeze_embedding toggle).x[:, -1, :]), size (batch_size, 64) due to bidirectionality.BCEWithLogitsLoss for multi-label classification.| Parameter | Value |
|---|---|
| Input Sequence Length | 256 tokens |
| Embedding Dimension | 128 |
| LSTM Layers | 2 |
| LSTM Hidden Dimension | 32 (bidirectional → output size 64) |
| Dropout Rate | 0.3 |
| Output Size | 12 |
| Loss Function | BCEWithLogitsLoss (with class weights) |
| Optimizer | Adam |
| Learning Rate | 1e-3 |
| Weight Decay | 1e-5 |
| Batch Size | 32 |
| Epochs | 10 |
| Device | GPU (if available) |
| Parameter | Value |
|---|---|
| Embedding Layer | Frozen(non-trainable) |
| LSTM Hidden Dimension | 256 (bidirectional → output size 512) |
| Dropout Rate | 0.5 |
| Loss Function | BCEWithLogitsLoss |
| Optimizer | AdamW |
| Learning Rate | 1e-4 |
| Weight Decay | 1e-5 |
| LR Scheduler | ReduceLROnPlateau (monitors val F1) |
| Epochs | 40 |
local_poster_path and converted to RGB.MultiLabelBinarizer, producing 12-dimensional multi-hot vectors stored as genre_label.EfficientNet_B3_Weights.IMAGENET1K_V1) with all MBConv + Squeeze-and-Excitation blocks intact, yielding a 1,536-dim feature vector.torch.amp.autocast and GradScaler for faster, memory-efficient CUDA training.BCEWithLogitsLoss with pos_weight = inverse mean frequency per genre.CosineAnnealingLR (T_max = 20 epochs).(batch_size × 12). At inference, apply sigmoid to convert logits to per-genre probabilities.EfficientNet-B0
EfficientNet-B3
Metrics Comparison




This project provided valuable insights into multimodal deep learning,while leveraging transfer learning, particularly in combining diverse data types like textual overviews and poster images. Initially, we assumed both modalities would perform equally well, but we discovered that each excelled in different areas depending on the genre.
We also encountered challenges with skewed data, particularly for underrepresented genres like TV Movie or Music, which were harder to predict due to their low frequency despite one-hot encoding and balanced sampling.
Finally, we learned the importance of preprocessing. Cleaning the dataset, removing failed poster downloads, filtering for usable genres, and properly cleaning and tokenizing overview text were critical to achieving meaningful results. Without these steps, the models would have struggled to learn effectively.
To enhance the model’s performance and applicability, we propose the following improvements:
This project demonstrated the power of multimodal learning when effective fusion techniques are applied. Each modality contributed unique strengths, and the attention-based fusion architecture intelligently leveraged these to improve genre predictions.
With a larger and more balanced dataset, end-to-end fine-tuning, and advanced architectures like BERT, GPT or co-attention-based fusion layers, the model’s performance can be significantly enhanced. For the image stream, exploring sophisticated convolutional architectures such as YOLO, EfficientNet-V2, or DenseNet-201 could capture deeper visual features and stylistic patterns in posters, particularly for diverse or high-resolution datasets.