Skip to content

COMPASSOne pixel config. Nine EM solvers. Cross-validated.

Open-source CMOS image sensor optics platform — define your pixel stack once and run it through 9 RCWA/FDTD/TMM backends to cross-check QE, crosstalk, and field maps.

COMPASS

Why COMPASS?

COMPASS bridges the gap between electromagnetic theory and practical CMOS image sensor design. Define your pixel stack once, run it through any solver, and compare results -- all from Python.

Multi-Solver Engine

Run the same pixel structure through RCWA (torcwa, grcwa, meent, fmmax) and FDTD (flaport, Meep, fdtdz) solvers from a single YAML config. Compare results head-to-head.

GPU Accelerated

Leverage PyTorch and JAX GPU backends for massively parallel wavelength sweeps. Achieve 10-100x speedup over CPU-only solvers on large parameter spaces.

dJ/dx

Differentiable Simulation

Automatic differentiation through the solver enables gradient-based inverse design. Optimize microlens profiles, BARL stacks, and color filter thicknesses directly.

OK

Cross-Validation

Built-in solver comparison framework ensures physics accuracy. Compare energy balance (R+T+A=1), QE spectra, and field distributions across solver backends.

Rich Analysis

Compute QE per pixel per wavelength, crosstalk matrices, energy balance, and field distributions. Plot results with built-in matplotlib and 3D PyVista viewers.

Open Source

MIT licensed. Fully documented with theory guides, cookbooks, and API references. Built on established open-source EM solver ecosystems.

Architecture

A clean five-stage pipeline takes you from YAML configuration to publication-ready results. Click any stage to learn more.

1ConfigYAMLPixel stackSourceSolver params2GeometryPixelStackMicrolensColor filterSilicon + DTI3SolverSolverBaseRCWAFDTDTMM4Analysisanalysis/QE calculatorEnergy balanceComparison5ResultsHDF5 / PlotQE spectraField mapsCrosstalk

Solver Backends

COMPASS provides a unified interface to 9 solver backends across three electromagnetic methods. Click any solver to see details.

RCWA4 backends
FDTD4 backends
TMM1 backends

Browser-Based Simulators

In addition to the Python solver pipeline, COMPASS ships with 20+ browser-based simulators for quick exploration and intuition-building. They run entirely client-side -- no install, no Python required -- and are designed for teaching, design-space exploration, and sanity checks before committing to a full RCWA/FDTD run.

  • Optical stack -- TMM QE, thin-film designer, energy budget
  • Performance -- SNR, dynamic range, EMVA 1288, photon transfer curve
  • Wave physics -- Si absorption, microlens raytrace, Fabry-Pérot, diffraction PSF
  • System -- MTF, color accuracy (ΔE), pixel scaling, dark current

Browse all simulators →

Quick Example

Define your simulation in a single YAML config and run it with three lines of Python:

yaml
# config.yaml
pixel:
  pitch: 1.0          # um
  unit_cell: [2, 2]   # 2x2 Bayer pattern

solver:
  name: torcwa
  type: rcwa
  fourier_order: 9

source:
  wavelength:
    mode: sweep
    sweep: { start: 0.4, stop: 0.7, step: 0.01 }
  polarization: unpolarized
python
from compass.runners.single_run import SingleRunner

result = SingleRunner.run("config.yaml")

for pixel, qe in result.qe_per_pixel.items():
    print(f"{pixel}: peak QE = {qe.max():.2%}")