This commit is contained in:
UmbertoJr 2019-10-31 16:19:43 +01:00
parent 0af91eac3c
commit b0590b4d62
1 changed files with 2 additions and 2 deletions

View File

@ -17,13 +17,13 @@ class Solver_TSP:
def __call__(self, instance_, verbose=True, return_value=True):
self.instance = instance_
if verbose:
print(f"### solving with {self.method}####")
print(f"### solving with {self.method} ####")
self.solution = self.available_methods[self.method](instance_)
assert self.check_if_solution_is_valid(self.solution), "Error the solution is not valid"
self.evaluate_solution()
self._gap()
if verbose:
print(f"### solution found with {self.gap} ####")
print(f"### solution found with {self.gap} % gap ####")
self._gap()
if return_value:
return self.solution