<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _get_baremetal_switches(self, port):
 """Get switch ip addresses from baremetal transaction. This method is used to extract switch information from the transaction where VNIC_TYPE is baremetal. :param port: Received port transaction :returns: list of all switches :returns: list of only switches which are active """


        all_switches = set()
        active_switches = set()
        all_link_info = port[bc.portbindings.PROFILE]['local_link_information']
        for link_info in all_link_info:
            switch_info = self._get_baremetal_switch_info(link_info)
            if not switch_info:
                continue
            switch_ip = switch_info['switch_ip']

            # If not for Nexus
            if not self._switch_defined(switch_ip):
                continue

            all_switches.add(switch_ip)
            if self.is_switch_active(switch_ip):
                active_switches.add(switch_ip)

        return list(all_switches), list(active_switches)