AttributeError: module 'tensorflow_federated.python.learning' has no attribute 'from_keras_model'

I am currently working on a project involving TensorFlow Federated (TFF), and I’m facing an issue with the from_keras_model attribute in the tensorflow_federated.python.learning module. When I attempt to use this attribute, I encounter the following error:
AttributeError: module ‘tensorflow_federated.python.learning’ has no attribute ‘from_keras_model’
Environment:
Successfully installed colorama-0.4.6 dp-accounting-0.4.3 farmhashpy-0.4.0 google-vizier-0.1.11 grpcio-tools-1.59.0 immutabledict-2.2.5 jax-0.4.14 jaxlib-0.4.14 numpy-1.25.2 packaging-22.0 portalocker-2.8.2 portpicker-1.6.0 protobuf-4.24.4 sacrebleu-2.3.1 scipy-1.9.3 semantic-version-2.10.0 sentencepiece-0.1.99 seqeval-1.2.2 sqlalchemy-1.4.20
tensorflow-compression-2.14.0
tensorflow-federated-0.64.0
tensorflow-metadata-1.13.1 tensorflow-model-optimization-0.7.5
tensorflow-privacy-0.8.12
tensorflow-text-2.14.0

I am trying to create some client nodes so that I can place some datasets on each node for training and I want to use a federated learning approach. I am running this project on Google Colab and the error occurs when,

def create_federated_model() → tff.learning.models.VariableModel:
model = tf.keras.Sequential([
tf.keras.layers.Input(shape=(13,)), # Input layer for 13 features
tf.keras.layers.Dense(64, activation=‘relu’),
tf.keras.layers.Dense(32, activation=‘relu’),
tf.keras.layers.Dense(16, activation=‘relu’),
tf.keras.layers.Dense(1, activation=‘sigmoid’) # Output layer for binary classification
])

return tff.learning.from_keras_model(
    model,
    input_spec=tf.TensorSpec(shape=(None, 13), dtype=tf.float32),
    loss=tf.keras.losses.BinaryCrossentropy(),
    metrics=[tf.keras.metrics.BinaryAccuracy()]
)