Skip to content
equation discovery · symbolic regression

KD A platform for Knowledge Discovery

KD is a plug-in platform for equation discovery. It gives different discovery algorithms a consistent, easy-to-use interface and provides shared services such as visualization, evaluation, and experiment management, while leaving each algorithm free to implement its own search procedure.

SGA-PDE · kdv · seed 42 generation 200 / 200 · nmse 2.70e-06 · AIC -19.42
Heatmap of the kdv field u over x and t
\(u_t =\)\(-u\,u_x\)\(-0.0025\,u_{xxx}\)
An SGA-PDE run on the KdV dataset, showing the field it was given and the equation it returned.
scroll

Quick start

Install KD and run your first equation-discovery experiment in a few lines of Python. The example below uses a Burgers dataset bundled with KD.

1  install
git clone -b trunk https://github.com/Scientific-Artificial-Intelligence-Lab/kd.git
cd kd && uv sync
2  fit
import kd

# a 256 × 201 (x, t) field; for your own arrays, PDEDataset.from_arrays
data = kd.load_burgers()

model = kd.Model(algorithm="sga", generations=5, seed=0)
model.fit(data)
5 generations · AIC -28.78
\(u_t =\)\(-u\,u_x\)\(+0.1002\,u_{xx}\)

Examples

Algorithms

KD currently provides seven equation-discovery algorithms through a common interface.

Design