<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _choice_format(self, occur):
 """Return the serialization format for a choice node."""
 
        middle = "%s" if self.rng_children() else "<empty/>%s"
        fmt = self.start_tag() + middle + self.end_tag()
        if self.occur != 2:
            return "<optional>" + fmt + "</optional>"
        else:
            return fmt