'Performs setup for the initial rendering of the problem.
`self.html_input_type` determines whether this problem is displayed
with radiobuttons or checkboxes
If the initial value of `self.value` is \'\' change it to {} so that
the template has an empty dictionary to work with.
sets the value of self.choices to be equal to the return value of
`self.extract_choices`'

def setup(self):

    self.text_input_values = {}
    if (self.tag == 'radiotextgroup'):
        self.html_input_type = 'radio'
    elif (self.tag == 'checkboxtextgroup'):
        self.html_input_type = 'checkbox'
    else:
        _ = self.capa_system.i18n.ugettext
        msg = _('{input_type}:    unexpected    tag    {tag_name}').format(input_type='ChoiceTextGroup', tag_name=self.tag)
        raise Exception(msg)
    if (self.value == ''):
        self.value = {}
    self.choices = self.extract_choices(self.xml, self.capa_system.i18n)
