Views
No views yet
.h51from tensorflow.keras.models import load_model
2
3# Load the model
4model = load_model("path_to_your_model.h5")
5
6# Example input
7input_data = ... # Replace with your preprocessed input
8output = model.predict(input_data)
9print(output)
10
11
12
13## Training Details
14The model was trained using a Convolutional Neural Network (CNN) architecture on the [Face Shape Classification Dataset](https://www.kaggle.com/datasets/lucifierx/face-shape-classification).
15
16### Preprocessing Steps
17- **Image Size**: All input images were resized to 224x224 pixels.
18- **Normalization**: Pixel values were normalized to the range [0, 1].
19- **Data Augmentation**: Techniques like rotation, flipping, and zooming were applied to improve generalization.
20
21### Training Configuration
22- **Framework**: TensorFlow (Keras)
23- **Optimizer**: Adam
24- **Loss Function**: Categorical Crossentropy
25- **Batch Size**: 32
26- **Epochs**: 50
27- **Validation Accuracy**: Achieved 85% on the validation set.
28
29### Hardware
30The model was trained on an NVIDIA GPU for faster computation.
31
32## Limitations
33- The model may not perform well with low-resolution or occluded images.
34- The dataset may not represent all possible face shapes, which could limit generalization.
35
36## Example Predictions
37Here are some example predictions:
38
39| Input Image | Predicted Class |
40|--------------------|-----------------|
41|  | Oval |
42|  | Square |