def select_data_file(self, button): data_path = button.get_file().get_path() reader = DataReader() reader.load(data_path) description = reader.get_description() self.dataset_desciption.set_text(description) self._cities = reader.get_cities() self.map.draw_cities(self._cities) self._cost_map = CostMap(self._cities) if self._alg_thread: self._pause = True self._alg_thread.join() self._alg_thread = None