Need help in Tensorflow using

Hello, I tried too train my model using resnet_50,and get the following warning:

/slurm/home/yrd/liaolab/nieshuyang/.local/lib/python3.9/site-packages/tensorflow/python/keras/engine/base_layer_v1.py:1694: UserWarning: layer.apply is deprecated and will be removed in a future version. Please use layer.__call__ method instead.
warnings.warn('layer.apply is deprecated and ’
2024-03-07 10:39:30.701518: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library ‘libcudnn.so.8’; dlerror: libcudnn.so.8: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /slurm/home/yrd/liaolab/nieshuyang/.local/lib/python3.9/site-packages/cv2/…/…/lib64:/slurm/soft/gcc/11.3.0/lib64:/slurm/soft/gcc/gmp/6.2.1/lib:/slurm/soft/gcc/mpc/1.2.1/lib:/slurm/soft/gcc/mpfr/4.1.0/lib:/slurm/soft/gcc/gsl/lib:/slurm/soft/gcc/zlib/1.2.9/lib:/usr/local/cuda/lib64:
2024-03-07 10:39:30.701611: W tensorflow/core/common_runtime/gpu/gpu_device.cc:1934] Cannot dlopen some GPU libraries. Please make sure the missing libraries mentioned above are installed properly if you would like to use GPU. Follow the guide at Compatibilité avec les GPU  |  TensorFlow for how to download and setup the required libraries for your platform.
Skipping registering GPU devices…
2024-03-07 10:39:30.703683: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
Loading ImageNet-pretrained resnet_50
2024-03-07 10:39:31.318140: W tensorflow/core/common_runtime/gpu/gpu_device.cc:1934] Cannot dlopen some GPU libraries. Please make sure the missing libraries mentioned above are installed properly if you would like to use GPU. Follow the guide at Install TensorFlow with pip for how to download and setup the required libraries for your platform.
Skipping registering GPU devices…
2024-03-07 10:39:32.478029: I tensorflow/compiler/mlir/mlir_graph_optimization_pass.cc:354] MLIR V1 optimization pass is not enabled

Hi @Stella_Fun, The warning says you are using deprecated methods in your code.

with the warning I suspect there are no CUDA libraries installed in the environment so the program was unable to use the GPU. Thank You.