class_docstr: Sorting network class.
  
  From Wikipedia : A sorting network is an abstract mathematical model
  of a network of wires and comparator modules that is used to sort a
  sequence of numbers. Each comparator connects two wires and sort the
  values by outputting the smaller value to one wire, and a larger
  value to the other.
class_docstr_tok: ["Sorting","network","class",".","From","Wikipedia",":","A","sorting","network","is","an","abstract","mathematical","model","of","a","network","of","wires","and","comparator","modules","that","is","used","to","sort","a","sequence","of","numbers",".","Each","comparator","connects","two","wires","and","sort","the","values","by","outputting","the","smaller","value","to","one","wire",",","and","a","larger","value","to","the","other","."]
docstr: Add a connector between wire1 and wire2 in the network.
docstr_tok: ["Add","a","connector","between","wire1","and","wire2","in","the","network","."]
code: def addConnector(self, wire1, wire2):
      """Add a connector between wire1 and wire2 in the network."""
      if wire1 == wire2:
          return
  
      if wire1 > wire2:
          wire1, wire2 = wire2, wire1
  
      index = 0
      for level in reversed(self):
          if self.checkConflict(level, wire1, wire2):
              break
          index -= 1
  
      if index == 0:
          self.append([(wire1, wire2)])
      else:
          self[index].append((wire1, wire2))
  
file_path: deap/examples/ga/sortingnetwork.py
imports: from itertools import product
label_desc: Use image node_id 2 for calling the SortingNetwork obj's underlying member method code with example usage: obj.addConnector(wire1, wire2) without return types