# ricardoborsoi/mua_sparseunmixing architecture

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

- Interactive diagram: https://gitdiagram.com/ricardoborsoi/mua_sparseunmixing
- Repository: https://github.com/ricardoborsoi/mua_sparseunmixing

## Overview

The README identifies the product as MATLAB hyperspectral-image sparse unmixing: demos compare SUnSAL, SUnSAL-TV, and S2WSU, with fine-scale sparse unmixing and spatial segmentation/regularization as documented stages. However, the supplied tree contains only the bundled VLFeat subtree, not the MATLAB algorithms, demos, or segmentation code, so their internal workflow cannot be mapped to source components here. The graph therefore maps substantial VLFeat capabilities visible in the tree and the documented SLIC integration; source-level links beyond the shown index and excerpts are omitted.

Main entry points: [`vlfeat-0.9.20/vl/sift.c`](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/sift.c) (SIFT features), [`vlfeat-0.9.20/vl/kmeans.c`](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/kmeans.c) (K-means), [`vlfeat-0.9.20/vl/mathop.c`](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/mathop.c) (Math operations), [`vlfeat-0.9.20/toolbox/slic/vl_slic.c`](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/toolbox/slic/vl_slic.c) (SLIC superpixels)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_features["Image Features"]
  node_sift["SIFT features<br/>[sift.c]"]
  node_covdet["Covariant detection<br/>[covdet.c]"]
  node_dsift["Dense SIFT<br/>[dsift.c]"]
  node_liop["LIOP descriptors<br/>[liop.c]"]
  node_mser["MSER regions<br/>[mser.c]"]
  node_quickshift["Quick shift<br/>[quickshift.c]"]
  node_slic["SLIC superpixels<br/>[vl_slic.c]"]
end

subgraph group_clustering["Clustering Models"]
  node_kmeans["K-means<br/>[kmeans.c]"]
  node_hikmeans["Hierarchical k-means<br/>[hikmeans.c]"]
  node_ikmeans["Integer k-means<br/>[ikmeans.c]"]
  node_gmm["Gaussian mixtures<br/>[gmm.c]"]
  node_kdtree["KD forest queries<br/>[vl_kdtreequery.c]"]
end

subgraph group_learning["Learning and Encoding"]
  node_svm["Support vector machines<br/>[svm.c]"]
  node_fisher["Fisher encoding<br/>[fisher.c]"]
  node_vlad["VLAD encoding<br/>[vlad.c]"]
  node_aib["Agglomerative information bottleneck<br/>[aib.c]"]
end

subgraph group_support["Core Support"]
  node_generic["Generic runtime<br/>[generic.c]"]
  node_mathop["Math operations<br/>[mathop.c]"]
  node_imopv["Image operations<br/>[imopv.c]"]
  node_scalespace["Scale space<br/>[scalespace.c]"]
end

node_matlab(("MATLAB demos"))
node_mua["Unmixing implementation"]

node_matlab -->|"runs demos"| node_mua
node_matlab -.->|"uses for superpixels"| node_slic
node_mua -.->|"uses segmentation"| node_slic
node_sift -->|"uses image operations"| node_imopv
node_sift -->|"uses math"| node_mathop
node_covdet -->|"builds scale space"| node_scalespace
node_kmeans -->|"uses runtime"| node_generic
node_kmeans -->|"uses math"| node_mathop
node_gmm -->|"initializes with"| node_kmeans
node_svm -->|"uses math"| node_mathop
node_matlab -.->|"may access toolbox"| node_sift

click node_sift "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/sift.c"
click node_covdet "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/covdet.c"
click node_dsift "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/dsift.c"
click node_liop "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/liop.c"
click node_mser "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/mser.c"
click node_quickshift "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/quickshift.c"
click node_slic "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/toolbox/slic/vl_slic.c"
click node_kmeans "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/kmeans.c"
click node_hikmeans "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/hikmeans.c"
click node_ikmeans "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/ikmeans.c"
click node_gmm "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/gmm.c"
click node_kdtree "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/toolbox/misc/vl_kdtreequery.c"
click node_svm "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/svm.c"
click node_fisher "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/fisher.c"
click node_vlad "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/vlad.c"
click node_aib "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/aib.c"
click node_generic "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/generic.c"
click node_mathop "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/mathop.c"
click node_imopv "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/imopv.c"
click node_scalespace "https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/scalespace.c"

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_sift,node_covdet,node_dsift,node_liop,node_mser,node_quickshift,node_slic toneBlue
class node_kmeans,node_hikmeans,node_ikmeans,node_gmm,node_kdtree toneAmber
class node_svm,node_fisher,node_vlad,node_aib toneMint
class node_generic,node_mathop,node_imopv,node_scalespace toneRose
class node_matlab,node_mua toneIndigo
```

## Components

### Image Features

- [SIFT features](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/sift.c): `vlfeat-0.9.20/vl/sift.c`
- [Covariant detection](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/covdet.c): `vlfeat-0.9.20/vl/covdet.c`
- [Dense SIFT](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/dsift.c): `vlfeat-0.9.20/vl/dsift.c`
- [LIOP descriptors](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/liop.c): `vlfeat-0.9.20/vl/liop.c`
- [MSER regions](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/mser.c): `vlfeat-0.9.20/vl/mser.c`
- [Quick shift](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/quickshift.c): `vlfeat-0.9.20/vl/quickshift.c`
- [SLIC superpixels](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/toolbox/slic/vl_slic.c): `vlfeat-0.9.20/toolbox/slic/vl_slic.c`

### Clustering Models

- [K-means](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/kmeans.c): `vlfeat-0.9.20/vl/kmeans.c`
- [Hierarchical k-means](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/hikmeans.c): `vlfeat-0.9.20/vl/hikmeans.c`
- [Integer k-means](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/ikmeans.c): `vlfeat-0.9.20/vl/ikmeans.c`
- [Gaussian mixtures](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/gmm.c): `vlfeat-0.9.20/vl/gmm.c`
- [KD forest queries](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/toolbox/misc/vl_kdtreequery.c): `vlfeat-0.9.20/toolbox/misc/vl_kdtreequery.c`

### Learning and Encoding

- [Support vector machines](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/svm.c): `vlfeat-0.9.20/vl/svm.c`
- [Fisher encoding](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/fisher.c): `vlfeat-0.9.20/vl/fisher.c`
- [VLAD encoding](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/vlad.c): `vlfeat-0.9.20/vl/vlad.c`
- [Agglomerative information bottleneck](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/aib.c): `vlfeat-0.9.20/vl/aib.c`

### Core Support

- [Generic runtime](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/generic.c): `vlfeat-0.9.20/vl/generic.c`
- [Math operations](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/mathop.c): `vlfeat-0.9.20/vl/mathop.c`
- [Image operations](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/imopv.c): `vlfeat-0.9.20/vl/imopv.c`
- [Scale space](https://github.com/ricardoborsoi/mua_sparseunmixing/blob/master/vlfeat-0.9.20/vl/scalespace.c): `vlfeat-0.9.20/vl/scalespace.c`

### Other components

- **MATLAB demos**
- **Unmixing implementation**

## Connections

- MATLAB demos → Unmixing implementation: runs demos
- MATLAB demos → SLIC superpixels: uses for superpixels
- Unmixing implementation → SLIC superpixels: uses segmentation
- SIFT features → Image operations: uses image operations (evidence: `vlfeat-0.9.20/vl/sift.c`)
- SIFT features → Math operations: uses math (evidence: `vlfeat-0.9.20/vl/sift.c`)
- Covariant detection → Scale space: builds scale space (evidence: `vlfeat-0.9.20/vl/covdet.c`)
- K-means → Generic runtime: uses runtime (evidence: `vlfeat-0.9.20/vl/kmeans.c`)
- K-means → Math operations: uses math (evidence: `vlfeat-0.9.20/vl/kmeans.c`)
- Gaussian mixtures → K-means: initializes with (evidence: `vlfeat-0.9.20/vl/gmm.c`)
- Support vector machines → Math operations: uses math (evidence: `vlfeat-0.9.20/vl/svm.c`)
- MATLAB demos → SIFT features: may access toolbox
