moment-timeseries-foundation-model / moment

MOMENT: A Family of Open Time-series Foundation Models
https://moment-timeseries-foundation-model.github.io/
MIT License
379 stars 58 forks source link

"TypeError: MOMENTPipeline.__init__() missing 1 required positional argument: 'config' " is still here #63

Open ZQLQY opened 2 weeks ago

ZQLQY commented 2 weeks ago

Hello, I encountered this issue while trying to load the model in the forecasting notebook.The current version of momentfm is 0.1.2. The error message states that a config file is missing, but I couldn't find this file in the project. I have seen the previous issue, and unfortunately, this problem still persists.So, is the config file something that needs to be downloaded? Is this issue caused by a network problem? Could you provide a solution or share the config file? Thank you very much. image

yigedabuliu commented 1 day ago

I chose to load the local model file successfully, you can also download the model before loading it. model = MOMENTPipeline.from_pretrained( "[your path]/models/MOMENT-1-large", model_kwargs={ 'task_name': 'forecasting', 'forecast_horizon': 96, 'head_dropout': 0.1, 'weight_decay': 0, 'freeze_encoder': True, # Freeze the patch embedding layer 'freeze_embedder': True, # Freeze the transformer encoder 'freeze_head': False, # The linear forecasting head must be trained }, local_files_only=True, # Whether or not to only look at local files (i.e., do not try to download the model). ) image