Skip to main content
Validate Ecm Endpoint
curl --request POST \
  --url https://api.ionworks.com/ecm/validate \
  --header 'Content-Type: application/json' \
  --data '
{
  "measurement_id": "<string>",
  "example_id": "<string>",
  "start_step": 123,
  "end_step": 123,
  "initial_soc": 0.5,
  "capacity": 1,
  "fit_results": {
    "soc": [
      123
    ],
    "ocv": [
      123
    ],
    "r0": [
      123
    ],
    "rc_pairs": [
      {
        "r": [
          123
        ],
        "c": [
          123
        ],
        "tau": [
          123
        ]
      }
    ],
    "capacity_Ah": 1
  },
  "parameterized_model_id": "<string>"
}
'
{
  "rmse_mV": 123,
  "mae_mV": 123,
  "max_mV": 123,
  "num_rcs": 123,
  "capacity_Ah": 123,
  "initial_soc": 123,
  "model_source": "<string>",
  "time": [
    123
  ],
  "data_voltage": [
    123
  ],
  "model_voltage": [
    123
  ],
  "residual_mV": [
    123
  ]
}

Body

application/json

Request body for validating a fitted ECM against a held-out trace.

Provide exactly one held-out data source (measurement_id or example_id) and exactly one model source (fit_results or parameterized_model_id). The model is re-simulated forward on the held-out current — no fit and no pipeline — and compared to the held-out voltage.

measurement_id
string | null

Held-out cell measurement to validate against.

example_id
string | null

Built-in example dataset id to validate against.

start_step
integer | null

Optional inclusive start step (measurement only).

end_step
integer | null

Optional inclusive end step (measurement only).

initial_soc
number | null

Known SOC (0–1) at the start of the held-out trace. When omitted it is recovered from the trace's first voltage via the fitted OCV(SOC) curve (assumes the trace starts near rest).

Required range: 0 <= x <= 1
capacity
number | null

Cell capacity [Ah] for the SOC integration. Defaults to the fit/model capacity (the SOC reference the curves were fitted against); it is never re-estimated from the held-out trace.

Required range: x > 0
fit_results
FitResultsData · object

In-memory fit results to re-simulate.

parameterized_model_id
string | null

Saved ECM parameterized model to re-simulate.

Response

Successful Response

Held-out validation result: error metrics + downsampled overlay traces.

rmse_mV
number
required

Root-mean-square voltage error [mV].

mae_mV
number
required

Mean absolute voltage error [mV].

max_mV
number
required

Maximum absolute voltage error [mV].

num_rcs
integer
required

RC-pair count of the validated model.

capacity_Ah
number
required

Capacity used for SOC integration [Ah].

initial_soc
number
required

Initial SOC used for the held-out trace.

model_source
string
required

Where the validated model came from.

time
number[]
required

Downsampled time grid [s].

data_voltage
number[]
required

Held-out measured voltage [V].

model_voltage
number[]
required

Re-simulated model voltage [V].

residual_mV
number[]
required

Model − data voltage residual [mV].