https://github.com/shervinnd/titanic-survival-predictor
π’ Dive into the Titanic dataset with this ML project! Using TensorFlow, predict passenger survival via neural networks. Features data preprocessing, model training, and visualization with pandas, scikit-learn, and matplotlib. Perfect for beginners in deep learning. ππ»
https://github.com/shervinnd/titanic-survival-predictor
classification data-preprocessing data-science data-visualization deep-learning jupyter-notebook machine-learning neural-network pandas predictive-modeling python scikit-learn tensorflow titanic-dataset
Last synced: 27 days ago
JSON representation
π’ Dive into the Titanic dataset with this ML project! Using TensorFlow, predict passenger survival via neural networks. Features data preprocessing, model training, and visualization with pandas, scikit-learn, and matplotlib. Perfect for beginners in deep learning. ππ»
- Host: GitHub
- URL: https://github.com/shervinnd/titanic-survival-predictor
- Owner: shervinnd
- License: mit
- Created: 2025-09-09T08:45:46.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2025-09-09T09:19:03.000Z (about 1 month ago)
- Last Synced: 2025-09-09T11:13:15.030Z (about 1 month ago)
- Topics: classification, data-preprocessing, data-science, data-visualization, deep-learning, jupyter-notebook, machine-learning, neural-network, pandas, predictive-modeling, python, scikit-learn, tensorflow, titanic-dataset
- Language: Jupyter Notebook
- Homepage:
- Size: 176 KB
- Stars: 2
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Titanic Survival Predictor π’π₯



Welcome to the **Titanic Survival Predictor** project! π This Jupyter
Notebook-based machine learning model dives into the historic Titanic
dataset to predict passenger survival using neural networks. Whether
you're a data science newbie or a seasoned sailor in ML waters, this
project is your ticket to exploring predictive modeling with a dash of
history! π## Overview π
The Titanic disaster of 1912 is one of history's most infamous events.
In this project, we use the famous Titanic dataset to build a deep
learning model that predicts whether a passenger survived based on
features like age, sex, class, and more.- **Goal**: Predict survival (0 = Did not survive π’, 1 = Survived π)
using a neural network built with TensorFlow/Keras.
- **Dataset**: Sourced from Kaggle's Titanic challenge (via GitHub raw
URL).
- **Tech Stack**: Python, Pandas, NumPy, Matplotlib, Scikit-learn,
TensorFlow.
- **Why Fun?**: It's a classic ML problem with real-world data
insights -- who survived and why? π## Features β¨
- **Data Loading & Exploration**: Load the Titanic dataset and peek
into its structure π.
- **Preprocessing**: Handle missing values, encode categorical
variables (e.g., Sex, Embarked), and scale features for optimal
model performance π.
- **Neural Network Model**: Build and train a TensorFlow/Keras model
to predict survival π§ .
- **Visualization**: Plot key insights using Matplotlib to understand
data distributions π.
- **Scalable Workflow**: Easily adaptable for further experimentation
or hyperparameter tuning βοΈ.## Getting Started π
### Prerequisites
To run this project, you'll need:
- Python 3.12+ π
- Jupyter Notebook π
- Libraries: Install via `pip install -r requirements.txt` or
manually:
- `pandas`
- `numpy`
- `matplotlib`
- `scikit-learn`
- `tensorflow`### Installation
1. Clone this repository:
``` bash
git clone https://github.com/shervinnd/titanic-survival-predictor.git
```2. Navigate to the project directory:
``` bash
cd titanic-survival-predictor
```3. Install dependencies:
``` bash
pip install -r requirements.txt
```4. Launch Jupyter Notebook:
``` bash
jupyter notebook Titanic.ipynb
```### Dataset
The dataset is sourced directly from:
https://raw.githubusercontent.com/datasciencedojo/datasets/master/titanic.csv
It includes features like:
- `PassengerId`, `Survived`, `Pclass`, `Sex`, `Age`, `SibSp`, `Parch`,
`Fare`, `Embarked`
- Preprocessing steps handle missing values (`Age`, `Embarked`) and
drop irrelevant columns (`Name`, `Ticket`, `Cabin`).## Usage π οΈ
1. Open `Titanic.ipynb` in Jupyter Notebook.
2. Run the cells sequentially to:
- Load and preprocess the data π§Ή.
- Build and train the neural network π§ .
- Evaluate model performance π.
3. Experiment with hyperparameters or feature engineering to improve
accuracy π§.## Project Structure π
- `Titanic.ipynb`: Main Jupyter Notebook with data processing, model
training, and evaluation.
- `README.md`: This file, your guide to the project! π
- `requirements.txt`: List of required Python libraries.## Future Improvements π
- Add feature engineering (e.g., family size, title extraction) π οΈ.
- Experiment with other models (e.g., Random Forest, XGBoost) π³.
- Implement cross-validation for robust evaluation β .
- Visualize predictions with confusion matrices or ROC curves π.## License π
This project is licensed under the MIT License. See the LICENSE file for
details.## Acknowledgments π
- Kaggle for providing the Titanic dataset.
- TensorFlow and Scikit-learn communities for awesome tools.
- The data science community for endless inspiration! π*Powered by Miracleβ‘*