          'invalid_choice': _('"{input}" is not a valid choice.')
      }
  
      def __init__(self, choices, **kwargs):
          # Allow either single or paired choices style:
          # choices = [1, 2, 3]
          # choices = [(1, 'First'), (2, 'Second'), (3, 'Third')]
          pairs = [
              isinstance(item, (list, tuple)) and len(item) == 2
              for item in choices
          ]
          if all(pairs):
              self.choices = OrderedDict([(key, display_value) for key, display_value in choices])
          else:
              self.choices = OrderedDict([(item, item) for item in choices])
  
          # Map the string representation of choices to the underlying value.
          # Allows us to deal with eg. integer choices while supporting either
          # integer or string input, but still get the correct datatype out.
          self.choice_strings_to_values = dict([
 
</s>
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
          'invalid_choice': _('"{input}" is not a valid choice.')
      }
  
      def __init__(self, choices, **kwargs):
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
        flat_choices = [self.flatten_choice(c) for c in choices]
        self.choices = OrderedDict(itertools.chain(*flat_choices))
  
          # Map the string representation of choices to the underlying value.
          # Allows us to deal with eg. integer choices while supporting either
          # integer or string input, but still get the correct datatype out.
          self.choice_strings_to_values = dict([
keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
 Add support for grouped choices.

This also adds support for mixing single and paired choices:
```
[
    ('poor', 'Poor quality'),
    'medium',
    ('good', 'Good quality'),
]
```
rest_framework/fields.py