Ejemplo n.º 1
0
 def solve_via_data(self,
                    data,
                    warm_start,
                    verbose,
                    solver_opts,
                    solver_cache=None):
     from cvxpy.problems.solvers.gurobi_intf import GUROBI as GUROBI_OLD
     solver = GUROBI_OLD()
     solver_opts[s.BOOL_IDX] = data[s.BOOL_IDX]
     solver_opts[s.INT_IDX] = data[s.INT_IDX]
     return solver.solve(data["objective"], data["constraints"],
                         {self.name(): ProblemData()}, warm_start, verbose,
                         solver_opts)
Ejemplo n.º 2
0
from cvxpy.problems.solvers.gurobi_intf import GUROBI
from cvxpy.problems.solvers.elemental_intf import Elemental
from cvxpy.problems.solvers.mosek_intf import MOSEK
from cvxpy.problems.solvers.ls_intf import LS
from cvxpy.problems.solvers.julia_opt_intf import JuliaOpt
from cvxpy.problems.solvers.xpress_intf import XPRESS

solver_intf = [
    ECOS(),
    ECOS_BB(),
    CVXOPT(),
    GLPK(),
    GLPK_MI(),
    CBC(),
    SCS(),
    GUROBI(),
    Elemental(),
    MOSEK(),
    LS(),
    JuliaOpt(),
    XPRESS()
]
SOLVERS = {solver.name(): solver for solver in solver_intf}


def installed_solvers():
    """List the installed solvers.
    """
    installed = []
    for name, solver in SOLVERS.items():
        if solver.is_installed():
Ejemplo n.º 3
0
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with CVXPY.  If not, see <http://www.gnu.org/licenses/>.
"""

from cvxpy.problems.solvers.ecos_intf import ECOS
from cvxpy.problems.solvers.ecos_bb_intf import ECOS_BB
from cvxpy.problems.solvers.cvxopt_intf import CVXOPT
from cvxpy.problems.solvers.glpk_intf import GLPK
from cvxpy.problems.solvers.glpk_mi_intf import GLPK_MI
from cvxpy.problems.solvers.scs_intf import SCS
from cvxpy.problems.solvers.gurobi_intf import GUROBI
from cvxpy.problems.solvers.elemental_intf import Elemental
from cvxpy.problems.solvers.mosek_intf import MOSEK

solver_intf = [ECOS(), ECOS_BB(), CVXOPT(), GLPK(),
               GLPK_MI(), SCS(), GUROBI(), Elemental(), MOSEK()]
SOLVERS = {solver.name():solver for solver in solver_intf}

def installed_solvers():
    """List the installed solvers.
    """
    installed = []
    for name, solver in SOLVERS.items():
        if solver.is_installed():
            installed.append(name)
    return installed
Ejemplo n.º 4
0
limitations under the License.
"""

from cvxpy.problems.solvers.ecos_intf import ECOS
from cvxpy.problems.solvers.ecos_bb_intf import ECOS_BB
from cvxpy.problems.solvers.cvxopt_intf import CVXOPT
from cvxpy.problems.solvers.glpk_intf import GLPK
from cvxpy.problems.solvers.glpk_mi_intf import GLPK_MI
from cvxpy.problems.solvers.cbc_intf import CBC
from cvxpy.problems.solvers.scs_intf import SCS
from cvxpy.problems.solvers.gurobi_intf import GUROBI
from cvxpy.problems.solvers.elemental_intf import Elemental
from cvxpy.problems.solvers.mosek_intf import MOSEK
from cvxpy.problems.solvers.ls_intf import LS
from cvxpy.problems.solvers.julia_opt_intf import JuliaOpt

solver_intf = [ECOS(), ECOS_BB(), CVXOPT(), GLPK(),
               GLPK_MI(), CBC(), SCS(), GUROBI(),
               Elemental(), MOSEK(), LS(), JuliaOpt()]
SOLVERS = {solver.name(): solver for solver in solver_intf}


def installed_solvers():
    """List the installed solvers.
    """
    installed = []
    for name, solver in SOLVERS.items():
        if solver.is_installed():
            installed.append(name)
    return installed
Ejemplo n.º 5
0
CVXPY is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with CVXPY.  If not, see <http://www.gnu.org/licenses/>.
"""

from cvxpy.problems.solvers.ecos_intf import ECOS
from cvxpy.problems.solvers.ecos_bb_intf import ECOS_BB
from cvxpy.problems.solvers.cvxopt_intf import CVXOPT
from cvxpy.problems.solvers.glpk_intf import GLPK
from cvxpy.problems.solvers.glpk_mi_intf import GLPK_MI
from cvxpy.problems.solvers.scs_intf import SCS
from cvxpy.problems.solvers.gurobi_intf import GUROBI

solver_intf = [ECOS(), ECOS_BB(), CVXOPT(), GLPK(), GLPK_MI(), SCS(), GUROBI()]
SOLVERS = {solver.name(): solver for solver in solver_intf}


def installed_solvers():
    """List the installed solvers.
    """
    installed = []
    for name, solver in SOLVERS.items():
        if solver.is_installed():
            installed.append(name)
    return installed