def METHOD_NAME(path):
  obj = tf.train.Checkpoint()
  @tf.function(input_signature=[tf.TensorSpec(None, dtype=tf.float32)])
  def plus_one(x):
    return x + 1
  obj.__call__ = plus_one
  tf.saved_model.save(obj, path)