Error while running "https://keras.io/examples/timeseries/timeseries_weather_forecasting/"

Hello

Any ideas about the error below:

2022-10-04 14:41:09.389230: W tensorflow/compiler/xla/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library ‘cudart64_110.dll’; dlerror: cudart64_110.dll not found
2022-10-04 14:41:09.389417: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
Traceback (most recent call last):
File “D:\Deepak\AI\timeseries-weather\timeseries_weather_forecasting.py”, line 16, in
import tensorflow as tf
File “C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\tensorflow_init_.py”, line 469, in
_keras._load()
File “C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\tensorflow\python\util\lazy_loader.py”, line 41, in load
module = importlib.import_module(self.name)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.2032.0_x64__qbz5n2kfra8p0\lib\importlib_init
.py", line 126, in import_module
return bootstrap.gcd_import(name[level:], package, level)
File "C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\keras_init
.py", line 21, in
from keras import models
File "C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\keras\models_init
.py", line 18, in
from keras.engine.functional import Functional
File “C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\keras\engine\functional.py”, line 34, in
from keras.engine import training as training_lib
File “C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\keras\engine\training.py”, line 44, in
from keras.saving import save
File “C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\keras\saving\save.py”, line 23, in
from keras.saving.saved_model import load_context
File “C:\Users\ADMIN\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\keras\saving\saved_model\load_context.py”, line 68, in
tf.internal.register_load_context_function(in_load_context)
AttributeError: module ‘tensorflow.compat.v2.internal’ has no attribute ‘register_load_context_function’. Did you mean: ‘register_call_context_function’?

Platform Details:

OS: Windows 10 Home

Python: 3.10.7

Keras: 2.10.0

Tensorflow: 2.10.0

I am also getting the same error while using tensor flow

Is this error resolved ?

@Deepak_Goel, @Raghav_Gupta,

Sorry for the delayed response.

You must have the Tensorflow package installed in order to utilise Keras. After installing Tensorflow, just import Keras using:

from tensorflow import keras

I recommended that you follow the step-by-step instructions and let us know?

Thank you!