SuppressInfeasibleWarning

(class from pyomo.contrib.gdpopt.util)

class pyomo.contrib.gdpopt.util.SuppressInfeasibleWarning[source]

Bases: object

Suppress the infeasible model warning message from solve().

The “WARNING: Loading a SolverResults object with a warning status” warning message from calling solve() is often unwanted, but there is no clear way to suppress it.

This is modeled on LoggingIntercept from pyomo.common.log, but different in function.

__init__()

Methods

__init__()

Attributes

warning_filter

Member Documentation

class InfeasibleWarningFilter(name='')[source]

Bases: Filter

filter(record)[source]

Determine if the specified record is to be logged.

Returns True if the record should be logged, or False otherwise. If deemed appropriate, the record may be modified in-place.