def serialize_to_xml(root, block):
root.tag = '<STR_LIT>'<EOL>if block.rationale_size is not None:<EOL><INDENT>if block.rationale_size.get('<STR_LIT>'):<EOL><INDENT>root.set('<STR_LIT>', unicode(block.rationale_size.get('<STR_LIT>')))<EOL><DEDENT>if block.rationale_size.get('<STR_LIT>'):<EOL><INDENT>root.set('<STR_LIT>', unicode(block.rationale_size['<STR_LIT>']))<EOL><DEDENT><DEDENT>if block.algo:<EOL><INDENT>if block.algo.get('<STR_LIT:name>'):<EOL><INDENT>root.set('<STR_LIT>', block.algo.get('<STR_LIT:name>'))<EOL><DEDENT>if block.algo.get('<STR_LIT>'):<EOL><INDENT>root.set('<STR_LIT>', unicode(block.algo.get('<STR_LIT>')))<EOL><DEDENT><DEDENT>display_name = etree.SubElement(root, '<STR_LIT>')<EOL>display_name.text = block.display_name<EOL>question = etree.SubElement(root, '<STR_LIT>')<EOL>question_text = etree.SubElement(question, '<STR_LIT:text>')<EOL>question_text.text = block.question_text['<STR_LIT:text>']<EOL>serialize_image(block.question_text, question)<EOL>options = etree.SubElement(root, '<STR_LIT>')<EOL>serialize_options(options, block)<EOL>seeds = etree.SubElement(root, '<STR_LIT>')<EOL>serialize_seeds(seeds, block)<EOL>
Serialize the Peer Instruction XBlock's content to XML.

Args:
    block (PeerInstructionXBlock): The peer instruction block to serialize.
    root (etree.Element): The XML root node to update.

Returns:
    etree.Element