KarimSayed commited on
Commit
435971c
·
verified ·
1 Parent(s): e5a54f1

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +46 -0
README.md ADDED
@@ -0,0 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - tensorflow
4
+ - efficientnetv2
5
+ - transfer-learning
6
+ license: mit
7
+ ---
8
+
9
+ # Cat Breed Classification Model
10
+
11
+ ## Model Description
12
+ This model leverages **transfer learning** with the **EfficientNetV2-L** architecture as the backbone to classify images of **five different cat breeds**. The model is fine-tuned to identify distinct types of cats based on image features, and the later layers of the EfficientNetV2-L backbone are exposed and used to create embeddings.
13
+
14
+ The model is trained to classify the following five cat breeds:
15
+ - Domestic Short-Hair
16
+ - Siamese
17
+ - Maine Coon
18
+ - Bengal
19
+ - Ragdoll
20
+
21
+ EfficientNetV2-L is a state-of-the-art image classification model that provides a good balance of speed and accuracy while achieving high performance on image recognition tasks.
22
+
23
+ ## Intended Use
24
+ This model is designed for the creation of embeddings of cat breeds in images.
25
+
26
+ ## How to Use
27
+ You can easily load this model and use it to classify cat images with the following code snippet:
28
+
29
+ ```python
30
+ import tensorflow as tf
31
+ from tensorflow.keras.models import load_model
32
+ import numpy as np
33
+ from tensorflow.keras.preprocessing import image
34
+
35
+ # Load the pre-trained model
36
+ model = tf.keras.models.load_model("path_to_model")
37
+
38
+ # Example image preprocessing
39
+ img_path = "path_to_image.jpg"
40
+ img = image.load_img(img_path, target_size=(128, 128)) # Resize to 128x128
41
+ img_array = image.img_to_array(img)
42
+ img_array = np.expand_dims(img_array, axis=0) # Add batch dimension
43
+ img_array /= 255.0 # Normalize to [0, 1]
44
+
45
+ # Predict the cat breed
46
+ predictions = model.predict(img_array)