From 7a46afb5123cf4ffbdff684e5b331f05497ff02e Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 16:31:53 +0200 Subject: [PATCH 01/18] pdlp objective tests added, other ctest disabled temporarily for dev --- check/CMakeLists.txt | 110 +++++++++++++++++++++++++++++-------------- 1 file changed, 74 insertions(+), 36 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index af5bd46f13..6d856fd405 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -137,11 +137,11 @@ if (NOT FAST_BUILD OR ALL_TESTS) RESOURCE_LOCK unittestbin) # create a binary running all the tests in the executable - add_test(NAME unit_tests_all COMMAND unit_tests --success) - set_tests_properties(unit_tests_all - PROPERTIES - DEPENDS unit-test-build) - set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) +# add_test(NAME unit_tests_all COMMAND unit_tests --success) +# set_tests_properties(unit_tests_all +# PROPERTIES +# DEPENDS unit-test-build) +# set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) # An individual test can be added with the command below but the approach # above with a single add_test for all the unit tests automatically detects all @@ -230,6 +230,22 @@ if (NOT FAST_BUILD OR ALL_TESTS) # "--parallel=on" ) + set(pdlpInstances + "25fv47\; 5.50184588\;" + "adlittle\; 2.254949631\;" + "afiro\;-4.64753143\;" + "avgas\;-7.749999999\;" + "blending\;-3.19999999\;" + "chip\;-9.000000001\;" + "e226\;-1.163892906\;" + "scrs8\; 9.042969540\;" + "sctest\; 5.749999936\;" + "shell\; 1.2088253460\;" + "stair\;-2.5126695353\;" + "standata\; 1.257699499\;" + "standgub\; 1.2576994998\;" + ) + # define a macro to add tests # # add_instancetests takes an instance group and a status @@ -284,42 +300,64 @@ if (NOT FAST_BUILD OR ALL_TESTS) endforeach(instance) endmacro(add_instancetests) - # add tests for success and fail instances - if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) - add_instancetests(successMacArmInstances "Optimal") - else() - add_instancetests(successInstances "Optimal") - endif() +# # add tests for success and fail instances +# if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) +# add_instancetests(successMacArmInstances "Optimal") +# else() +# add_instancetests(successInstances "Optimal") +# endif() - add_instancetests(failInstances "Fail") - add_instancetests(infeasibleInstances "Infeasible") - #add_instancetests(unboundedInstances "Unbounded") +# add_instancetests(failInstances "Fail") +# add_instancetests(infeasibleInstances "Infeasible") - foreach(instance ${mipInstances}) - list(GET instance 0 name) - list(GET instance 1 optval) - # specify the instance and the settings load command - set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") +# add_instancetests(unboundedInstances "Unbounded") - foreach(setting ${settings}) - if (FAST_BUILD) - add_test(NAME ${name}${setting} COMMAND $ ${setting} - --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) - else() - add_test(NAME ${name}${setting} COMMAND $ ${setting} - --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) - endif() - set_tests_properties (${name}${setting} PROPERTIES - DEPENDS unit_tests_all) +# foreach(instance ${mipInstances}) +# list(GET instance 0 name) +# list(GET instance 1 optval) +# # specify the instance and the settings load command +# set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") - set_tests_properties (${name}${setting} PROPERTIES - PASS_REGULAR_EXPRESSION - "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" - FAIL_REGULAR_EXPRESSION - "Solution status infeasible") +# foreach(setting ${settings}) +# if (FAST_BUILD) +# add_test(NAME ${name}${setting} COMMAND $ ${setting} +# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) +# else() +# add_test(NAME ${name}${setting} COMMAND $ ${setting} +# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) +# endif() - endforeach(setting) - endforeach() +# set_tests_properties (${name}${setting} PROPERTIES +# DEPENDS unit_tests_all) + +# set_tests_properties (${name}${setting} PROPERTIES +# PASS_REGULAR_EXPRESSION +# "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" +# FAIL_REGULAR_EXPRESSION +# "Solution status infeasible") + +# endforeach(setting) +# endforeach(instance) + + foreach(instance_pdlp ${pdlpInstances}) + # add default tests + # treat the instance as a tuple (list) of two values + list(GET instance_pdlp 0 name_pdlp) + list(GET instance_pdlp 1 optval) + + set(inst_pdlp "${HIGHS_SOURCE_DIR}/check/instances/${name_pdlp}.mps") + + add_test(NAME ${name_pdlp}--pdlp COMMAND $ "--solver=pdlp" + ${inst_pdlp}) + + set_tests_properties (${name_pdlp}--pdlp PROPERTIES + PASS_REGULAR_EXPRESSION + "Model status : Optimal") + + set_tests_properties (${name_pdlp}--pdlp PROPERTIES + PASS_REGULAR_EXPRESSION + "Objective value : ${optval}") + endforeach(instance_pdlp) endif() From f55afb366aff47c68ebe34d81e6e2a908b62e67f Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 17:20:15 +0200 Subject: [PATCH 02/18] disable pdlp tests with fast build off --- check/CMakeLists.txt | 40 +++++++++++++++++++++------------------- 1 file changed, 21 insertions(+), 19 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 6d856fd405..e714da4800 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -340,24 +340,26 @@ if (NOT FAST_BUILD OR ALL_TESTS) # endforeach(setting) # endforeach(instance) - foreach(instance_pdlp ${pdlpInstances}) - # add default tests - # treat the instance as a tuple (list) of two values - list(GET instance_pdlp 0 name_pdlp) - list(GET instance_pdlp 1 optval) - - set(inst_pdlp "${HIGHS_SOURCE_DIR}/check/instances/${name_pdlp}.mps") - - add_test(NAME ${name_pdlp}--pdlp COMMAND $ "--solver=pdlp" - ${inst_pdlp}) - - set_tests_properties (${name_pdlp}--pdlp PROPERTIES - PASS_REGULAR_EXPRESSION - "Model status : Optimal") - - set_tests_properties (${name_pdlp}--pdlp PROPERTIES - PASS_REGULAR_EXPRESSION - "Objective value : ${optval}") - endforeach(instance_pdlp) + if(FAST_BUILD) + foreach(instance_pdlp ${pdlpInstances}) + # add default tests + # treat the instance as a tuple (list) of two values + list(GET instance_pdlp 0 name_pdlp) + list(GET instance_pdlp 1 optval) + + set(inst_pdlp "${HIGHS_SOURCE_DIR}/check/instances/${name_pdlp}.mps") + + add_test(NAME ${name_pdlp}--pdlp COMMAND $ "--solver=pdlp" + ${inst_pdlp}) + + set_tests_properties (${name_pdlp}--pdlp PROPERTIES + PASS_REGULAR_EXPRESSION + "Model status : Optimal") + + set_tests_properties (${name_pdlp}--pdlp PROPERTIES + PASS_REGULAR_EXPRESSION + "Objective value : ${optval}") + endforeach(instance_pdlp) + endif() endif() From 4c105fc4969698b5b3f6f4ed9d25f767cd5112bd Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 17:41:55 +0200 Subject: [PATCH 03/18] remove win and mac test(s) with large gap e00, modified mac arm objectives within tolerace --- check/CMakeLists.txt | 48 ++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index e714da4800..4a590df6c7 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -237,7 +237,6 @@ if (NOT FAST_BUILD OR ALL_TESTS) "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-9.000000001\;" - "e226\;-1.163892906\;" "scrs8\; 9.042969540\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" @@ -245,7 +244,30 @@ if (NOT FAST_BUILD OR ALL_TESTS) "standata\; 1.257699499\;" "standgub\; 1.2576994998\;" ) + + + if (UNIX) + # on windows model status is unknown, rel gap e00 + set(pdlpInstances ${pdlpInstances} "e226\;-1.163892906\;") + endif() + set(pdlpMacArmInstances + "25fv47\; 5.50184589\;" + "adlittle\; 2.254949631\;" + "afiro\;-4.64753143\;" + "avgas\;-7.749999999\;" + "blending\;-3.19999999\;" + "chip\;-8.9999988715\;" + "e226\;-1.163892890 \;" + "scrs8\; 9.042969540\;" + "sctest\; 5.749999936\;" + "shell\; 1.2088253460\;" + # "stair\;-2.5126695353\;" + # "standata\; 1.257699499\;" #model status unknown, rel gap e00 + # "standgub\; 1.2576994998\;" + ) + + # define a macro to add tests # # add_instancetests takes an instance group and a status @@ -340,7 +362,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) # endforeach(setting) # endforeach(instance) - if(FAST_BUILD) + if(FAST_BUILD AND NOT APPLE) foreach(instance_pdlp ${pdlpInstances}) # add default tests # treat the instance as a tuple (list) of two values @@ -362,4 +384,26 @@ if (NOT FAST_BUILD OR ALL_TESTS) endforeach(instance_pdlp) endif() + if (FAST BUILD AND APPLE) + foreach(instance_pdlp ${pdlpMacArmInstances}) + # add default tests + # treat the instance as a tuple (list) of two values + list(GET instance_pdlp 0 name_pdlp) + list(GET instance_pdlp 1 optval) + + set(inst_pdlp "${HIGHS_SOURCE_DIR}/check/instances/${name_pdlp}.mps") + + add_test(NAME ${name_pdlp}--pdlp COMMAND $ "--solver=pdlp" + ${inst_pdlp}) + + set_tests_properties (${name_pdlp}--pdlp PROPERTIES + PASS_REGULAR_EXPRESSION + "Model status : Optimal") + + set_tests_properties (${name_pdlp}--pdlp PROPERTIES + PASS_REGULAR_EXPRESSION + "Objective value : ${optval}") + endforeach(instance_pdlp) + endif() + endif() From ac1eb6132571debf8867d112de856c8a703b3d75 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 17:51:32 +0200 Subject: [PATCH 04/18] fix typo in test condition --- check/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 4a590df6c7..c1d0c5ffc5 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -384,7 +384,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) endforeach(instance_pdlp) endif() - if (FAST BUILD AND APPLE) + if (FAST_BUILD AND APPLE) foreach(instance_pdlp ${pdlpMacArmInstances}) # add default tests # treat the instance as a tuple (list) of two values From 8da68d1aedc016ab5844908ad9f57aeef293ef6f Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 17:58:21 +0200 Subject: [PATCH 05/18] instance lists pdlp --- check/CMakeLists.txt | 53 +++++++++++++++++++++++++++----------------- 1 file changed, 33 insertions(+), 20 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index c1d0c5ffc5..531308443c 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -230,27 +230,40 @@ if (NOT FAST_BUILD OR ALL_TESTS) # "--parallel=on" ) - set(pdlpInstances - "25fv47\; 5.50184588\;" - "adlittle\; 2.254949631\;" - "afiro\;-4.64753143\;" - "avgas\;-7.749999999\;" - "blending\;-3.19999999\;" - "chip\;-9.000000001\;" - "scrs8\; 9.042969540\;" - "sctest\; 5.749999936\;" - "shell\; 1.2088253460\;" - "stair\;-2.5126695353\;" - "standata\; 1.257699499\;" - "standgub\; 1.2576994998\;" - ) - - - if (UNIX) - # on windows model status is unknown, rel gap e00 - set(pdlpInstances ${pdlpInstances} "e226\;-1.163892906\;") + if (UNIX AND NOT APPLE) + set(pdlpInstances + "25fv47\; 5.50184588\;" + "adlittle\; 2.254949631\;" + "afiro\;-4.64753143\;" + "avgas\;-7.749999999\;" + "blending\;-3.19999999\;" + "chip\;-9.000000001\;" + "e226\;-1.163892906\;" + "scrs8\; 9.042969540\;" + "sctest\; 5.749999936\;" + "shell\; 1.2088253460\;" + "stair\;-2.5126695353\;" + "standata\; 1.257699499\;" + "standgub\; 1.2576994998\;" + ) + elseif(WIN32) + # on windows e226 model status is unknown, rel gap e00 + set(pdlpInstances + "25fv47\; 5.50184588\;" + "adlittle\; 2.254949631\;" + "afiro\;-4.64753143\;" + "avgas\;-7.749999999\;" + "blending\;-3.19999999\;" + "chip\;-9.000000001\;" + "scrs8\; 9.042969540\;" + "sctest\; 5.749999936\;" + "shell\; 1.2088253460\;" + "stair\;-2.5126695353\;" + "standata\; 1.257699499\;" + "standgub\; 1.2576994998\;" + ) endif() - + set(pdlpMacArmInstances "25fv47\; 5.50184589\;" "adlittle\; 2.254949631\;" From a462f99a5099e99b82f05ba9468de1ebb4d5155e Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 18:14:49 +0200 Subject: [PATCH 06/18] e226 macos adjust objective --- check/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 531308443c..c69eab457a 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -271,7 +271,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-8.9999988715\;" - "e226\;-1.163892890 \;" + "e226\;-1.163892910 \;" "scrs8\; 9.042969540\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" From 2d1e7272a54ba7dbfba3e9794d4638b8361d1adc Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 18:38:10 +0200 Subject: [PATCH 07/18] remove whitespace --- check/CMakeLists.txt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index c69eab457a..fdaf00910a 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -263,7 +263,8 @@ if (NOT FAST_BUILD OR ALL_TESTS) "standgub\; 1.2576994998\;" ) endif() - + 1.1638929103e + 163892910 set(pdlpMacArmInstances "25fv47\; 5.50184589\;" "adlittle\; 2.254949631\;" @@ -271,7 +272,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-8.9999988715\;" - "e226\;-1.163892910 \;" + "e226\;-1.163892910\;" "scrs8\; 9.042969540\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" From fe4dcdf5c7efc81e0be3ab38a035c0bd53e202ba Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Mon, 28 Oct 2024 19:08:35 +0200 Subject: [PATCH 08/18] clean up --- check/CMakeLists.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index fdaf00910a..356cfd9f6f 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -263,8 +263,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) "standgub\; 1.2576994998\;" ) endif() - 1.1638929103e - 163892910 + set(pdlpMacArmInstances "25fv47\; 5.50184589\;" "adlittle\; 2.254949631\;" From e93d20cbd0db55942c00ac989f0b8699977ee468 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Tue, 29 Oct 2024 10:57:45 +0200 Subject: [PATCH 09/18] enable all tests --- check/CMakeLists.txt | 89 ++++++++++++++++++++++---------------------- 1 file changed, 44 insertions(+), 45 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 356cfd9f6f..a8255c74db 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -137,11 +137,11 @@ if (NOT FAST_BUILD OR ALL_TESTS) RESOURCE_LOCK unittestbin) # create a binary running all the tests in the executable -# add_test(NAME unit_tests_all COMMAND unit_tests --success) -# set_tests_properties(unit_tests_all -# PROPERTIES -# DEPENDS unit-test-build) -# set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) + add_test(NAME unit_tests_all COMMAND unit_tests --success) + set_tests_properties(unit_tests_all + PROPERTIES + DEPENDS unit-test-build) + set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) # An individual test can be added with the command below but the approach # above with a single add_test for all the unit tests automatically detects all @@ -263,7 +263,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) "standgub\; 1.2576994998\;" ) endif() - + set(pdlpMacArmInstances "25fv47\; 5.50184589\;" "adlittle\; 2.254949631\;" @@ -335,45 +335,44 @@ if (NOT FAST_BUILD OR ALL_TESTS) endforeach(instance) endmacro(add_instancetests) -# # add tests for success and fail instances -# if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) -# add_instancetests(successMacArmInstances "Optimal") -# else() -# add_instancetests(successInstances "Optimal") -# endif() - -# add_instancetests(failInstances "Fail") -# add_instancetests(infeasibleInstances "Infeasible") - -# add_instancetests(unboundedInstances "Unbounded") - - -# foreach(instance ${mipInstances}) -# list(GET instance 0 name) -# list(GET instance 1 optval) -# # specify the instance and the settings load command -# set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") - -# foreach(setting ${settings}) -# if (FAST_BUILD) -# add_test(NAME ${name}${setting} COMMAND $ ${setting} -# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) -# else() -# add_test(NAME ${name}${setting} COMMAND $ ${setting} -# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) -# endif() - -# set_tests_properties (${name}${setting} PROPERTIES -# DEPENDS unit_tests_all) - -# set_tests_properties (${name}${setting} PROPERTIES -# PASS_REGULAR_EXPRESSION -# "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" -# FAIL_REGULAR_EXPRESSION -# "Solution status infeasible") - -# endforeach(setting) -# endforeach(instance) + # add tests for success and fail instances + if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) + add_instancetests(successMacArmInstances "Optimal") + else() + add_instancetests(successInstances "Optimal") + endif() + + add_instancetests(failInstances "Fail") + add_instancetests(infeasibleInstances "Infeasible") + add_instancetests(unboundedInstances "Unbounded") + + + foreach(instance ${mipInstances}) + list(GET instance 0 name) + list(GET instance 1 optval) + # specify the instance and the settings load command + set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") + + foreach(setting ${settings}) + if (FAST_BUILD) + add_test(NAME ${name}${setting} COMMAND $ ${setting} + --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) + else() + add_test(NAME ${name}${setting} COMMAND $ ${setting} + --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) + endif() + + set_tests_properties (${name}${setting} PROPERTIES + DEPENDS unit_tests_all) + + set_tests_properties (${name}${setting} PROPERTIES + PASS_REGULAR_EXPRESSION + "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" + FAIL_REGULAR_EXPRESSION + "Solution status infeasible") + + endforeach(setting) + endforeach(instance) if(FAST_BUILD AND NOT APPLE) foreach(instance_pdlp ${pdlpInstances}) From 1fc5cc4447a2724308609a9b18a1bf70117b96d9 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Tue, 29 Oct 2024 11:00:44 +0200 Subject: [PATCH 10/18] mac arm release and debug tolerance --- check/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index a8255c74db..33257ee012 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -271,7 +271,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-8.9999988715\;" - "e226\;-1.163892910\;" + "e226\;-1.1638929\;" "scrs8\; 9.042969540\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" From b6b31dbd1ca92fda575e9c8c035521c8d399dee3 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Tue, 29 Oct 2024 11:55:06 +0200 Subject: [PATCH 11/18] tolerance --- check/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 33257ee012..f64635b12f 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -271,7 +271,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-8.9999988715\;" - "e226\;-1.1638929\;" + "e226\;-1.163892\;" "scrs8\; 9.042969540\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" From e32f7dddba69ceffaa9884fb07680ef2ad3349dc Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Tue, 29 Oct 2024 19:57:58 +0200 Subject: [PATCH 12/18] presolve off for pdlp tests --- check/CMakeLists.txt | 64 +++++++++++++++----------------------------- 1 file changed, 21 insertions(+), 43 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index f64635b12f..a0617aac79 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -262,23 +262,23 @@ if (NOT FAST_BUILD OR ALL_TESTS) "standata\; 1.257699499\;" "standgub\; 1.2576994998\;" ) - endif() - - set(pdlpMacArmInstances - "25fv47\; 5.50184589\;" - "adlittle\; 2.254949631\;" - "afiro\;-4.64753143\;" - "avgas\;-7.749999999\;" - "blending\;-3.19999999\;" - "chip\;-8.9999988715\;" - "e226\;-1.163892\;" - "scrs8\; 9.042969540\;" - "sctest\; 5.749999936\;" - "shell\; 1.2088253460\;" - # "stair\;-2.5126695353\;" - # "standata\; 1.257699499\;" #model status unknown, rel gap e00 - # "standgub\; 1.2576994998\;" + elseif(APPLE) + set(pdlpInstances + "25fv47\; 5.50184589\;" + "adlittle\; 2.254949631\;" + "afiro\;-4.64753143\;" + "avgas\;-7.749999999\;" + "blending\;-3.19999999\;" + "chip\;-8.9999988715\;" + "e226\;-1.163892\;" + "scrs8\; 9.042969540\;" + "sctest\; 5.749999936\;" + "shell\; 1.2088253460\;" + # "stair\;-2.5126695353\;" + # "standata\; 1.257699499\;" #model status unknown, rel gap e00 + # "standgub\; 1.2576994998\;" ) + endif() # define a macro to add tests @@ -374,7 +374,7 @@ if (NOT FAST_BUILD OR ALL_TESTS) endforeach(setting) endforeach(instance) - if(FAST_BUILD AND NOT APPLE) + if(FAST_BUILD) foreach(instance_pdlp ${pdlpInstances}) # add default tests # treat the instance as a tuple (list) of two values @@ -383,36 +383,14 @@ if (NOT FAST_BUILD OR ALL_TESTS) set(inst_pdlp "${HIGHS_SOURCE_DIR}/check/instances/${name_pdlp}.mps") - add_test(NAME ${name_pdlp}--pdlp COMMAND $ "--solver=pdlp" - ${inst_pdlp}) - - set_tests_properties (${name_pdlp}--pdlp PROPERTIES - PASS_REGULAR_EXPRESSION - "Model status : Optimal") - - set_tests_properties (${name_pdlp}--pdlp PROPERTIES - PASS_REGULAR_EXPRESSION - "Objective value : ${optval}") - endforeach(instance_pdlp) - endif() - - if (FAST_BUILD AND APPLE) - foreach(instance_pdlp ${pdlpMacArmInstances}) - # add default tests - # treat the instance as a tuple (list) of two values - list(GET instance_pdlp 0 name_pdlp) - list(GET instance_pdlp 1 optval) - - set(inst_pdlp "${HIGHS_SOURCE_DIR}/check/instances/${name_pdlp}.mps") - - add_test(NAME ${name_pdlp}--pdlp COMMAND $ "--solver=pdlp" - ${inst_pdlp}) + add_test(NAME ${name_pdlp}-pdlp-no-presolve COMMAND $ "--solver=pdlp" + "--presolve=off" ${inst_pdlp}) - set_tests_properties (${name_pdlp}--pdlp PROPERTIES + set_tests_properties (${name_pdlp}-pdlp-no-presolve PROPERTIES PASS_REGULAR_EXPRESSION "Model status : Optimal") - set_tests_properties (${name_pdlp}--pdlp PROPERTIES + set_tests_properties (${name_pdlp}-pdlp-no-presolve PROPERTIES PASS_REGULAR_EXPRESSION "Objective value : ${optval}") endforeach(instance_pdlp) From 5a50653395bbbda23bf480bd7293d4fee1b2027b Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Wed, 30 Oct 2024 16:15:09 +0200 Subject: [PATCH 13/18] values linux --- check/CMakeLists.txt | 96 ++++++++++++++++++++++---------------------- 1 file changed, 48 insertions(+), 48 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index a0617aac79..2ed6b6bac5 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -137,11 +137,11 @@ if (NOT FAST_BUILD OR ALL_TESTS) RESOURCE_LOCK unittestbin) # create a binary running all the tests in the executable - add_test(NAME unit_tests_all COMMAND unit_tests --success) - set_tests_properties(unit_tests_all - PROPERTIES - DEPENDS unit-test-build) - set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) +# add_test(NAME unit_tests_all COMMAND unit_tests --success) +# set_tests_properties(unit_tests_all +# PROPERTIES +# DEPENDS unit-test-build) +# set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) # An individual test can be added with the command below but the approach # above with a single add_test for all the unit tests automatically detects all @@ -234,17 +234,17 @@ if (NOT FAST_BUILD OR ALL_TESTS) set(pdlpInstances "25fv47\; 5.50184588\;" "adlittle\; 2.254949631\;" - "afiro\;-4.64753143\;" + "afiro\;-4.64753142\;" "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-9.000000001\;" - "e226\;-1.163892906\;" - "scrs8\; 9.042969540\;" + "e226\;-1.16389293\;" + "scrs8\; 9.042969511\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" - "stair\;-2.5126695353\;" + "stair\;-2.51266951\;" "standata\; 1.257699499\;" - "standgub\; 1.2576994998\;" + "standgub\; 1.25769949\;" ) elseif(WIN32) # on windows e226 model status is unknown, rel gap e00 @@ -335,44 +335,44 @@ if (NOT FAST_BUILD OR ALL_TESTS) endforeach(instance) endmacro(add_instancetests) - # add tests for success and fail instances - if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) - add_instancetests(successMacArmInstances "Optimal") - else() - add_instancetests(successInstances "Optimal") - endif() - - add_instancetests(failInstances "Fail") - add_instancetests(infeasibleInstances "Infeasible") - add_instancetests(unboundedInstances "Unbounded") - - - foreach(instance ${mipInstances}) - list(GET instance 0 name) - list(GET instance 1 optval) - # specify the instance and the settings load command - set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") - - foreach(setting ${settings}) - if (FAST_BUILD) - add_test(NAME ${name}${setting} COMMAND $ ${setting} - --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) - else() - add_test(NAME ${name}${setting} COMMAND $ ${setting} - --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) - endif() - - set_tests_properties (${name}${setting} PROPERTIES - DEPENDS unit_tests_all) - - set_tests_properties (${name}${setting} PROPERTIES - PASS_REGULAR_EXPRESSION - "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" - FAIL_REGULAR_EXPRESSION - "Solution status infeasible") - - endforeach(setting) - endforeach(instance) +# # add tests for success and fail instances +# if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) +# add_instancetests(successMacArmInstances "Optimal") +# else() +# add_instancetests(successInstances "Optimal") +# endif() + +# add_instancetests(failInstances "Fail") +# add_instancetests(infeasibleInstances "Infeasible") +# add_instancetests(unboundedInstances "Unbounded") + + +# foreach(instance ${mipInstances}) +# list(GET instance 0 name) +# list(GET instance 1 optval) +# # specify the instance and the settings load command +# set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") + +# foreach(setting ${settings}) +# if (FAST_BUILD) +# add_test(NAME ${name}${setting} COMMAND $ ${setting} +# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) +# else() +# add_test(NAME ${name}${setting} COMMAND $ ${setting} +# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) +# endif() + +# set_tests_properties (${name}${setting} PROPERTIES +# DEPENDS unit_tests_all) + +# set_tests_properties (${name}${setting} PROPERTIES +# PASS_REGULAR_EXPRESSION +# "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" +# FAIL_REGULAR_EXPRESSION +# "Solution status infeasible") + +# endforeach(setting) +# endforeach(instance) if(FAST_BUILD) foreach(instance_pdlp ${pdlpInstances}) From c28d1ee7194ded22603e5f1954fb8aa854a38281 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Wed, 30 Oct 2024 16:29:26 +0200 Subject: [PATCH 14/18] values macos --- check/CMakeLists.txt | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 2ed6b6bac5..50666322c3 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -264,19 +264,19 @@ if (NOT FAST_BUILD OR ALL_TESTS) ) elseif(APPLE) set(pdlpInstances - "25fv47\; 5.50184589\;" - "adlittle\; 2.254949631\;" - "afiro\;-4.64753143\;" + "25fv47\; 5.5018458\;" + "adlittle\; 2.25494963\;" + "afiro\;-4.64753142\;" "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-8.9999988715\;" "e226\;-1.163892\;" - "scrs8\; 9.042969540\;" + "scrs8\; 9.04296953\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" - # "stair\;-2.5126695353\;" - # "standata\; 1.257699499\;" #model status unknown, rel gap e00 - # "standgub\; 1.2576994998\;" + "stair\;-2.5126695\;" + "standata\; 1.25769950\;" + "standgub\; 1.25769950\;" ) endif() From 53a1ebccdc26151ced3e5abdab566a4a4a96a1e6 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Wed, 30 Oct 2024 17:03:33 +0200 Subject: [PATCH 15/18] values windows --- check/CMakeLists.txt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 2ed6b6bac5..37f4714eb3 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -250,17 +250,17 @@ if (NOT FAST_BUILD OR ALL_TESTS) # on windows e226 model status is unknown, rel gap e00 set(pdlpInstances "25fv47\; 5.50184588\;" - "adlittle\; 2.254949631\;" - "afiro\;-4.64753143\;" + "adlittle\; 2.25494963\;" + "afiro\;-4.64753142\;" "avgas\;-7.749999999\;" "blending\;-3.19999999\;" "chip\;-9.000000001\;" - "scrs8\; 9.042969540\;" + "scrs8\; 9.0429695\;" "sctest\; 5.749999936\;" "shell\; 1.2088253460\;" - "stair\;-2.5126695353\;" - "standata\; 1.257699499\;" - "standgub\; 1.2576994998\;" + "stair\;-2.51266951\;" + "standata\; 1.2576995\;" + "standgub\; 1.2576995\;" ) elseif(APPLE) set(pdlpInstances From 5223fa5f9c743b468c51aab2729ebf03f991759d Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Wed, 30 Oct 2024 17:07:49 +0200 Subject: [PATCH 16/18] add windows test --- .github/workflows/build-windows.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml index f14d66e150..2c44134281 100644 --- a/.github/workflows/build-windows.yml +++ b/.github/workflows/build-windows.yml @@ -229,7 +229,7 @@ jobs: # Note the current convention is to use the -S and -B options here to specify source # and build directories, but this is only available with CMake 3.13 and higher. # The CMake binaries on the Github Actions machines are (as of this writing) 3.12 - run: cmake $GITHUB_WORKSPACE -DFAST_BUILD=OFF -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON + run: cmake $GITHUB_WORKSPACE-DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON - name: Build working-directory: ${{runner.workspace}}/build @@ -263,7 +263,7 @@ jobs: # Note the current convention is to use the -S and -B options here to specify source # and build directories, but this is only available with CMake 3.13 and higher. # The CMake binaries on the Github Actions machines are (as of this writing) 3.12 - run: cmake $GITHUB_WORKSPACE -DFAST_BUILD=OFF -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON + run: cmake $GITHUB_WORKSPACE -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON -DALL_TESTS=ON - name: Build working-directory: ${{runner.workspace}}/build From 9996d3cfa93ec003f33d90aac8f7955198e39cc3 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Wed, 30 Oct 2024 19:10:50 +0200 Subject: [PATCH 17/18] typo --- .github/workflows/build-windows.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml index 2c44134281..b2ddc66b08 100644 --- a/.github/workflows/build-windows.yml +++ b/.github/workflows/build-windows.yml @@ -229,7 +229,7 @@ jobs: # Note the current convention is to use the -S and -B options here to specify source # and build directories, but this is only available with CMake 3.13 and higher. # The CMake binaries on the Github Actions machines are (as of this writing) 3.12 - run: cmake $GITHUB_WORKSPACE-DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON + run: cmake $GITHUB_WORKSPACE -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON - name: Build working-directory: ${{runner.workspace}}/build From 79ab774d3e1166cb63f52477349c0558a74cc2f8 Mon Sep 17 00:00:00 2001 From: Ivet Galabova Date: Wed, 30 Oct 2024 20:38:55 +0200 Subject: [PATCH 18/18] enable all tests --- check/CMakeLists.txt | 86 ++++++++++++++++++++++---------------------- 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/check/CMakeLists.txt b/check/CMakeLists.txt index 061be1c931..0fac3894aa 100644 --- a/check/CMakeLists.txt +++ b/check/CMakeLists.txt @@ -137,11 +137,11 @@ if (NOT FAST_BUILD OR ALL_TESTS) RESOURCE_LOCK unittestbin) # create a binary running all the tests in the executable -# add_test(NAME unit_tests_all COMMAND unit_tests --success) -# set_tests_properties(unit_tests_all -# PROPERTIES -# DEPENDS unit-test-build) -# set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) + add_test(NAME unit_tests_all COMMAND unit_tests --success) + set_tests_properties(unit_tests_all + PROPERTIES + DEPENDS unit-test-build) + set_tests_properties(unit_tests_all PROPERTIES TIMEOUT 10000) # An individual test can be added with the command below but the approach # above with a single add_test for all the unit tests automatically detects all @@ -335,44 +335,44 @@ if (NOT FAST_BUILD OR ALL_TESTS) endforeach(instance) endmacro(add_instancetests) -# # add tests for success and fail instances -# if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) -# add_instancetests(successMacArmInstances "Optimal") -# else() -# add_instancetests(successInstances "Optimal") -# endif() - -# add_instancetests(failInstances "Fail") -# add_instancetests(infeasibleInstances "Infeasible") -# add_instancetests(unboundedInstances "Unbounded") - - -# foreach(instance ${mipInstances}) -# list(GET instance 0 name) -# list(GET instance 1 optval) -# # specify the instance and the settings load command -# set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") - -# foreach(setting ${settings}) -# if (FAST_BUILD) -# add_test(NAME ${name}${setting} COMMAND $ ${setting} -# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) -# else() -# add_test(NAME ${name}${setting} COMMAND $ ${setting} -# --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) -# endif() - -# set_tests_properties (${name}${setting} PROPERTIES -# DEPENDS unit_tests_all) - -# set_tests_properties (${name}${setting} PROPERTIES -# PASS_REGULAR_EXPRESSION -# "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" -# FAIL_REGULAR_EXPRESSION -# "Solution status infeasible") - -# endforeach(setting) -# endforeach(instance) + # add tests for success and fail instances + if (APPLE AND (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "arm64")) + add_instancetests(successMacArmInstances "Optimal") + else() + add_instancetests(successInstances "Optimal") + endif() + + add_instancetests(failInstances "Fail") + add_instancetests(infeasibleInstances "Infeasible") + add_instancetests(unboundedInstances "Unbounded") + + + foreach(instance ${mipInstances}) + list(GET instance 0 name) + list(GET instance 1 optval) + # specify the instance and the settings load command + set(inst "${HIGHS_SOURCE_DIR}/check/instances/${name}.mps") + + foreach(setting ${settings}) + if (FAST_BUILD) + add_test(NAME ${name}${setting} COMMAND $ ${setting} + --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) + else() + add_test(NAME ${name}${setting} COMMAND $ ${setting} + --options_file ${CMAKE_BINARY_DIR}/testoptions.txt ${inst}) + endif() + + set_tests_properties (${name}${setting} PROPERTIES + DEPENDS unit_tests_all) + + set_tests_properties (${name}${setting} PROPERTIES + PASS_REGULAR_EXPRESSION + "Status Optimal\n Primal bound ${optval}.*\n Dual bound ${optval}.*\n Solution status feasible\n ${optval}.* \\(objective\\)" + FAIL_REGULAR_EXPRESSION + "Solution status infeasible") + + endforeach(setting) + endforeach(instance) if(FAST_BUILD) foreach(instance_pdlp ${pdlpInstances})