
Nested Clusters with EVoC
by marimo team
Explore nested clusters in Fashion MNIST using EVoC with interactive parallel coordinates and treemap views.
About this notebook
This notebook clusters the Fashion MNIST clothing images with EVoC and shows the nested cluster structure the algorithm finds. Sliders select 2,500 to 5,000 sample images and the number of components, and a checkbox switches the reduction method between PCA and UMAP. The reduced data lives in a Polars DataFrame, and wigglystuff widgets render it.
The notebook has three interactive views. An Altair scatter plot shows the first two components. Brush a rectangle and marimo re-runs the dependent cells, which show up to ten of the selected images as matplotlib thumbnails with their labels. A parallel coordinates widget from wigglystuff plots every component on its own axis, colored by clothing label.
EVoC fits the same image sample and returns cluster labels at several nested levels in its cluster_layers_ attribute. The notebook adds three of these layers as extra axes on a second parallel coordinates plot, with small random jitter so the integer labels do not overlap. A wigglystuff treemap shows the same three layers as nested rectangles. Hover on a rectangle and the notebook shows up to ten sample images from that cluster.











