X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=dunshire%2Fgames.py;h=51c97add2314a9de54f8bb7d76f56ac13d6a1dd9;hb=5a78134ba154ef2e4855b791d1bdb45f26bfdf57;hp=437b53336ab5791cbf010ff15aa5f78509ea57c0;hpb=e297d8d0471068f10d4953570047d6770ceeb7be;p=dunshire.git diff --git a/dunshire/games.py b/dunshire/games.py index 437b533..51c97ad 100644 --- a/dunshire/games.py +++ b/dunshire/games.py @@ -926,7 +926,7 @@ class SymmetricLinearGame: """ try: - opts = {'show_progress': options.VERBOSE} + opts = {'show_progress': False} soln_dict = solvers.conelp(self._c(), self._G(), self._h(), @@ -939,6 +939,7 @@ class SymmetricLinearGame: # Oops, CVXOPT tried to take the square root of a # negative number. Report some details about the game # rather than just the underlying CVXOPT crash. + printing.options['dformat'] = options.DEBUG_FLOAT_FORMAT raise PoorScalingException(self) else: raise error @@ -963,6 +964,7 @@ class SymmetricLinearGame: # that CVXOPT is convinced the problem is infeasible (and that # cannot happen). if soln_dict['status'] in ['primal infeasible', 'dual infeasible']: + printing.options['dformat'] = options.DEBUG_FLOAT_FORMAT raise GameUnsolvableException(self, soln_dict) # The "optimal" and "unknown" results, we actually treat the @@ -976,11 +978,13 @@ class SymmetricLinearGame: # it) because otherwise CVXOPT might return "unknown" and give # us two points in the cone that are nowhere near optimal. if abs(p1_value - p2_value) > 2*options.ABS_TOL: + printing.options['dformat'] = options.DEBUG_FLOAT_FORMAT raise GameUnsolvableException(self, soln_dict) # And we also check that the points it gave us belong to the # cone, just in case... if (p1_optimal not in self._K) or (p2_optimal not in self._K): + printing.options['dformat'] = options.DEBUG_FLOAT_FORMAT raise GameUnsolvableException(self, soln_dict) # For the game value, we could use any of: