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

[BUG] Wrong import from statsforecast when installing u8darts-torch #1197

Closed
JeroenPeterBos opened this issue Sep 8, 2022 · 2 comments
Closed
Labels
bug Something isn't working triage Issue waiting for triaging

Comments

@JeroenPeterBos
Copy link

Describe the bug
There are import errors when I try to import TFTModel after installing using u8darts-torch using conda.

To Reproduce
I run the following commands from an M1 macos device.

conda create -n bug-example -c conda-forge pytorch u8darts-torch -y
conda activate bug-example
python
>>> from darts.models import TFTModel

Which returns:

from statsforecast.models import croston_classic, croston_optimized, croston_sba
ImportError: cannot import name 'croston_classic' from 'statsforecast.models'

I checked statsforecast and indeed croston_classic does not exist, only _croston_classic and CrostonClassic.

Expected behavior
A clear and concise description of what you expected to happen.

System (please complete the following information):

  • Python version: 3.8
  • darts version: 0.20.0

Additional context
I am running this from an M1 mac with OS 12.5.1
Additionally, I first tried to install u8darts-all using conda create -n test python=3.8 pytorch u8darts-all, but that could not find any satisfable dependency configuration.

@JeroenPeterBos JeroenPeterBos added bug Something isn't working triage Issue waiting for triaging labels Sep 8, 2022
@JeroenPeterBos
Copy link
Author

After some further digging I found that this issue is fixed in this PR that has already been merged:

If anyone else runs into this issue, you can probably solve it by explicitly installing statsforecasts==0.6.0.

@hrzn
Copy link
Contributor

hrzn commented Sep 12, 2022

Yes, this should be fixed in 0.21.0 with statsforecasts>0.6.0 as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage Issue waiting for triaging
Projects
None yet
Development

No branches or pull requests

2 participants