Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Minor BUG] num_workers when calling predict/historical_forecasts of specific models #1767

Closed
pfk-beta opened this issue May 13, 2023 · 0 comments · Fixed by #2050
Closed
Labels
improvement New feature or improvement

Comments

@pfk-beta
Copy link

pfk-beta commented May 13, 2023

Hello,

Not sure if it is a bug, or just little inconvenience (darts==0.23.1)

My scenario:

  1. calling historic_forecast of TFT model without retrain, and only for few historic elements
  2. getting a lot of PossibleUserWarning: The dataloader, predict_dataloader 0, does not have many workers which may be a bottleneck. Consider increasing the value of the `num_workers` argument` (try 4 which is the number of cpus on this machine) in the `DataLoader` init to improve performance.

After quick debugging:

  1. forecasting_model.py(1802)_predict_wrapper() is calling TFTModel's predict function, but doesn't pass num_loader_workers
  2. predict_wrapper is called from historic_forecast as almost last statement.

Proposition:

  1. Historic_forecast should have extra parameter num_loader_workers - named, or as kwargs...
  2. This parameter should be passed to predict-wrapper, and then to predict.
  3. Not sure about interfering with other elements of Darts.

Btw. Darts is wonderfull and very usefull software. And big thanks to their developers :)\

@pfk-beta pfk-beta added bug Something isn't working triage Issue waiting for triaging labels May 13, 2023
@pfk-beta pfk-beta changed the title [Minor BUG] num_workers when calling predict of specific models [Minor BUG] num_workers when calling predict/historical_forecasts of specific models May 13, 2023
@madtoinou madtoinou added improvement New feature or improvement and removed bug Something isn't working triage Issue waiting for triaging labels Nov 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement New feature or improvement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants