CuPDLPx.jl

version

Julia interface for cuPDLPx.

Installation

CuPDLPx.jl is available from the Julia General registry:

pkg> add CuPDLPx

Use with JuMP

To use CuPDLPx with JuMP, use CuPDLPx.Optimizer:

using JuMP, CuPDLPx
model = Model(CuPDLPx.Optimizer)

Setting solver parameters

CuPDLPx.jl supports setting solver parameters via set_optimizer_attribute.

using JuMP
using CuPDLPx

model = read_from_file("2club200v15p5scn.mps.gz")
undo = relax_integrality(model)

println("Read MPS succeed.")
set_optimizer(model, CuPDLPx.Optimizer)

set_optimizer_attribute(model, "verbose", true)
set_optimizer_attribute(model, "l_inf_ruiz_iterations", 0)
set_optimizer_attribute(model, "iteration_limit", 200)

optimize!(model)
println(solution_summary(model))

Supported parameters

All of the following attributes are supported.

1. Termination criteria

NameTypeDefaultDescription
eps_optimal_relativeFloat641e-4Relative tolerance for optimality gap.
eps_feasible_relativeFloat641e-4Relative tolerance for primal and dual feasibility.
eps_feas_polish_relativeFloat641e-6Relative tolerance used during the polishing phase.
time_sec_limitFloat643600.0Maximum runtime allowed in seconds.
iteration_limitInt322147483647Maximum number of iterations.
optimality_normnorm_type_tNORM_TYPE_L2Norm used to measure residuals: NORM_TYPE_L2 (0) or NORM_TYPE_L_INF (1).
termination_evaluation_frequencyInt200Frequency (in iterations) at which to check termination criteria.

2. Algorithm and Preconditioning

NameTypeDefaultDescription
presolveBooltrueWhether to enable the PSLP presolver.
l_inf_ruiz_iterationsInt10Number of Ruiz rescaling iterations.
has_pock_chambolle_alphaBooltrueWhether to use Pock-Chambolle rescaling.
pock_chambolle_alphaFloat641.0$\alpha$ used in Pock-Chambolle rescaling.
bound_objective_rescalingBooltrueWhether to use objective and bound rescaling.
reflection_coefficientFloat641.0Reflection coefficient (typically in $[0, 1]$).
feasibility_polishingBoolfalseWheather to perform post-solve feasibility polishing.
sv_max_iterInt5000Maximum iterations for singular value estimation.
sv_tolFloat641e-4Tolerance for singular value estimation.
verboseBoolfalseWhether to enable console output and progress logging.

3. Adaptive Restart and Primal Weight

NameTypeDefaultDescription
artificial_restart_thresholdFloat640.36Threshold for triggering a forced "artificial" restart (based on iterations).
sufficient_reduction_for_restartFloat640.2Threshold for sufficient decay in fixed-point error to trigger a restart.
necessary_reduction_for_restartFloat640.8Threshold for necessary decay in fixed-point error to trigger a restart.
k_pFloat640.99Proportional gain for the primal weight (PID) controller.
k_iFloat640.01Integral gain for the primal weight (PID) controller.
k_dFloat640.0Derivative gain for the primal weight (PID) controller.
i_smoothFloat640.3Smoothing factor for the integral component of the controller.