Update README.md
Browse files
README.md
CHANGED
|
@@ -31,6 +31,23 @@ This set contains two models trained in the context of a thesis on emotion recog
|
|
| 31 |
|
| 32 |
Both models are in `.h5` format and were developed using TensorFlow and Keras. They have been fine-tuned to capture emotional expressions relevant to educational environments.
|
| 33 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 34 |
This resource has been shared for scientific reproducibility and to support academic and technical analysis.
|
| 35 |
|
| 36 |
## Source Code Repository
|
|
|
|
| 31 |
|
| 32 |
Both models are in `.h5` format and were developed using TensorFlow and Keras. They have been fine-tuned to capture emotional expressions relevant to educational environments.
|
| 33 |
|
| 34 |
+
|
| 35 |
+
**Note on Model Loading**:
|
| 36 |
+
- The **FacialModel** can be loaded using standard Keras methods:
|
| 37 |
+
```python
|
| 38 |
+
model = tf.keras.models.load_model("FacialModel-8177.h5")
|
| 39 |
+
```
|
| 40 |
+
- The **TextModel** uses custom objects (e.g., `TFRobertaModel`). You must specify them when loading the model:
|
| 41 |
+
```python
|
| 42 |
+
from transformers import TFRobertaModel
|
| 43 |
+
from tensorflow.keras.models import load_model
|
| 44 |
+
|
| 45 |
+
def custom_objects_fn_roberta():
|
| 46 |
+
return {'TFRobertaModel': TFRobertaModel}
|
| 47 |
+
|
| 48 |
+
model = load_model("TextModel-0.7836.h5", custom_objects=custom_objects_fn_roberta())
|
| 49 |
+
```
|
| 50 |
+
|
| 51 |
This resource has been shared for scientific reproducibility and to support academic and technical analysis.
|
| 52 |
|
| 53 |
## Source Code Repository
|