Skip to content

Cross-validation and metrics ​

match ← All logistic growth benchmarks

One cutoff, a 7-day horizon, all metrics and a baseline comparison.

Input ​

benchmark/inputs/v1/logistic-implicit-floor.json: 96 history rows and 24 forecast rows.

Output ​

Largest difference: 1.6e-11 (< 0.0001% of the input's range).

Each row is one forecast made during cross-validation, next to the value that actually happened.

DateActualEffect ProphetPython ProphetDifference
2020-03-1856.348256.229056.22901.6e-11
2020-03-1957.183157.150057.15001.6e-11
2020-03-2057.725757.823757.82371.5e-11
2020-03-2158.110858.107958.10791.5e-11
2020-03-2258.293558.223858.22381.4e-11
2020-03-2358.446058.526058.52601.4e-11
2020-03-2459.023259.134559.13451.4e-11

Timing ​

Median of all measured repetitions.

StepEffect ProphetPython ProphetEffect Prophet is
Convert input rows17 µs364 µs22× faster
Plan cross-validation folds971 µs543 µs1.8× slower
Cross-validate16.6 ms60.2 ms3.6× faster
Compute metrics192 µs5.34 ms28× faster
Score baselines1.43 ms787 µs1.8× slower
First cross-validation in a new process184 ms1.53 s8.3× faster

Settings ​

The case declaration both libraries ran.

json
{
  "kind": "evaluation",
  "comparison": {
    "kind": "different-public-work",
    "evidenceId": "rolling-origin-evaluation-v1"
  },
  "configuration": {
    "growth": "logistic",
    "scaling": "absmax",
    "seasonalityMode": "additive",
    "holidaysMode": "additive",
    "changepoints": {
      "mode": "explicit",
      "timestamps": [
        "2020-02-10T00:00:00.000Z"
      ]
    },
    "changepointPriorScale": 0.2,
    "seasonalities": [
      {
        "name": "weekly-custom",
        "periodDays": 7,
        "fourierOrder": 2,
        "priorScale": 10
      }
    ],
    "events": [],
    "regressors": []
  },
  "pythonOptimizer": {
    "algorithm": "Auto",
    "maxIterations": 10000,
    "newtonFallback": true,
    "sigFigs": 12
  },
  "plan": {
    "horizonMs": 604800000,
    "cutoffs": [
      "2020-03-17T00:00:00.000Z"
    ]
  },
  "metricAggregation": "horizons",
  "mapeZeroActual": "exclude"
}

Inspired by Prophet from Meta. Not affiliated with Meta.