Posts

Showing posts from November, 2026

e-means Meets DBSCAN: Two Moons Said Yes, Cairo Said No

Image
Back in 2016, I wrote DBSCAN on Spark . I like DBSCAN because you do not have to give it the number of clusters. But it uses a lot of time and memory when the input is large. This month, Meta FAIR and École des Ponts released e-means in faiss 1.16.0. It does the work of k-means in a few passes over the data. So I asked a simple question: can e-means make the data small, so that DBSCAN can do the rest? In this post, I show how I combined the two and how fast e-means is on a GPU. Then I test the method on real satellite data of Cairo. It did not win there. The source is on GitHub: mraad/emeans-dbscan . The e-means explorer after one run on Cairo with k = 3. All the arithmetic runs in the browser. The terms Vector. One row of numbers. There are n vectors, and each vector has d numbers. Centroid. The center point of a cluster. There are k centroids. Epoch. One pass over all the training vectors. Noise. The vectors that DBSCAN does not put in a cluster. Their...

map-pane: one live map for Claude Code, Codex and Pi

Image
I work most of the day in a terminal with a coding agent. When the work is spatial, I want to see the result on a map. I do not want to leave the terminal, and I do not want to write a web app first. map-pane is my answer. It is a live web map that an agent drives from the shell. The map uses the ArcGIS Maps SDK for JavaScript 5.2.2. Headless Chrome draws the map, and a terminal pane shows it. The pane also takes your mouse and keys, so you can pan and zoom by hand while the agent works. The code is at github.com/mraad/map-pane , MIT licensed. It needs macOS, Node.js 24 and Google Chrome. It has no npm dependencies. I want to keep it that way. What it does The agent can do these things on the map: Add data: GeoJSON (file, URL or inline), GeoPackage, GeoParquet, CSV, feature services, map services, tile and vector tile layers, and portal items. Style data: renderers, labels and filters. GeoJSON with one geometry type gets a legend entry and popups. Move the view: to a geocoded ...

Service Areas on the GPU and in the Browser, Checked Against ArcGIS

Image
I have used ArcGIS Network Analyst for service areas for a long time. You give it a start point and a few drive times, and it gives you the streets and the area that you can reach. It is correct, and it is the reference that people trust. But it is not fast. For 100 crash locations in Adams County, Ohio, with breaks of 1, 5 and 10 minutes, the solve takes 69 seconds. For all 2,483 crashes, it takes 31 minutes. So I asked a simple question: can a GPU calculate the same service areas, and I mean the same, not "close enough"? And if the GPU can do it, can the browser do it too? In this post, I show the three engines that I built, how I compare them with ArcGIS, and where they do not agree. The source is on GitHub: mraad/service-area . The live page. The mouse moves along a street near West Union, Ohio. The browser calculates the 5-minute service area again at each position. The problem The study area is Adams County, Ohio. The data is a file geodatabase with 3,063...

A Map Beside the Chat: An ArcGIS Mod for Claude Code

Image
Update, November 2026: This project is now part of map-pane. One skill drives the same live map from Claude Code, Codex and Pi. Read the current post: map-pane: one live map for Claude Code, Codex and Pi . Claude Code now has mods . A mod is a plugin with a hooks module: a TypeScript file whose functions Claude Code calls when events occur. A mod can add tools for Claude, slash commands, and panes beside the chat. When I read that, I had one question. Can I put a live ArcGIS map next to Claude, and can Claude draw on it while I talk to it? The answer is yes, with one interesting detour. In this post, I show the mod, explain how the parts connect, and tell you what does not work yet. The source is on GitHub: mraad/claude-mod-map . Markers in seven cities, labels, a geodesic route and a dark basemap, all placed with the mod's tools. What the mod does The mod gives Claude six tools. Each tool changes a map that uses the ArcGIS Maps SDK for JavaScript 5.2. add_gr...