# sarinkaavya19-ai/emo-affectnetmodel architecture

> Architecture diagram of the GitHub repository sarinkaavya19-ai/emo-affectnetmodel, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sarinkaavya19-ai/emo-affectnetmodel
- Repository: https://github.com/sarinkaavya19-ai/emo-affectnetmodel

## Overview

This repository appears to center on a webcam-based facial-emotion demo: capture frames, detect/track a face, run emotion inference, and display or record results. The dependency notes document webcam capture, MediaPipe FaceLandmarker, TorchScript inference, overlays, and VideoWriter output; the model and face-task assets are present in the tree. The notebook itself and architecture documents were not sampled, so finer control flow and any additional capabilities cannot be verified. The older pipeline under _unused is excluded.

Main entry points: [`check_backbone_models_by_webcam.output.ipynb`](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb) (Demo workflow), [`models_EmoAffectnet/torchscript_model_0_66_49_wo_gl.pth`](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/models_EmoAffectnet/torchscript_model_0_66_49_wo_gl.pth) (Emotion model), [`models_face/face_landmarker.task`](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/models_face/face_landmarker.task) (Face task model)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_demo["Webcam demo"]
  node_notebook["Demo workflow"]
  node_capture["Frame capture"]
  node_detect["Face landmarks"]
  node_infer["Emotion inference"]
end

subgraph group_models["Model assets"]
  node_weights["Emotion model"]
  node_landmarker["Face task model"]
end

subgraph group_results["Results"]
  node_preview["Annotated preview"]
  node_recording["Recorded video"]
end

node_user(("Operator"))
node_camera(("Webcam"))

node_user -->|"runs"| node_notebook
node_camera -->|"supplies frames"| node_capture
node_notebook -->|"uses"| node_capture
node_notebook -->|"uses"| node_detect
node_notebook -->|"uses"| node_infer
node_notebook -->|"renders"| node_preview
node_notebook -->|"writes"| node_recording
node_detect -->|"loads"| node_landmarker
node_infer -->|"loads"| node_weights

click node_notebook "https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb"
click node_capture "https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb"
click node_detect "https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb"
click node_infer "https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb"
click node_weights "https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/models_EmoAffectnet/torchscript_model_0_66_49_wo_gl.pth"
click node_landmarker "https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/models_face/face_landmarker.task"
click node_preview "https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_notebook,node_capture,node_detect,node_infer toneBlue
class node_weights,node_landmarker toneAmber
class node_preview,node_recording toneMint
class node_user,node_camera toneIndigo
```

## Components

### Webcam demo

- [Demo workflow](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb): `check_backbone_models_by_webcam.output.ipynb`
- [Frame capture](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb): `check_backbone_models_by_webcam.output.ipynb`
- [Face landmarks](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb): `check_backbone_models_by_webcam.output.ipynb`
- [Emotion inference](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb): `check_backbone_models_by_webcam.output.ipynb`

### Model assets

- [Emotion model](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/models_EmoAffectnet/torchscript_model_0_66_49_wo_gl.pth): `models_EmoAffectnet/torchscript_model_0_66_49_wo_gl.pth`
- [Face task model](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/models_face/face_landmarker.task): `models_face/face_landmarker.task`

### Results

- [Annotated preview](https://github.com/sarinkaavya19-ai/emo-affectnetmodel/blob/main/check_backbone_models_by_webcam.output.ipynb): `check_backbone_models_by_webcam.output.ipynb`
- **Recorded video**

### Other components

- **Operator**
- **Webcam**

## Connections

- Operator → Demo workflow: runs
- Webcam → Frame capture: supplies frames
- Demo workflow → Frame capture: uses
- Demo workflow → Face landmarks: uses
- Demo workflow → Emotion inference: uses
- Demo workflow → Annotated preview: renders
- Demo workflow → Recorded video: writes
- Face landmarks → Face task model: loads
- Emotion inference → Emotion model: loads
