code: def translate(self, by):
          
          new_positions = _translate(self.xyz_with_ports, by)
          self.xyz_with_ports = new_positions
docs: Translate the Compound by a vector
  
          Parameters
          ----------
          by : np.ndarray, shape=(3,), dtype=float