npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@paulrobins/wafermap

v0.7.0

Published

Browser-first wafer map visualization toolkit with a renderer abstraction and Plotly adapter.

Readme

wafermap

Browser-first wafer map visualization for semiconductor test data.

Live demos →

| Demo | Live | Source | | --- | --- | --- | | Renderer Comparison | open | examples/plotly-integration-demo/ | | CSV Analyzer | open | examples/app-demo/ | | Lot Gallery | open | examples/gallery-demo/ | | Bin Occurrence Map | open | examples/bin-gallery-demo/ | | Geometry Inference | open | examples/inference-demo/ | | Bundler Setup | open | examples/vite-demo/ | | Manual Pipeline | open | examples/basic-demo/ |


API overview

buildWaferMap()       — data layer: prober results → wafer + dies + scene
    │
    ├── renderWaferMap()     — single interactive canvas map with full toolbar
    ├── renderWaferGallery() — multi-map gallery with shared controls + click-to-modal
    └── toPlotly()           — Plotly SVG renderer (bring your own Plotly CDN)

x and y are always die grid positions (prober step coordinates), not millimetres.


Canvas rendering (no Plotly required)

Single interactive map

import { buildWaferMap } from '@paulrobins/wafermap';
import { renderWaferMap } from '@paulrobins/wafermap/canvas-adapter';

const { wafer, dies } = buildWaferMap({
  results:     rows.map(r => ({ x: +r.x, y: +r.y, bins: [+r.hbin], values: [+r.testA] })),
  waferConfig: { diameter: 300, notch: { type: 'bottom' } },
  dieConfig:   { width: 10, height: 10 },
});

const canvas = document.getElementById('map');
const ctrl = renderWaferMap(canvas, wafer, dies, {
  sceneOptions: { plotMode: 'hardbin' },
  onClick:  die  => console.log('clicked', die),
  onSelect: dies => console.log('selected', dies.length, 'dies'),
  onSceneOptionsChange: opts => syncSidebar(opts),
});

// Programmatic control
ctrl.setOptions({ plotMode: 'value', colorScheme: 'viridis' });
ctrl.clearSelection();
ctrl.resetView();
ctrl.destroy();

The toolbar provides: camera download · zoom-region · pan · zoom+/− · reset · plot mode · colour scheme · ring/quadrant/label toggles · rotate · flip.

Multi-map gallery

import { renderWaferGallery } from '@paulrobins/wafermap/canvas-adapter';

const galleryCtrl = renderWaferGallery(
  document.getElementById('gallery'),
  waferIds.map(id => ({ wafer: wafers[id], dies: dies[id], label: id })),
  {
    sceneOptions: { plotMode: 'hardbin' },
    onSceneOptionsChange: opts => syncSidebar(opts),
  },
);

// One shared control bar drives all cards simultaneously.
galleryCtrl.setOptions({ plotMode: 'value' });

// Clicking a card opens a full-screen modal with the full toolbar.
// The gallery bar also has a composite PNG download button.

Plotly rendering

import { buildWaferMap, toPlotly } from '@paulrobins/wafermap';

const result = buildWaferMap({
  results:     rows.map(r => ({ x: +r.x, y: +r.y, bins: [+r.hbin], values: [+r.testA] })),
  waferConfig: { diameter: 300, notch: { type: 'bottom' } },
  dieConfig:   { width: 10, height: 10 },
});

const { data, layout } = toPlotly(result.scene);
Plotly.react('chart', data, layout, { responsive: true });

Plotly.js must be loaded separately (CDN or bundler). No runtime dependency on Plotly is included in this package.


Architecture

packages/core/           — wafer geometry, die generation, clipping, transforms (no DOM, no Plotly)
packages/renderer/       — buildWaferMap(), buildScene() → renderer-agnostic Scene
packages/plotly-adapter/ — toPlotly(): Scene → Plotly { data, layout }
packages/canvas-adapter/ — renderWaferMap(), renderWaferGallery(), toCanvas()
packages/worker/         — createWafermapWorker(): run buildWaferMap off the main thread

Plot modes

'value' · 'hardbin' · 'softbin' · 'stackedValues' · 'stackedBins'

Key features

  • True rectangular die rendering with configurable kerf gap
  • Wafer clipping with partial die detection and edge exclusion zone
  • Wafer orientation flat / V-notch rendered from diameter automatically
  • Interactive rotate, flip, zoom, pan, and die selection
  • Reticle, probe path, ring, quadrant, and XY indicator overlays
  • Multi-channel values[] and bins[] per die
  • Lot-level stacking (lotStack) with mean / median / stddev / countBin / mode / percent aggregation
  • Adaptive geometry inference — omit die size or diameter and the library estimates them
  • Configurable colour schemes; continuous colorbar for value modes; bin legend with click-to-highlight for bin modes
  • Web Worker support via createWafermapWorker for off-main-thread data processing

Full API reference: docs/API.md


Running demos locally

npm install
npm run build
python3 -m http.server 8000
# open http://localhost:8000/examples/plotly-integration-demo/

For the Vite demo:

cd examples/vite-demo
npm install
npm run dev