google-research / timesfm

TimesFM (Time Series Foundation Model) is a pretrained time-series foundation model developed by Google Research for time-series forecasting.
https://research.google/blog/a-decoder-only-foundation-model-for-time-series-forecasting/
Apache License 2.0
3.02k stars 228 forks source link

ImportError: Failed to load native TensorFlow runtime during timesfm import #75

Open MatthiasNeumueller opened 3 weeks ago

MatthiasNeumueller commented 3 weeks ago

Environment Details:

Issue Description: I followed the instructions to run the timesfm model on the cpu and set up the conda environment based on the environment_cpu.yml file. The setup of the conda environment ran through without any errors or warnings. However, when attempting to import the timesfm module and create the model, I encountered an ImportError related to TensorFlow's native runtime.

Error Message:

File "pywrap_tensorflow.py", line 77, in <module>
    raise ImportError(ImportError: Traceback (most recent call last):
  File "pywrap_tensorflow.py", line 62, in <module>
    from tensorflow.python._pywrap_tensorflow_internal import *
ImportError: /.../_pywrap_tensorflow_internal.so: undefined symbol: _ZNK10tensorflow4data11DatasetBase8FinalizeEPNS_15OpKernelContextESt8functionIFNS_8StatusOrISt10unique_ptrIS1_NS_4core15RefCountDeleterEEEEvEE

Failed to load the native TensorFlow runtime.

Additional Information: I am seeking help to understand this error and find a possible fix. The detailed ImportError suggests an issue with _pywrap_tensorflow_internal.so, which could be related to an improper TensorFlow build or configuration specific to CPU environments.