(benchmark_id)
return supervised.training.EvalTask(
      eval_data(),
      metrics,
      metric_names=[f'{name_upper} accuracy',
                    f'{name_upper} sequence accuracy'])
Returns a T5 GLUE eval task, based on ``benchmark_id``.
Returns a T5 GLUE eval task, based on ``benchmark_id``.
Returns a T5 GLUE eval task based on benchmark_id .
def _T5GlueEvalTask(benchmark_id):
  """Returns a T5 GLUE eval task, based on ``benchmark_id``."""
  eval_data = T5GlueEvalStream(benchmark_id)
  benchmark_id = _ensure_eval_suffix(benchmark_id)
  metrics = [tl.WeightedCategoryAccuracy(), tl.SequenceAccuracy()]
  benchmark, split = benchmark_id.rsplit('_', 1)
  if benchmark == 'cola':
    name_upper = 'Cola'
  elif benchmark == 'mnli':
    name_upper = 'MNLI_matched' if split == 'e' else 'MNLI_mismatched'
  else:
    name_upper = benchmark.upper()
  return supervised.training.EvalTask(
      eval_data(),
      metrics,
      metric_names=[f'{name_upper} accuracy',
                    f'{name_upper} sequence accuracy'])
def _T5GlueEvalTask ( benchmark_id ) : eval_data = T5GlueEvalStream ( benchmark_id ) benchmark_id = _ensure_eval_suffix ( benchmark_id ) metrics = [ tl . WeightedCategoryAccuracy ( ) , tl . SequenceAccuracy ( ) ] benchmark , split = benchmark_id . rsplit ( '_' , 1 ) if benchmark == 'cola' : name_upper = 'Cola' elif benchmark == 'mnli' : name_upper = 'MNLI_matched' if split == 'e' else 'MNLI_mismatched' else : name_upper = benchmark . upper ( ) return supervised . training . EvalTask ( eval_data ( ) , metrics , metric_names = [ f'{name_upper} accuracy' , f'{name_upper} sequence accuracy' ] )