Skip to content

Refit after a week of new data ​

match ← All flat growth benchmarks

fit(history, { growth: "flat", map: { warmStart } }) from warmStartParameters of a fit of the first 89 days, against fit(df, init=warm_start_params(m)). 96 days around one level with a weekly rhythm, fitted with Newton. Timings compare the refit with a fresh fit.

Input ​

benchmark/inputs/v1/flat-seasonal.json: 96 history rows and 24 forecast rows.

Output ​

Largest difference: 5.6e-6 (0.00019% of the input's range).

Every forecast row from both libraries.

DateEffect ProphetPython ProphetDifference
2020-04-0633.633433.63341.4e-6
2020-04-0733.911533.91153.2e-6
2020-04-0835.002535.00254.0e-6
2020-04-0936.096836.09685.6e-6
2020-04-1036.366336.36632.5e-6
2020-04-1135.607835.60782.8e-6
2020-04-1234.392134.39213.6e-6
2020-04-1333.633433.63341.4e-6
2020-04-1433.911533.91153.2e-6
2020-04-1535.002535.00254.0e-6
2020-04-1636.096836.09685.6e-6
2020-04-1736.366336.36632.5e-6
2020-04-1835.607835.60782.8e-6
2020-04-1934.392134.39213.6e-6
2020-04-2033.633433.63341.4e-6
2020-04-2133.911533.91153.2e-6
2020-04-2235.002535.00254.0e-6
2020-04-2336.096836.09685.6e-6
2020-04-2436.366336.36632.5e-6
2020-04-2535.607835.60782.8e-6
2020-04-2634.392134.39213.6e-6
2020-04-2733.633433.63341.4e-6
2020-04-2833.911533.91153.2e-6
2020-04-2935.002535.00254.0e-6

Timing ​

Median of all measured repetitions.

StepEffect ProphetPython ProphetEffect Prophet is
Fit110 ms389 ms3.5× faster
Refit from an earlier fit6.38 ms8.52 ms1.3× faster

Settings ​

The case declaration both libraries ran.

json
{
  "kind": "map",
  "comparison": {
    "kind": "equivalent-objective",
    "evidenceId": "flat-growth-reduced-v1"
  },
  "fitRequest": "growth-only",
  "configuration": {
    "growth": "flat",
    "scaling": "absmax",
    "seasonalityMode": "additive",
    "holidaysMode": "additive",
    "changepoints": {
      "mode": "auto",
      "count": 25,
      "range": 0.8
    },
    "changepointPriorScale": 0.05,
    "seasonalities": [
      {
        "name": "weekly",
        "periodDays": 7,
        "fourierOrder": 3,
        "priorScale": 10
      }
    ],
    "events": [],
    "regressors": []
  },
  "pythonOptimizer": {
    "algorithm": "Auto",
    "maxIterations": 10000,
    "newtonFallback": true
  },
  "warmStart": {
    "baseRows": 89,
    "investigateParameterAbsolute": 0.01
  }
}

Inspired by Prophet from Meta. Not affiliated with Meta.