@staticmethod<EOL><INDENT>def from_element(root, timezone):<DEDENT>
assert root.tag == '<STR_LIT>'<EOL>if root.xpath('<STR_LIT>'):<EOL><INDENT>return _ScheduleIntervals(root, timezone)<EOL><DEDENT>elif root.xpath('<STR_LIT>'):<EOL><INDENT>return _ScheduleRecurring(root, timezone)<EOL><DEDENT>raise NotImplementedError<EOL>
Return a Schedule object based on an lxml Element for the <schedule>
        tag. timezone is a tzinfo object, ideally from pytz.