C2-W1 getting Unresolved reference error while importing pad_sequences

im trying to import pad_sequences using: from tensorflow.keras.preprocessing.sequence import pad_sequences

in intellij iDE, but im getting this error:Unresolved reference ‘pad_sequences’

similarly issue with from tensorflow.keras.metrics import Accuracy(Cannot find reference ‘Accuracy’ in ‘metrics.pyi’ ) & from tensorflow.keras.callbacks import EarlyStopping(Unresolved reference)

please help me with this, i have tried changing the way the import has been written, re installed tensorflow as well, tried using different versions of python(3.10,3.11,3.12) as well, keep getting the same error

The labs make use of tensorflow 2.7 which uses a different location for pad_sequences than the one present in the latest version i.e. 2.15. Follow the same line of thought for resolving Accuracy.