          btngen = ttk.Button(actframe,
                              text="Generate",
                              width=10,
                              command=lambda: tk_vars["generate"].set(var_value))
          btngen.pack(side=tk.RIGHT, padx=5)
          Tooltip(btngen,
                  text="Output command line options to the console",
                  wraplength=200)
          logger.debug("Added action buttons: '%s'", self.title)
  
 
</s> remove                 child.kill()
            _, alive = psutil.wait_procs(alive, timeout=10)
            if not alive:
                logger.debug("Killed")
                print("Killed")
            else:
                for child in alive:
                    msg = "Process {} survived SIGKILL. Giving up".format(child)
                    logger.debug(msg)
                    print(msg)
 </s> add                 msg = "Process {} survived SIGKILL. Giving up".format(child)
                logger.debug(msg)
                print(msg) </s> remove             try:
 </s> add             if os.name == "nt":
                try:
                    logger.debug("Sending carriage return to process")
                    self.process.communicate(input="\n", timeout=timeout)
                except TimeoutExpired:
                    logger.error("Timeout reached sending Exit Signal")
                    self.terminate_all_children()
            else:
                logger.debug("Sending SIGINT to process") </s> remove                 if os.name == "nt":
                    try:
                        logger.debug("Sending carriage return to process")
                        self.process.communicate(input="\n", timeout=60)
                    except TimeoutExpired:
                        raise ValueError("Timeout reached sending Exit Signal")
                else:
                    logger.debug("Sending SIGINT to process")
                    self.process.send_signal(signal.SIGINT)
                    while True:
                        timeelapsed = time() - now
                        if self.process.poll() is not None:
                            break
                        if timeelapsed > 60:
                            raise ValueError("Timeout reached sending Exit Signal")
 </s> add                 self.process.send_signal(signal.SIGINT)
                while True:
                    timeelapsed = time() - now
                    if self.process.poll() is not None:
                        break
                    if timeelapsed > timeout:
                        logger.error("Timeout reached sending Exit Signal")
                        self.terminate_all_children()
        btngen.pack(side=tk.LEFT, padx=5)
        if self.command == "train":
            self.add_timeout(actframe)
          btngen = ttk.Button(actframe,
                              text="Generate",
                              width=10,
                              command=lambda: tk_vars["generate"].set(var_value))
        btngen.pack(side=tk.LEFT, padx=5)
        if self.command == "train":
            self.add_timeout(actframe)
          Tooltip(btngen,
                  text="Output command line options to the console",
                  wraplength=200)
          logger.debug("Added action buttons: '%s'", self.title)
  
keep keep keep keep replace keep keep keep keep keep
 Add timeout slider to train tab. Terminate properly on timeout 
lib/gui/command.py