Software
General-purpose research tools, released with tests, archived with DOIs.
Twelve research tools grew out of the research projects. All are maintained under the TaN-MM-Org organization and installable with a single pip command. They follow the same rules. The main results of each release are checked by automated tests that run publicly on every change, against textbook formulas, published results or a second, independent calculation. Built-in physical constants and parameter sets carry a citation to their source. Each release is archived on Zenodo under its own DOI. And each package says plainly what it does not do.
Every package also works with a lab’s own measurements. Most can plan a measurement before it is taken (which settings to measure, and how many repeats a target error bar will cost) and then fit the measured data with honest error bars, stopping with an explanation when the data cannot answer the question asked. One of the tools, labplan, is that planning-and-fitting layer on its own, for any model you can write as a Python function.
In September 2026 the documentation of every tool was rewritten in plain language, with worked examples whose printed output is checked by actually running them. Checking each document line by line against its code also turned up real bugs. They are fixed, each with a new test, in a patch release of every tool; the release notes and changelogs list each one.
ramansep
When an atomically thin material such as MoS2 is stretched, or gains extra electric charge, its Raman peaks shift. But both effects shift the same peaks, so a single measurement cannot tell them apart. ramansep untangles the two by combining peaks that respond differently, turning a Raman map into separate maps of strain and charge, each with honest error bars. It can also combine more than two peaks, and then it checks itself: it flags any pixel where strain and charge alone cannot explain the data, which no two-peak analysis can do. It ships published coefficient sets for MoS2 and graphene, and its test suite reproduces the edge-charge result of the nanoribbon study on the Research page. Latest release (0.15.0): it gives the strain and charge along a line, for example against distance from an edge, with the full error budget, and turns that profile into single numbers such as the extra charge per micrometer of edge. Results no longer depend on the units chosen for the charge density; before, some good calibrations were refused and one map was off by 6 parts in 10,000. Exact error bars of the smoothed map inversion are up to about 100 times faster on a large map, and a new worked tutorial is included.
pip install ramansep
kpenvelope
Calculates how holes (missing electrons) behave when trapped in thin layered stacks of nitride semiconductors such as GaN and AlN, the physics behind the hole-mass study on the Research page. It solves the standard six-band quantum model of the valence bands together with the electrostatics of the trapped charge, using published, cited material parameters. Recently added: realistic finite barriers, so a neighbouring layer no longer has to be treated as an impenetrable wall: material properties can change from layer to layer, and the results are checked against exact textbook solutions. Latest release (0.15.0): it gives the exact sensitivity of every computed energy to each band parameter, with propagated error bars, and transition strengths between whole energy levels that no longer depend on the solver's internal choices. The warning about missing states now also catches states that rise above their starting energy. The solver is about 2 times faster at finite momentum, and a new worked tutorial is included.
pip install kpenvelope
sqzcomb
Tiny ring resonators can produce "squeezed" light: light whose noise, measured the right way, drops below the usual quantum limit, a resource for precision measurement and quantum computing. sqzcomb predicts how much squeezing a detector will actually see from such a ring, including everything that eats it along the way: losses, imperfect detectors, and how the light is extracted. It covers pairs of coupled rings, which its test suite drives past the well-known single-ring extraction limit, and it can also quantify the quantum entanglement between pairs of comb lines. Its tests check it against textbook formulas and independent calculations. Latest release (0.17.0): it fits squeezing and antisqueezing measured at several pump levels to find the total detection efficiency and the phase jitter, and it fits resonances split in two by backscattering. A sign error made two linewidth error bars from transmission scans wrong (for example 0.33 MHz reported where the true scatter was 0.17 MHz). The coupled-ring spectrum model is about 5 times faster, and a new worked tutorial is included.
pip install sqzcomb
absnoise
In certain superconducting devices, the current is carried by a handful of quantum levels whose occupation flickers randomly even in perfect equilibrium. absnoise computes that intrinsic flicker and what it means for using such devices as extremely sensitive thermometers and photon-energy detectors: how precisely temperature can be read, how much noise is unavoidable, and where the fundamental limits sit. It ships junction recipes taken from published devices. It also works in reverse: given a noisy measured readout record, it recovers the hidden level occupation and the device's flip rates, and these estimates are tested on simulated records. Latest release (0.15.0): calibration now uses the exact critical current by default, so a calibrated MoRe junction reproduces its measured critical current; before, it came out 1.7 % low. The other recipes shift by 0.2 % or less. Version 0.14.0 added the detector's energy resolution at limited readout bandwidth, the exact critical current, a fix for wrong inductance results near zero phase difference, a dwell-time test about 3 times faster, and a new worked tutorial.
pip install absnoise
cavsqueeze
Simulates how an enormous number of atomic spins inside a resonator can be steered into a collectively quieter, "squeezed" state, a route to better clocks and magnetometers. Its solver's cost is set by the shape of the spin ensemble rather than its size (its documentation works an example with 1015 spins), and it cross-checks itself against exact solutions for small ensembles and against an independent second method. Developed for 171Yb3+:CaWO4 crystals and applicable to any spin ensemble coupled to a resonator, it also translates its results directly into the numbers an experiment is designed against (clock stability and magnetic-field sensitivity), and exports its states into the widely used QuTiP toolbox. Latest release (1.19.0): it calibrates the readout against projection noise using coherent spin states, and it carries the uncertainty of the subtracted detector noise into the squeezing error bars (without it, error bars were more than 1.5 times too small in a test). Repeated or unsorted output times no longer crash, and negative pulse durations, which used to pass silently, are refused. The solver runs about 1.5 times faster, and a new worked tutorial is included.
pip install cavsqueeze
SPARQ
Finding a good single-photon emitter (the light source behind many quantum technologies) means measuring hundreds of candidate spots, most of them useless. SPARQ automates that screening. It simulates the standard photon-correlation measurement faithfully, analyzes real measured data with honest uncertainties, and decides on the fly how long to keep measuring each spot, stopping the moment the evidence is sufficient instead of waiting out a fixed dwell time. It also includes machine-learning agents that learn the screening strategy itself, from our SPARQ paper (ACS Photonics, 2026). The physics core is tested against exact reference calculations. It ships built-in parameter ranges for four kinds of emitter (NV and SiV centres in diamond, and emitters in hBN and GaN) and lets you add your own. Latest release (0.14.0): it fits the excited-state lifetime from pulsed-laser timing histograms, with one or two decays, timing jitter and leftover light from earlier pulses, and gives intervals and a fit-quality test. The saturation fit now refuses data it cannot fit instead of returning nonsense. Writing PTU files is about 5 times faster, and a new worked tutorial is included.
pip install sparq-triage
vacspin
Certain atomic-scale defects in diamond, such as the silicon-vacancy, germanium-vacancy and tin-vacancy centres, act as tiny quantum memories that talk to light, which makes them building blocks for quantum networks. vacspin computes how such a centre behaves in a real, imperfect sample: how strain in the crystal and applied magnetic fields shift its energy levels, how cleanly it can be read out in a single shot, and how the fluorescence budget splits between its optical transitions. Every built-in parameter set carries its source. The tin-vacancy set uses the device values of a published experiment; for the silicon- and germanium-vacancy centres only the measured energy splittings are built in, and sample-specific values such as strain are left for you to fit from your own data. The lead-vacancy centre is documented but not shipped, because its parameters are not yet fully measured. Latest release (0.8.0): it fits the excited-state lifetime from a photon-timing histogram, with error bars and a fit-quality test, and turns lifetimes measured with the cavity tuned away and on resonance into the cooperativity and the share of light going into the cavity. It gives the readout fidelity at the photon-count threshold an experiment actually uses. At magnetic fields too weak to split the spin states it now refuses instead of returning numbers set by rounding error, and a new worked tutorial is included.
pip install vacspin
hamop
Many properties of a material (its electronic energy levels, how it absorbs light, how well it carries current, even subtle "topological" properties) are usually computed by separate programs with separate conventions, and the answers can quietly drift apart. hamop computes all of them from one and the same simple model of electrons hopping between atoms, so they start from the same description of the material. It handles magnetic fields, spin, disorder and very large systems, and it checks itself: its numerical tests (253 tests in all) compare it with exact textbook results, symmetries or a second calculation done a different way, and several key quantities are computed by two independent routes that must agree. It was distilled from the modelling pipeline behind the MoS2 defect study, generalized so any material model can be pushed through it. Latest release (0.14.0): it computes the conductivity, Seebeck coefficient and electronic heat conductivity in the Boltzmann picture, and it handles ribbons and other systems that repeat in fewer directions than they have dimensions. Symmetry folding now refuses operations it cannot apply correctly (before, uneven meshes or operations given as a generator gave wrong densities of states), and models whose number of states changes with momentum no longer crash. Berry-curvature tools run 20 to 160 times faster, and a new worked tutorial is included.
pip install hamop
fabtwin
Optical filters are built by depositing many thin layers, and no deposition machine hits its targets exactly. The errors are not simple random scatter: they drift, they depend on the recipe, and it is the rare bad runs, not the average one, that decide how many manufactured devices actually work. fabtwin learns a machine's error behaviour from its own production logs, then redesigns the filter so that even the worst runs come out well. The optics behind it is exact, and every derivative it uses is worked out by hand and cross-checked against an independent method. Grown out of our FabGAN-ID paper (IEEE Sensors Journal, 2026), it accepts any lab's own logged data through a documented file format, and states plainly what a model learned from logs can and cannot promise. Latest release (0.11.0): it predicts how thickness errors build up over a whole optically monitored run, layer by layer, and checks the prediction by simulating runs. Two fixes: wavelength points exactly on a band edge were left out of the merit function, and the drift test gave p-values that were too small with few runs. Scoring many designs at once is about 2 to 4 times faster, and a new worked tutorial is included.
pip install fabtwin
fracpll
Almost every radio, radar and fast chip contains a phase-locked loop: a circuit that multiplies a clean reference clock up to the gigahertz frequency the system actually needs. Designing one raises the same questions in every technology: is the loop stable, and by how much? How much noise does the fractional divider add? What does the closed loop do to the oscillator noise you measured, and how much timing jitter comes out? Will it lock, and how large a timing offset does leakage leave once it has? fracpll answers all of these from measured pieces: your tuning curves, your noise points, your pump current, each behind a mandatory provenance field. It computes the divider control sequence with exact integer arithmetic (its average is exact as a fraction, not approximately), validates the noise formula against a simulation of that exact sequence, and refuses, with an explanation, wherever its averaged model stops being trustworthy. Version 0.2 goes further than any averaged model can: it also simulates the loop edge by edge, exactly as the phase detector and charge pump switch, which shows cycle slips, dead zones, pump mismatch and loops running close to the reference frequency, and it gives the exact stability limit at any loop bandwidth. Version 0.3 explains an effect those edge-by-edge runs revealed: with a fractional divider, the noise near the loop bandwidth is higher than a simple linear model predicts (15 dB higher in the worked example), because each charge-pump pulse lasts a finite time. A new fast model computes this with no fitted numbers and matches the full simulation. Version 0.3.1 fixes a 3 dB error in converting measured noise from dBc/Hz, refuses negative oscillator gain where the simple model cannot handle it, adds support for older NumPy versions, and rewrites the documentation in plain language with worked examples. Latest release (0.7.0): it predicts the reference spurs of a locked integer-N loop from leakage and pump mismatch, and it reports the closed-loop bandwidth and peaking. A crash with very large fractional moduli under NumPy 2 is fixed, several inputs that were silently truncated are now refused, and the stability-margin routine is about 1.6 times faster, and a new worked tutorial is included. Its main results are cross-checked against independent exact calculations. Distilled from the GaN-on-SOI PLL study on the Research page, and usable for any charge-pump loop in any technology.
pip install fracpll
lockkernel
Fireflies, heart cells, power grids and laser arrays all do the same thing: above a critical coupling strength, a crowd of individually different oscillators suddenly starts beating together. How sharply that order grows near the onset is set by a single object, the locking kernel: how well one oscillator follows the crowd as a function of how detuned it is. lockkernel computes the whole transition exactly for any frequency spread and any kernel, with no fitting and no simulation error near the critical point, to high numerical precision. And it works in reverse for the lab: given a measured synchronization curve, it fits the threshold and the growth exponent with honest error bars, tells you what the exponent reveals about the underlying kernel, refuses to over-claim when the data cannot distinguish the candidates, and prices how many measurement points a target error bar will cost. It is the maintained distribution of the reference code behind the locking-kernel universality study, with the same tests. Latest release (1.5.1): the license NOTICE file is included in the package again; no code changed. Version 1.5.0 fits the exact synchronization curve to measured data over the whole range, not only near the threshold, with a test of whether the model fits. It has two fixes: lines with sharp edges (such as a box-shaped spread) gave wrong tail integrals, and the measurement planner refused targets that needed between 6.3 and 10 million points. The exact solver for small ensembles is about 13 to 15 times faster, and a new worked tutorial is included.
pip install lockkernel
labplan
The question every lab faces before every calibration: which settings should we measure, and how many repeats will the error bar we need actually cost? labplan answers it for any instrument or experiment you can describe with a Python function. It plans the measurement before you take it (telling you which settings are most informative and how many repeats your target error bar will cost), fits your data with honest uncertainties once you have it, tells you when a planned measurement cannot determine what you asked for (and refuses to fit or design with it), and can wrap the result in error bounds whose coverage guarantee does not depend on the model being right. It then writes the record an audit or a lab notebook actually needs: values with error bars, a fingerprint of the raw data, software versions, timestamp and operator. It needs nothing beyond NumPy, and a literature reference is a required field of every model, not a comment. Latest release (0.5.0): it fits data in which the settings also have error bars (the classic errors-in-both-variables problem), checked against published reference values. A rounding problem that could make conformal error bounds one step too tight at very large sample sizes is fixed. Reading a calibration curve backwards is up to about 60 times faster for many readings, and a new worked tutorial is included.
pip install labplan
Citing the tools
Each repository carries a CITATION.cff file with citation metadata that GitHub renders directly, and each release has its own Zenodo DOI. If one of these tools contributes to a publication, please cite the versioned DOI you used.
Contributing
Issues and pull requests are welcome on each repository. The contribution bar is the same as the release bar: a change that touches physics arrives with a test, and constants arrive with their source.
Support this work
This software is developed at the Department of Electrical and Electronic Engineering, BRAC University, and released openly under the Apache-2.0 license. The Support page lists every way to help, from citing the tools to a small monthly donation.