Skip to content

Commit 5b59dc4

Browse files
committed
Add tests for multiplexing with sensitivities (#419)
1 parent 006499a commit 5b59dc4

5 files changed

+6303
-0
lines changed

test/GeneralRateModel.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,17 @@ TEST_CASE("GRM numerical Benchmark with parameter sensitivities for linear case"
7575
cadet::test::column::testReferenceBenchmark(modelFilePath, refFilePath, "001", absTol, relTol, disc, true);
7676
}
7777

78+
TEST_CASE("GRM numerical Benchmark with parameter sensitivities and multiplexing for 2parType 2comp linear case", "[GRM],[FV],[Simulation],[Reference],[Sensitivity],[CI_sensitivity1]")
79+
{
80+
const std::string modelFilePath = std::string("/data/model_GRMparType2_dynLin_2comp_sensbenchmark1.json");
81+
const std::string refFilePath = std::string("/data/ref_GRMparType2_dynLin_2comp_sensbenchmark1_FV_Z16parZ8.h5");
82+
const std::vector<double> absTol = { 1e-12, 1e-6, 1e-6, 1e-6, 1e-6, 1e-6, 1e-6 };
83+
const std::vector<double> relTol = { 1e-4, 1e-1, 1e-1, 1e-1, 1e-1, 1e-1, 1e-1 };
84+
85+
const cadet::test::column::FVparams disc(16, 8);
86+
cadet::test::column::testReferenceBenchmark(modelFilePath, refFilePath, "001", absTol, relTol, disc, true);
87+
}
88+
7889
TEST_CASE("GRM numerical Benchmark with parameter sensitivities for SMA LWE case", "[GRM],[FV],[Simulation],[Reference],[Sensitivity],[CI_sensitivity1]")
7990
{
8091
const std::string& modelFilePath = std::string("/data/model_GRM_reqSMA_4comp_benchmark1.json");

test/GeneralRateModelDG.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,17 @@ TEST_CASE("GRM_DG numerical Benchmark with parameter sensitivities for linear ca
8080
cadet::test::column::testReferenceBenchmark(modelFilePath, refFilePath, "001", absTol, relTol, disc, true);
8181
}
8282

83+
TEST_CASE("GRM_DG numerical Benchmark with parameter sensitivities and multiplexing for 2parType 2comp linear case", "[GRM],[DG],[DG1D],[Simulation],[Reference],[Sensitivity],[CI_sensitivity1]")
84+
{
85+
const std::string modelFilePath = std::string("/data/model_GRMparType2_dynLin_2comp_sensbenchmark1.json");
86+
const std::string refFilePath = std::string("/data/ref_GRMparType2_dynLin_2comp_sensbenchmark1_cDG_P3Z4_DGexInt_parP3parZ2.h5");
87+
const std::vector<double> absTol = { 1e-12, 1e-6, 1e-6, 1e-6, 1e-6, 1e-6, 1e-6 };
88+
const std::vector<double> relTol = { 1e-4, 1e-1, 1e-1, 1e-1, 1e-1, 1e-1, 1e-1 };
89+
90+
const cadet::test::column::DGparams disc(0, 3, 4, 3, 2);
91+
cadet::test::column::testReferenceBenchmark(modelFilePath, refFilePath, "001", absTol, relTol, disc, true);
92+
}
93+
8394
TEST_CASE("GRM_DG numerical Benchmark with parameter sensitivities for SMA LWE case", "[GRM],[DG],[DG1D],[Simulation],[Reference],[Sensitivity],[CI_sensitivity2]")
8495
{
8596
const std::string modelFilePath = std::string("/data/model_GRM_reqSMA_4comp_benchmark1.json");

0 commit comments

Comments
 (0)