File size: 1,462 Bytes
7187970 59556a3 911883a 7187970 59556a3 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
---
license: mit
language:
- en
pipeline_tag: tabular-classification
library_name: keras
tags:
- tabular-classification
- traffic
- keras
---
# TPnet-small
TPnet-small is a lightweight deep neural network (DNN) designed to predict traffic congestion using tabular smart mobility features. It serves as a compact yet powerful alternative to tree-based models.
## Model Details
- **Model type**: Feedforward Deep Neural Network (3 hidden layers)
- **Architecture**: [128, 64, 32] with ReLU activations and Dropout
- **Output**: 3-class Softmax output (`High`, `Medium`, `Low`)
- **Trained on**: Smart Mobility Traffic Dataset from Kaggle
## Training Details
- Optimizer: Adam
- Loss: Sparse Categorical Crossentropy
- Epochs: 50
- Batch size: 32
- Training time: ~6 seconds on CPU
- Train Accuracy: 99.1%
- Val Accuracy: 94.6%
## Evaluation
| Metric | Value |
|----------|-------|
| Accuracy | 94.5% |
| F1 Score | 0.944 |
| Parameters | 13,123 |
| Model Size | ~156 KB (.h5 format) |
Includes training trajectory and confusion matrix plots.
## How to Use
```python
from tensorflow.keras.models import load_model
model = load_model("traffic_predictor_dnn.h5")
y_pred = model.predict(X_test) # X_test must be scaled [n_samples, 20]
```
## Limitations
- Performance limited by small dataset size and feature coverage
- Currently optimized for CPU inference, not edge deployment
## Authors
- Created by [@Yukin3](https://github.com/Yukin3) |