<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _load_codes(self, tag, ssh=False):
 """Extracts all the paths to additional code directories to be considered. :arg tag: the ET tag for the <codes> element."""

        codes = []
        for code in tag:
            if code.tag == "trunk":
                codes.append(code.attrib["value"])
        
        if ssh == False:
            self._vardict["codes"] = codes
        else:
            self._vardict["ssh.codes"] = codes