Skip to main content

iconoscope

iconoscope is a python package for exploring image collections using visual similarity based on image embeddings extracted from models like CLIP and DINOv2/3. Embeddings can be used to generate a mosaic where visually similar images appear near each other, or for interactive exploration in a preliminary HTML viewer.

The name iconoscope comes from the Greek words for image (εἰκών) and to see (σκοπεῖν). The iconoscope was the first practical video camera tube used in early television cameras.

This package was inspired by Andrej Karpathy's CNN embedding visualizer. Version 0.1 started as a python port of Karpathy's cnnembed Matlab code created with Claude Code.

Install

pip install iconoscope
pip install "iconoscope[umap]"   # include UMAP reducer

Or with uv:

uv add iconoscope
uv add "iconoscope[umap]"

CLIP backend

The CLIP embedding backend is not available on PyPI and must be installed separately:

pip install git+https://github.com/openai/CLIP.git

Usage

Two-stage pipeline: embed first (slow, GPU-accelerated), then mosaic (fast, iterate freely).

1. Embed

Extract features from a directory of images and save to an HDF5 file:

iconoscope embed ./images/ mycollection.h5

2. Mosaic

Reduce embeddings to 2D and render a mosaic image:

iconoscope mosaic mycollection.h5

Output defaults to mycollection.jpg. Coordinates are cached in the HDF5 file so subsequent runs skip the slow dimensionality reduction step.

3. Viewer

Generate an interactive HTML viewer:

iconoscope viewer mycollection.h5

Writes mycollection.html. Requires a pre-built Svelte app (cd viewer && npm install && npm run build).

Other commands

iconoscope info mycollection.h5          # inspect what's stored in an embeddings file
iconoscope cluster mycollection.h5 -k 12 # k-means clustering on embeddings

Embeddings file

The .h5 file is the hand-off between pipeline stages. It holds:

  • features — L2-normalized float32 embeddings [N, D]
  • paths — image paths [N]
  • coords — cached 2D coordinates [N, 2] (written after the first mosaic run)
  • cluster assignments (written by cluster)

Run iconoscope info to inspect the contents of any embeddings file.

Metadata

Release files for iconoscope 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for iconoscope 0.1.1
File Size Uploaded
iconoscope-0.1.1.tar.gz 11.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for iconoscope 0.1.1
File Interpreter ABI Platform
iconoscope-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 26.4 kB

Release files / iconoscope-0.1.1.tar.gz

Download URL iconoscope-0.1.1.tar.gz
Size 11.1 kB
Tags Source
SHA-256 checksum
How to use checksums
dddde52a68c93edcf1fcef03b79eb9a8e0cb9edc0a2e6b668364f55eb9867cb6
BLAKE2b-256 checksum
How to use checksums
a4017e6fc06c6516536b639c7761ce288f1865c55d525094e84bdb049e72d320
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / iconoscope-0.1.1-py3-none-any.whl

Download URL iconoscope-0.1.1-py3-none-any.whl
Size 15.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
16a6ba477c9b561d43ab7ce0404c9945cb8c52b4d3850110dbae74f1ac69eedf
BLAKE2b-256 checksum
How to use checksums
74fad5bbd2949826b03086ba3ea80774e5528c768ec9a61133317d33881589cb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page