# yatheendra-source/the-spotters-problem architecture

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

- Interactive diagram: https://gitdiagram.com/yatheendra-source/the-spotters-problem
- Repository: https://github.com/yatheendra-source/the-spotters-problem

## Overview

This repository is a computer-vision assignment organized as four sequential tasks: image filtering and quality metrics, multiscale Waldo detection, feature extraction, and descriptor matching with voting. The main workflow runs the task scripts in order, reusing earlier task code; Task 2 also scores detections against annotations. Task 4’s details are represented from the README only, since its source was not sampled. The README describes image and plot directories that are absent from the provided tree, so those are shown as external inputs and outputs.

Main entry points: [`task2.py`](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task2.py) (Template detection), [`task1.py`](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task1.py) (Filtering and metrics), [`task3.py`](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task3.py) (Orientation descriptors), [`task4.py`](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task4.py) (Descriptor matching and voting)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_image_processing["Image Processing"]
  node_task1["Filtering and metrics<br/>[task1.py]"]
end

subgraph group_waldo_detection["Waldo Detection"]
  node_task2["Template detection<br/>[task2.py]"]
end

subgraph group_feature_extraction["Feature Extraction"]
  node_task3_corners["Harris corners<br/>[task3.py]"]
  node_task3_blobs["DoG keypoints<br/>[task3.py]"]
  node_task3_descriptors["Orientation descriptors<br/>[task3.py]"]
end

subgraph group_feature_matching["Feature Matching"]
  node_task4["Descriptor matching and voting<br/>[task4.py]"]
end

node_user(("Assignment user"))
node_images["Scenes and template"]
node_annotations["Ground-truth annotations"]
node_results["Detection and feature results"]
node_plots["Generated figures"]

node_user -->|"runs first"| node_task1
node_user -->|"runs next"| node_task2
node_user -->|"runs next"| node_task3_corners
node_user -->|"runs last"| node_task4
node_images -.->|"supplies images"| node_task1
node_images -->|"supplies scenes"| node_task2
node_images -->|"supplies template"| node_task3_corners
node_task2 -->|"imports helpers"| node_task1
node_task3_corners -->|"imports helpers"| node_task1
node_task3_blobs -->|"uses peak finding"| node_task2
node_task3_descriptors -->|"uses image operations"| node_task1
node_task2 -->|"scores detections"| node_annotations
node_task3_descriptors -.->|"provides descriptors"| node_task4
node_task2 -->|"produces detections"| node_results
node_task3_descriptors -->|"produces features"| node_results
node_task4 -->|"votes on answer"| node_results
node_task1 -->|"writes figures"| node_plots
node_task2 -->|"writes figures"| node_plots
node_task3_descriptors -->|"writes figures"| node_plots

click node_task1 "https://github.com/yatheendra-source/the-spotters-problem/blob/main/task1.py"
click node_task2 "https://github.com/yatheendra-source/the-spotters-problem/blob/main/task2.py"
click node_task3_corners "https://github.com/yatheendra-source/the-spotters-problem/blob/main/task3.py"
click node_task3_blobs "https://github.com/yatheendra-source/the-spotters-problem/blob/main/task3.py"
click node_task3_descriptors "https://github.com/yatheendra-source/the-spotters-problem/blob/main/task3.py"
click node_task4 "https://github.com/yatheendra-source/the-spotters-problem/blob/main/task4.py"

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_task1,node_user toneBlue
class node_task2 toneAmber
class node_task3_corners,node_task3_blobs,node_task3_descriptors toneMint
class node_task4 toneRose
class node_images,node_annotations,node_results,node_plots toneIndigo
```

## Components

### Image Processing

- [Filtering and metrics](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task1.py): `task1.py`

### Waldo Detection

- [Template detection](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task2.py): `task2.py`

### Feature Extraction

- [Harris corners](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task3.py): `task3.py`
- [DoG keypoints](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task3.py): `task3.py`
- [Orientation descriptors](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task3.py): `task3.py`

### Feature Matching

- [Descriptor matching and voting](https://github.com/yatheendra-source/the-spotters-problem/blob/main/task4.py): `task4.py`

### Other components

- **Assignment user**
- **Scenes and template**
- **Ground-truth annotations**
- **Detection and feature results**
- **Generated figures**

## Connections

- Assignment user → Filtering and metrics: runs first (evidence: `README.md`)
- Assignment user → Template detection: runs next (evidence: `README.md`)
- Assignment user → Harris corners: runs next (evidence: `README.md`)
- Assignment user → Descriptor matching and voting: runs last (evidence: `README.md`)
- Scenes and template → Filtering and metrics: supplies images
- Scenes and template → Template detection: supplies scenes (evidence: `README.md`)
- Scenes and template → Harris corners: supplies template (evidence: `task3.py`)
- Template detection → Filtering and metrics: imports helpers (evidence: `task2.py`)
- Harris corners → Filtering and metrics: imports helpers (evidence: `task3.py`)
- DoG keypoints → Template detection: uses peak finding (evidence: `task3.py`)
- Orientation descriptors → Filtering and metrics: uses image operations (evidence: `task3.py`)
- Template detection → Ground-truth annotations: scores detections (evidence: `README.md`)
- Orientation descriptors → Descriptor matching and voting: provides descriptors
- Template detection → Detection and feature results: produces detections (evidence: `task2.py`)
- Orientation descriptors → Detection and feature results: produces features (evidence: `task3.py`)
- Descriptor matching and voting → Detection and feature results: votes on answer (evidence: `README.md`)
- Filtering and metrics → Generated figures: writes figures (evidence: `task1.py`)
- Template detection → Generated figures: writes figures (evidence: `task2.py`)
- Orientation descriptors → Generated figures: writes figures (evidence: `task3.py`)
