tensorflow_model_analysis/eval_saved_model/example_trainers/fixed_prediction_estimator.py [43:62]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    del config
    predictions = features['prediction']

    if output_prediction_key is not None:
      predictions_dict = {
          output_prediction_key: predictions,
      }
    else:
      # For simulating Estimators which don't return a predictions dict in
      # EVAL mode.
      predictions_dict = {}

    if mode == tf.estimator.ModeKeys.PREDICT:
      return tf.estimator.EstimatorSpec(
          mode=mode,
          predictions=predictions_dict,
          export_outputs={
              tf.saved_model.DEFAULT_SERVING_SIGNATURE_DEF_KEY:
                  tf.estimator.export.RegressionOutput(predictions)
          })
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



tensorflow_model_analysis/eval_saved_model/example_trainers/fixed_prediction_estimator_no_labels.py [37:56]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    del config
    predictions = features['prediction']

    if output_prediction_key is not None:
      predictions_dict = {
          output_prediction_key: predictions,
      }
    else:
      # For simulating Estimators which don't return a predictions dict in
      # EVAL mode.
      predictions_dict = {}

    if mode == tf.estimator.ModeKeys.PREDICT:
      return tf.estimator.EstimatorSpec(
          mode=mode,
          predictions=predictions_dict,
          export_outputs={
              tf.saved_model.DEFAULT_SERVING_SIGNATURE_DEF_KEY:
                  tf.estimator.export.RegressionOutput(predictions)
          })
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



