Skip to content

NeuralForecastModel example notebook#3026

Merged
dennisbader merged 11 commits intomasterfrom
docs/nf_example_notebook
Feb 26, 2026
Merged

NeuralForecastModel example notebook#3026
dennisbader merged 11 commits intomasterfrom
docs/nf_example_notebook

Conversation

@dennisbader
Copy link
Collaborator

Checklist before merging this PR:

  • Mentioned all issues that this PR fixes or addresses.
  • Summarized the updates of this PR under Summary.
  • Added an entry under Unreleased in the Changelog.

Summary

Adds NeuralForecastModel example notebook.

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@dennisbader
Copy link
Collaborator Author

@daidahao I created the example notebook for NeuralForecastModel. Let me know if you would like to have a look :)

@codecov
Copy link

codecov bot commented Feb 22, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.66%. Comparing base (c3079fe) to head (d67c2aa).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3026      +/-   ##
==========================================
- Coverage   95.73%   95.66%   -0.07%     
==========================================
  Files         158      158              
  Lines       17122    17122              
==========================================
- Hits        16391    16380      -11     
- Misses        731      742      +11     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@daidahao
Copy link
Contributor

@dennisbader
Fabulous! I will have a closer look in the next few days.

@review-notebook-app
Copy link

review-notebook-app bot commented Feb 23, 2026

View / edit / reply to this conversation on ReviewNB

jakubchlapek commented on 2026-02-23T11:04:21Z
----------------------------------------------------------------

Line #18.    fig = pred_prob.plotly(label="KAN (probabilistic)", fig=fig)

when i loaded the notebook locally the plot was squashed by the too long labels. maybe we can do `label="KAN (probabilistic)<br>", should solve this issue without any other issues.


@review-notebook-app
Copy link

review-notebook-app bot commented Feb 23, 2026

View / edit / reply to this conversation on ReviewNB

jakubchlapek commented on 2026-02-23T11:04:22Z
----------------------------------------------------------------

essentially not esentially typo haha


@review-notebook-app
Copy link

review-notebook-app bot commented Feb 23, 2026

View / edit / reply to this conversation on ReviewNB

jakubchlapek commented on 2026-02-23T11:04:23Z
----------------------------------------------------------------

Line #13.    # finally, apply a MinMax scaler to scale all values into the range (0,1)

it was scaled before on line #6, maybe just comment with # finally, display the plot or sth


@review-notebook-app
Copy link

review-notebook-app bot commented Feb 23, 2026

View / edit / reply to this conversation on ReviewNB

jakubchlapek commented on 2026-02-23T11:04:23Z
----------------------------------------------------------------

Line #5.    pred = model_nf.fit(series_multivar[:-12]).predict(n=output_chunk_length)

could use output_chunk_length here instead of the 12 but nitpicky


@review-notebook-app
Copy link

review-notebook-app bot commented Feb 23, 2026

View / edit / reply to this conversation on ReviewNB

jakubchlapek commented on 2026-02-23T11:04:24Z
----------------------------------------------------------------

should be #7


@jakubchlapek
Copy link
Collaborator

hey @dennisbader, pretty much LGTM, some very very minor corrections, mostly out of personal preference lol. I like the plots with the direct comparisons between the models, as well as the covariate forecasting sections. It really shows how nice of a feature NF support is :)

@daidahao
Copy link
Contributor

daidahao commented Feb 23, 2026

@dennisbader
The notebook looks great and really highlights the versatility of Darts torch forecasting! I wonder if we could rearrange the topic order so it has better narrative (univariate -> univariate with covariates -> multivariate -> multiple series -> probabilistic) and becomes progressively more advanced with the topics.

  1. Quick Start (xLSTM [univariate], a "new" model to Darts).
  2. Forecasting Using Covariates (xLSTM again so we could have MAE comparisons).
  3. Historical Forecasts & Backtesting (xLSTM with covariates)
  4. Multivariate Forecasting (TimeXer [multivariate] with covariates)
  5. Multiple Series Forecasting (TimeXer, covariates might not be necessary)
  6. Probabilistic Forecasting (TiDE)
  7. Comparison: Darts TiDE vs NeuralForecast TiDE.

The reason I want to move Probabilistic Forecasting and Comparison at the end is because 1) probabilistic forecasting is visually different than all deterministic forecasting before and 2) the validation (Darts vs NF) might be more academic driven than being directly helpful to users.

Other than that, I think the PR is almost merge-ready.

@dennisbader
Copy link
Collaborator Author

Thanks for the review @daidahao, the suggestions make a lot of sense :) I updated the notebook 🚀

@dennisbader dennisbader merged commit 3ae6ca3 into master Feb 26, 2026
9 checks passed
@daidahao
Copy link
Contributor

Thanks for the review @daidahao, the suggestions make a lot of sense :) I updated the notebook 🚀

Sad to see the poltly() gone (guess it was not compatible with docs?) but the notebook is the best I've seen 🔥!

@dennisbader
Copy link
Collaborator Author

Thanks @daidahao :) Yes, unfortunately when rendering the notebooks with nbshinx during docs generation, the plotly figures either didn't show up in the HTML or source notebooks. Thought it was easiest to rollback to static images.

@dennisbader dennisbader deleted the docs/nf_example_notebook branch February 27, 2026 13:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants