# quocanwyf/doantotnghiep2nguoi architecture

> Architecture diagram of the GitHub repository quocanwyf/doantotnghiep2nguoi, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/quocanwyf/doantotnghiep2nguoi
- Repository: https://github.com/quocanwyf/doantotnghiep2nguoi

## Overview

This is a research project for measurable face-recognition optimization, with a later mobile deployment goal—not a shipped check-in application. The active workflow runs pinned detection and identity experiments on local datasets/models, then produces aggregate evaluations and diagnostic analyses. Documentation also covers problem framing, survey, optimization, evaluation, mobile integration, and reporting; those planned areas are shown without asserting an implemented runtime pipeline. Edges reflect excerpted imports or explicit README statements; unsampled subsystems are represented only where their paths are supported.

Main entry points: [`scripts/t011_widerface_predict.py`](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_widerface_predict.py) (WIDER prediction), [`scripts/t011_xqlfw_baseline.py`](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_baseline.py) (XQLFW baseline), [`scripts/t011_xqlfw_r50_comparison.py`](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_r50_comparison.py) (MBF/R50 comparison), [`scripts/t012_xqlfw_four_combinations.py`](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_xqlfw_four_combinations.py) (Component combinations)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_research["Research framing"]
  node_problem["Problem definition"]
  node_survey["Technical survey"]
end

subgraph group_baseline["Baseline experiments"]
  node_widerface_predict["WIDER prediction"]
  node_widerface_eval["WIDER evaluation"]
  node_xqlfw_baseline["XQLFW baseline"]
  node_identity_split["Identity split audit"]
  node_r50_compare["MBF/R50 comparison"]
  node_reference_detection["Reference detection"]
  node_reference_encoder["Encoder timing"]
end

subgraph group_analysis["Diagnostics and comparison"]
  node_coverage["Detector coverage"]
  node_error_slices["WIDER error slices"]
  node_one_multi["One/multiple faces"]
  node_ltft_proxy["LTFT box proxy"]
  node_ltft_diagnostics["LTFT path diagnostics"]
  node_ltft_faceflag["LTFT face-flag audit"]
  node_ltft_overlap["LTFT overlap gate"]
  node_interface["Detector/encoder interface"]
  node_four_combinations["Component combinations"]
  node_conditional["Conditional embedding"]
end

subgraph group_future["Later project stages"]
  node_optimization["Optimization research"]
  node_evaluation["Evaluation plan"]
  node_mobile["Mobile integration"]
  node_report["Final report"]
end

node_researcher(("Research team"))
node_local_data[("Local datasets")]
node_local_artifacts[("Local results")]

node_researcher -->|"frames problem"| node_problem
node_researcher -->|"surveys methods"| node_survey
node_researcher -->|"runs experiments"| node_widerface_predict
node_researcher -->|"runs experiments"| node_xqlfw_baseline
node_widerface_predict -->|"loads evaluator helpers"| node_widerface_eval
node_reference_detection -->|"reuses predictor"| node_widerface_predict
node_coverage -->|"reuses baseline helpers"| node_xqlfw_baseline
node_r50_compare -->|"reuses baseline helpers"| node_xqlfw_baseline
node_r50_compare -->|"imports split audit"| node_identity_split
node_reference_encoder -->|"reuses baseline helpers"| node_xqlfw_baseline
node_reference_encoder -->|"reuses encoder evaluation"| node_r50_compare
node_error_slices -->|"reuses evaluation rules"| node_widerface_eval
node_error_slices -->|"reads prediction protocol"| node_widerface_predict
node_one_multi -->|"reuses evaluation"| node_widerface_eval
node_one_multi -->|"reads predictions"| node_widerface_predict
node_one_multi -->|"imports analysis definitions"| node_error_slices
node_ltft_diagnostics -->|"reuses proxy code"| node_ltft_proxy
node_ltft_faceflag -->|"reuses proxy code"| node_ltft_proxy
node_ltft_overlap -->|"reuses proxy code"| node_ltft_proxy
node_interface -->|"reuses detector adapter"| node_widerface_predict
node_interface -->|"reuses baseline helpers"| node_xqlfw_baseline
node_interface -->|"reuses comparison helpers"| node_r50_compare
node_four_combinations -->|"reuses detector adapter"| node_widerface_predict
node_four_combinations -->|"reuses baseline helpers"| node_xqlfw_baseline
node_four_combinations -->|"reuses comparison helpers"| node_r50_compare
node_four_combinations -->|"reuses interface helpers"| node_interface
node_conditional -->|"reuses baseline helpers"| node_xqlfw_baseline
node_conditional -->|"reuses comparison helpers"| node_r50_compare
node_local_data -->|"supplies images"| node_widerface_predict
node_local_data -->|"supplies inputs"| node_xqlfw_baseline
node_widerface_predict -->|"writes predictions"| node_local_artifacts
node_widerface_eval -->|"writes metrics"| node_local_artifacts
node_xqlfw_baseline -->|"writes summary"| node_local_artifacts
node_researcher -->|"develops optimization"| node_optimization
node_researcher -->|"plans evaluation"| node_evaluation
node_researcher -->|"targets mobile"| node_mobile
node_researcher -->|"prepares report"| node_report

click node_problem "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/01-problem"
click node_survey "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/02-survey"
click node_widerface_predict "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_widerface_predict.py"
click node_widerface_eval "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_widerface_evaluate.py"
click node_xqlfw_baseline "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_baseline.py"
click node_identity_split "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_identity_split_audit.py"
click node_r50_compare "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_r50_comparison.py"
click node_reference_detection "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_m1_reference_detection.py"
click node_coverage "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_coverage.py"
click node_reference_encoder "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_m2_reference_encoder.py"
click node_error_slices "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_widerface_error_slices.py"
click node_one_multi "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_widerface_one_multi.py"
click node_ltft_proxy "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_box_proxy.py"
click node_ltft_diagnostics "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_box_path_diagnostics.py"
click node_ltft_faceflag "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_faceflag_audit.py"
click node_ltft_overlap "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_overlap_gate.py"
click node_interface "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_xqlfw_detector_encoder_interface.py"
click node_four_combinations "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_xqlfw_four_combinations.py"
click node_conditional "https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_xqlfw_conditional_embedding.py"
click node_optimization "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/04-optimization"
click node_evaluation "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/05-evaluation"
click node_mobile "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/06-mobile"
click node_report "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/07-report"
click node_local_data "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/data"
click node_local_artifacts "https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/artifacts"

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_problem,node_survey toneBlue
class node_widerface_predict,node_widerface_eval,node_xqlfw_baseline,node_identity_split,node_r50_compare,node_reference_detection,node_reference_encoder,node_local_data,node_local_artifacts toneAmber
class node_coverage,node_error_slices,node_one_multi,node_ltft_proxy,node_ltft_diagnostics,node_ltft_faceflag,node_ltft_overlap,node_interface,node_four_combinations,node_conditional toneMint
class node_optimization,node_evaluation,node_mobile,node_report toneRose
class node_researcher toneIndigo
```

## Components

### Research framing

- [Problem definition](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/01-problem): `docs/01-problem`
- [Technical survey](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/02-survey): `docs/02-survey`

### Baseline experiments

- [WIDER prediction](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_widerface_predict.py): `scripts/t011_widerface_predict.py`
- [WIDER evaluation](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_widerface_evaluate.py): `scripts/t011_widerface_evaluate.py`
- [XQLFW baseline](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_baseline.py): `scripts/t011_xqlfw_baseline.py`
- [Identity split audit](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_identity_split_audit.py): `scripts/t011_xqlfw_identity_split_audit.py`
- [MBF/R50 comparison](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_r50_comparison.py): `scripts/t011_xqlfw_r50_comparison.py`
- [Reference detection](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_m1_reference_detection.py): `scripts/t011_m1_reference_detection.py`
- [Encoder timing](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_m2_reference_encoder.py): `scripts/t012_m2_reference_encoder.py`

### Diagnostics and comparison

- [Detector coverage](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t011_xqlfw_coverage.py): `scripts/t011_xqlfw_coverage.py`
- [WIDER error slices](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_widerface_error_slices.py): `scripts/t012_widerface_error_slices.py`
- [One/multiple faces](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_widerface_one_multi.py): `scripts/t012_widerface_one_multi.py`
- [LTFT box proxy](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_box_proxy.py): `scripts/t012_ltft_box_proxy.py`
- [LTFT path diagnostics](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_box_path_diagnostics.py): `scripts/t012_ltft_box_path_diagnostics.py`
- [LTFT face-flag audit](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_faceflag_audit.py): `scripts/t012_ltft_faceflag_audit.py`
- [LTFT overlap gate](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_ltft_overlap_gate.py): `scripts/t012_ltft_overlap_gate.py`
- [Detector/encoder interface](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_xqlfw_detector_encoder_interface.py): `scripts/t012_xqlfw_detector_encoder_interface.py`
- [Component combinations](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_xqlfw_four_combinations.py): `scripts/t012_xqlfw_four_combinations.py`
- [Conditional embedding](https://github.com/quocanwyf/doantotnghiep2nguoi/blob/main/scripts/t012_xqlfw_conditional_embedding.py): `scripts/t012_xqlfw_conditional_embedding.py`

### Later project stages

- [Optimization research](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/04-optimization): `docs/04-optimization`
- [Evaluation plan](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/05-evaluation): `docs/05-evaluation`
- [Mobile integration](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/06-mobile): `docs/06-mobile`
- [Final report](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/docs/07-report): `docs/07-report`

### Other components

- **Research team**
- [Local datasets](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/data): `data`
- [Local results](https://github.com/quocanwyf/doantotnghiep2nguoi/tree/main/artifacts): `artifacts`

## Connections

- Research team → Problem definition: frames problem (evidence: `README.md`)
- Research team → Technical survey: surveys methods (evidence: `README.md`)
- Research team → WIDER prediction: runs experiments (evidence: `scripts/t011_widerface_predict.py`)
- Research team → XQLFW baseline: runs experiments (evidence: `scripts/t011_xqlfw_baseline.py`)
- WIDER prediction → WIDER evaluation: loads evaluator helpers (evidence: `scripts/t011_widerface_predict.py`)
- Reference detection → WIDER prediction: reuses predictor (evidence: `scripts/t011_m1_reference_detection.py`)
- Detector coverage → XQLFW baseline: reuses baseline helpers (evidence: `scripts/t011_xqlfw_coverage.py`)
- MBF/R50 comparison → XQLFW baseline: reuses baseline helpers (evidence: `scripts/t011_xqlfw_r50_comparison.py`)
- MBF/R50 comparison → Identity split audit: imports split audit (evidence: `scripts/t011_xqlfw_r50_comparison.py`)
- Encoder timing → XQLFW baseline: reuses baseline helpers (evidence: `scripts/t012_m2_reference_encoder.py`)
- Encoder timing → MBF/R50 comparison: reuses encoder evaluation (evidence: `scripts/t012_m2_reference_encoder.py`)
- WIDER error slices → WIDER evaluation: reuses evaluation rules (evidence: `scripts/t012_widerface_error_slices.py`)
- WIDER error slices → WIDER prediction: reads prediction protocol (evidence: `scripts/t012_widerface_error_slices.py`)
- One/multiple faces → WIDER evaluation: reuses evaluation (evidence: `scripts/t012_widerface_one_multi.py`)
- One/multiple faces → WIDER prediction: reads predictions (evidence: `scripts/t012_widerface_one_multi.py`)
- One/multiple faces → WIDER error slices: imports analysis definitions (evidence: `scripts/t012_widerface_one_multi.py`)
- LTFT path diagnostics → LTFT box proxy: reuses proxy code (evidence: `scripts/t012_ltft_box_path_diagnostics.py`)
- LTFT face-flag audit → LTFT box proxy: reuses proxy code (evidence: `scripts/t012_ltft_faceflag_audit.py`)
- LTFT overlap gate → LTFT box proxy: reuses proxy code (evidence: `scripts/t012_ltft_overlap_gate.py`)
- Detector/encoder interface → WIDER prediction: reuses detector adapter (evidence: `scripts/t012_xqlfw_detector_encoder_interface.py`)
- Detector/encoder interface → XQLFW baseline: reuses baseline helpers (evidence: `scripts/t012_xqlfw_detector_encoder_interface.py`)
- Detector/encoder interface → MBF/R50 comparison: reuses comparison helpers (evidence: `scripts/t012_xqlfw_detector_encoder_interface.py`)
- Component combinations → WIDER prediction: reuses detector adapter (evidence: `scripts/t012_xqlfw_four_combinations.py`)
- Component combinations → XQLFW baseline: reuses baseline helpers (evidence: `scripts/t012_xqlfw_four_combinations.py`)
- Component combinations → MBF/R50 comparison: reuses comparison helpers (evidence: `scripts/t012_xqlfw_four_combinations.py`)
- Component combinations → Detector/encoder interface: reuses interface helpers (evidence: `scripts/t012_xqlfw_four_combinations.py`)
- Conditional embedding → XQLFW baseline: reuses baseline helpers (evidence: `scripts/t012_xqlfw_conditional_embedding.py`)
- Conditional embedding → MBF/R50 comparison: reuses comparison helpers (evidence: `scripts/t012_xqlfw_conditional_embedding.py`)
- Local datasets → WIDER prediction: supplies images (evidence: `scripts/t011_widerface_predict.py`)
- Local datasets → XQLFW baseline: supplies inputs (evidence: `scripts/t011_xqlfw_baseline.py`)
- WIDER prediction → Local results: writes predictions (evidence: `scripts/t011_widerface_predict.py`)
- WIDER evaluation → Local results: writes metrics (evidence: `scripts/t011_widerface_evaluate.py`)
- XQLFW baseline → Local results: writes summary (evidence: `scripts/t011_xqlfw_baseline.py`)
- Research team → Optimization research: develops optimization (evidence: `README.md`)
- Research team → Evaluation plan: plans evaluation (evidence: `README.md`)
- Research team → Mobile integration: targets mobile (evidence: `README.md`)
- Research team → Final report: prepares report (evidence: `README.md`)
