code: def _get_keras_model(params):
      """Constructs and returns the model."""
      batch_size = params["batch_size"]
      user_input = tf.keras.layers.Input(
          shape=(1,), name=movielens.USER_COLUMN, dtype=tf.int32
      )
      item_input = tf.keras.layers.Input(
          shape=(1,), name=movielens.ITEM_COLUMN, dtype=tf.int32
      )
      valid_pt_mask_input = tf.keras.layers.Input(
          shape=(1,), name=rconst.VALID_POINT_MASK, dtype=tf.bool
      )
      dup_mask_input = tf.keras.layers.Input(
          shape=(1,), name=rconst.DUPLICATE_MASK, dtype=tf.int32
      )
      label_input = tf.keras.layers.Input(
          shape=(1,), name=rconst.TRAIN_LABEL_KEY, dtype=tf.bool
      )
      base_model = neumf_model.construct_model(
          user_input, item_input, params
      )
      logits = base_model.output
      zeros = tf.keras.layers.Lambda(lambda x: x * 0)(logits)
      softmax_logits = tf.keras.layers.concatenate(
          [zeros, logits], axis=-1
      )
      keras_model = tf.keras.Model(
          inputs={
              movielens.USER_COLUMN: user_input,
              movielens.ITEM_COLUMN: item_input,
              rconst.VALID_POINT_MASK: valid_pt_mask_input,
              rconst.DUPLICATE_MASK: dup_mask_input,
              rconst.TRAIN_LABEL_KEY: label_input,
          },
          outputs=softmax_logits,
      )
      keras_model.summary()
      return keras_model
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import json
  import yaml
  import os
  import sys
  import tensorflow
  from absl import app
  from absl import flags
  from absl import logging
  from os.path import expanduser
  from tensorflow_addons.optimizers import LazyAdam
  from utils.recommendation import constants
  from utils.recommendation import movielens
  from utils.recommendation import ncf_common
  from utils.recommendation import ncf_input_pipeline
  from utils.recommendation import neumf_model
  from utils.flags import core
  from utils.logs import logger
  from utils.logs import mlperf_helper
  from utils.misc import keras_utils
  from utils.misc import model_helpers
  from autodist import AutoDist
  from autodist.strategy.ps_strategy import PS
  from autodist.strategy.ps_lb_strategy import PSLoadBalancing
  from autodist.strategy.partitioned_ps_strategy import PartitionedPS
  from autodist.strategy.all_reduce_strategy import AllReduce
  from autodist.strategy.parallax_strategy import Parallax
label_desc: Use image node_id 1 for calling a global function with example usage: _get_keras_model(params) and returns: keras_model