def measurement_ids_and_names(experiment_proto):
  """List all measurement IDs and names for an experiment.

  Results are sorted by measurement ID.

  Args:
    experiment_proto: selection_pb2.Experiment describing the experiment.

  Returns:
    measurement_ids: tuple of integer IDs for each measurement.
    column_names: tuple of string names correpsonding to each measurement ID.
  """
  pairs = []
  for round_proto in experiment_proto.rounds.values():
    for reads in [round_proto.positive_reads, round_proto.negative_reads]:
      if reads.name:
        pairs.append((reads.measurement_id, reads.name))
  for binding_array in experiment_proto.binding_arrays:
    if binding_array.name:
      pairs.append((binding_array.measurement_id, binding_array.name))
  if pairs:
    measurement_ids, column_names = list(zip(*sorted(pairs)))
    return measurement_ids, column_names
  else:
    return None, None