From fc72c0ae9f8084e50b00ef20bc4e38c5a21ac63a Mon Sep 17 00:00:00 2001 From: Paul Sharp <44529197+DrPaulSharp@users.noreply.github.com> Date: Thu, 27 Feb 2025 15:37:45 +0000 Subject: [PATCH 1/2] Removes unused properties from the API --- RATapi/inputs.py | 22 ----- cpp/RAT | 2 +- cpp/rat.cpp | 187 ++++++++++++++++++------------------------- tests/test_inputs.py | 54 ------------- tests/test_run.py | 72 ----------------- 5 files changed, 78 insertions(+), 259 deletions(-) diff --git a/RATapi/inputs.py b/RATapi/inputs.py index 69080636..0bc00284 100644 --- a/RATapi/inputs.py +++ b/RATapi/inputs.py @@ -142,9 +142,6 @@ def make_input(project: RATapi.Project, controls: RATapi.Controls) -> tuple[Prob [[element.min, element.max] for element in getattr(project, class_list)], ) - # Use dummy value for qzshifts - limits.qzshifts = [] - if project.model == LayerModels.CustomXY: controls.calcSldDuringFit = True @@ -298,7 +295,6 @@ def make_problem(project: RATapi.Project) -> ProblemDefinition: problem.dataPresent = make_data_present(project) problem.dataLimits = data_limits problem.simulationLimits = simulation_limits - problem.oilChiDataPresent = [0] * len(project.contrasts) problem.numberOfContrasts = len(project.contrasts) problem.geometry = project.geometry problem.useImaginary = project.absorption @@ -306,7 +302,6 @@ def make_problem(project: RATapi.Project) -> ProblemDefinition: problem.contrastBackgroundParams = contrast_background_params problem.contrastBackgroundTypes = contrast_background_types problem.contrastBackgroundActions = [contrast.background_action for contrast in project.contrasts] - problem.contrastQzshifts = [1] * len(project.contrasts) # This is marked as "to do" in RAT problem.contrastScalefactors = [ project.scalefactors.index(contrast.scalefactor, True) for contrast in project.contrasts ] @@ -317,7 +312,6 @@ def make_problem(project: RATapi.Project) -> ProblemDefinition: problem.contrastResolutionTypes = contrast_resolution_types problem.backgroundParams = [param.value for param in project.background_parameters] - problem.qzshifts = [0.0] problem.scalefactors = [param.value for param in project.scalefactors] problem.bulkIns = [param.value for param in project.bulk_in] problem.bulkOuts = [param.value for param in project.bulk_out] @@ -358,18 +352,6 @@ def make_problem(project: RATapi.Project) -> ProblemDefinition: for param in getattr(project, class_list) if param.fit ] - problem.otherParams = [ - param.value - for class_list in RATapi.project.parameter_class_lists - for param in getattr(project, class_list) - if not param.fit - ] - problem.otherLimits = [ - [param.min, param.max] - for class_list in RATapi.project.parameter_class_lists - for param in getattr(project, class_list) - if not param.fit - ] problem.priorNames = [ param.name for class_list in RATapi.project.parameter_class_lists for param in getattr(project, class_list) ] @@ -392,10 +374,6 @@ def make_problem(project: RATapi.Project) -> ProblemDefinition: problem.checks, parameter_field[class_list], [int(element.fit) for element in getattr(project, class_list)] ) - # Use dummy values for qz shifts - problem.names.qzshifts = [] - problem.checks.qzshifts = [] - check_indices(problem) return problem diff --git a/cpp/RAT b/cpp/RAT index 7effee9d..62421f6d 160000 --- a/cpp/RAT +++ b/cpp/RAT @@ -1 +1 @@ -Subproject commit 7effee9dc3190ff064187bf69d7c66f3ee828622 +Subproject commit 62421f6df7e2d5bb16c628a944d5955aea609d37 diff --git a/cpp/rat.cpp b/cpp/rat.cpp index 039be9de..d8d48d68 100644 --- a/cpp/rat.cpp +++ b/cpp/rat.cpp @@ -227,7 +227,6 @@ RAT::b_ParamNames createParamNamesStruct(const NameStore& names) names_struct.params = customCaller("NameStore.params", pyListToRatCellWrap02d, names.params); names_struct.backgroundParams = customCaller("NameStore.backgroundParams", pyListToRatCellWrap02d, names.backgroundParams); names_struct.scalefactors = customCaller("NameStore.scalefactors", pyListToRatCellWrap02d, names.scalefactors); - names_struct.qzshifts = customCaller("NameStore.qzshifts", pyListToRatCellWrap02d, names.qzshifts); names_struct.bulkIns = customCaller("NameStore.bulkIns", pyListToRatCellWrap02d, names.bulkIns); names_struct.bulkOuts = customCaller("NameStore.bulkOuts", pyListToRatCellWrap02d, names.bulkOuts); names_struct.resolutionParams = customCaller("NameStore.resolutionParams", pyListToRatCellWrap02d, names.resolutionParams); @@ -243,7 +242,6 @@ RAT::CheckFlags createCheckFlagsStruct(const Checks& checks) checks_struct.params = customCaller("Checks.params", pyArrayToRatRowArray1d, checks.params); checks_struct.backgroundParams = customCaller("Checks.backgroundParams", pyArrayToRatRowArray1d, checks.backgroundParams); checks_struct.scalefactors = customCaller("Checks.scalefactors", pyArrayToRatRowArray1d, checks.scalefactors); - checks_struct.qzshifts = customCaller("Checks.qzshifts", pyArrayToRatRowArray1d, checks.qzshifts); checks_struct.bulkIns = customCaller("Checks.bulkIns", pyArrayToRatRowArray1d, checks.bulkIns); checks_struct.bulkOuts = customCaller("Checks.bulkOuts", pyArrayToRatRowArray1d, checks.bulkOuts); checks_struct.resolutionParams = customCaller("Checks.resolutionParams", pyArrayToRatRowArray1d, checks.resolutionParams); @@ -262,7 +260,6 @@ RAT::b_ProblemDefinition createProblemDefinitionStruct(const ProblemDefinition& problem_struct.dataPresent = customCaller("Problem.dataPresent", pyArrayToRatRowArray1d, problem.dataPresent); problem_struct.dataLimits = customCaller("Problem.dataLimits", pyListToRatCellWrap2, problem.dataLimits); problem_struct.simulationLimits = customCaller("Problem.simulationLimits", pyListToRatCellWrap2, problem.simulationLimits); - problem_struct.oilChiDataPresent = customCaller("Problem.oilChiDataPresent", pyArrayToRatRowArray1d, problem.oilChiDataPresent); problem_struct.numberOfContrasts = problem.numberOfContrasts; stringToRatBoundedArray(problem.geometry, problem_struct.geometry.data, problem_struct.geometry.size); problem_struct.useImaginary = problem.useImaginary; @@ -270,14 +267,12 @@ RAT::b_ProblemDefinition createProblemDefinitionStruct(const ProblemDefinition& problem_struct.contrastBackgroundParams = customCaller("Problem.contrastBackgroundParams", pyListToRatCellWrap3, problem.contrastBackgroundParams); problem_struct.contrastBackgroundTypes = customCaller("Problem.contrastBackgroundTypes", pyListToRatCellWrap02d, problem.contrastBackgroundTypes); problem_struct.contrastBackgroundActions = customCaller("Problem.contrastBackgroundActions", pyListToRatCellWrap02d, problem.contrastBackgroundActions); - problem_struct.contrastQzshifts = customCaller("Problem.contrastQzshifts", pyArrayToRatRowArray1d, problem.contrastQzshifts); problem_struct.contrastScalefactors = customCaller("Problem.contrastScalefactors", pyArrayToRatRowArray1d, problem.contrastScalefactors); problem_struct.contrastBulkIns = customCaller("Problem.contrastBulkIns", pyArrayToRatRowArray1d, problem.contrastBulkIns); problem_struct.contrastBulkOuts = customCaller("Problem.contrastBulkOuts", pyArrayToRatRowArray1d, problem.contrastBulkOuts); problem_struct.contrastResolutionParams = customCaller("Problem.contrastResolutionParams", pyListToRatCellWrap4, problem.contrastResolutionParams); problem_struct.contrastResolutionTypes = customCaller("Problem.contrastResolutionTypes", pyListToRatCellWrap02d, problem.contrastResolutionTypes); problem_struct.backgroundParams = customCaller("Problem.backgroundParams", pyArrayToRatRowArray1d, problem.backgroundParams); - problem_struct.qzshifts = customCaller("Problem.qzshifts", pyArrayToRatRowArray1d, problem.qzshifts); problem_struct.scalefactors = customCaller("Problem.scalefactors", pyArrayToRatRowArray1d, problem.scalefactors); problem_struct.bulkIns = customCaller("Problem.bulkIns", pyArrayToRatRowArray1d, problem.bulkIns); problem_struct.bulkOuts = customCaller("Problem.bulkOuts", pyArrayToRatRowArray1d, problem.bulkOuts); @@ -294,9 +289,7 @@ RAT::b_ProblemDefinition createProblemDefinitionStruct(const ProblemDefinition& problem_struct.numberOfDomainContrasts = problem.numberOfDomainContrasts; problem_struct.domainContrastLayers = customCaller("Problem.domainContrastLayers", pyListToRatCellWrap5, problem.domainContrastLayers); problem_struct.fitParams = customCaller("Problem.fitParams", pyArrayToRatRowArray1d, problem.fitParams); - problem_struct.otherParams = customCaller("Problem.otherParams", pyArrayToRatRowArray1d, problem.otherParams); problem_struct.fitLimits = customCaller("Problem.fitLimits", pyArrayToRatArray2d, problem.fitLimits); - problem_struct.otherLimits = customCaller("Problem.otherLimits", pyArrayToRatArray2d, problem.otherLimits); problem_struct.priorNames = customCaller("Problem.priorNames", pyListToRatCellWrap01d, problem.priorNames); problem_struct.priorValues = customCaller("Problem.priorValues", pyArrayToRatArray2d, problem.priorValues); @@ -314,7 +307,6 @@ RAT::ProblemLimits createProblemLimitsStruct(const Limits& limits) limits_struct.params = customCaller("Limits.params", pyArrayToRatArray2d, limits.params); limits_struct.backgroundParams = customCaller("Limits.backgroundParams", pyArrayToRatArray2d, limits.backgroundParams); limits_struct.scalefactors = customCaller("Limits.scalefactors", pyArrayToRatArray2d, limits.scalefactors); - limits_struct.qzshifts = customCaller("Limits.qzshifts", pyArrayToRatArray2d, limits.qzshifts); limits_struct.bulkIns = customCaller("Limits.bulkIns", pyArrayToRatArray2d, limits.bulkIns); limits_struct.bulkOuts = customCaller("Limits.bulkOuts", pyArrayToRatArray2d, limits.bulkOuts); limits_struct.resolutionParams = customCaller("Limits.resolutionParams", pyArrayToRatArray2d, limits.resolutionParams); @@ -480,7 +472,6 @@ ProblemDefinition problemDefinitionFromStruct(const RAT::b_ProblemDefinition pro problem_def.dataPresent = pyArrayFromRatArray1d>(problem.dataPresent); problem_def.dataLimits = pyListFromRatCellWrap2(problem.dataLimits); problem_def.simulationLimits = pyListFromRatCellWrap2(problem.simulationLimits); - problem_def.oilChiDataPresent = pyArrayFromRatArray1d>(problem.oilChiDataPresent); problem_def.numberOfContrasts = problem.numberOfContrasts; stringFromRatBoundedArray(problem.geometry.data, problem.geometry.size, problem_def.geometry); problem_def.useImaginary = problem.useImaginary; @@ -488,14 +479,12 @@ ProblemDefinition problemDefinitionFromStruct(const RAT::b_ProblemDefinition pro problem_def.contrastBackgroundParams = pyListFromBoundedCellWrap>(problem.contrastBackgroundParams); problem_def.contrastBackgroundTypes = pyListFromRatCellWrap02d(problem.contrastBackgroundTypes); problem_def.contrastBackgroundActions = pyListFromRatCellWrap02d(problem.contrastBackgroundActions); - problem_def.contrastQzshifts = pyArrayFromRatArray1d>(problem.contrastQzshifts); problem_def.contrastScalefactors = pyArrayFromRatArray1d>(problem.contrastScalefactors); problem_def.contrastBulkIns = pyArrayFromRatArray1d>(problem.contrastBulkIns); problem_def.contrastBulkOuts = pyArrayFromRatArray1d>(problem.contrastBulkOuts); problem_def.contrastResolutionParams = pyListFromBoundedCellWrap>(problem.contrastResolutionParams); problem_def.contrastResolutionTypes = pyListFromRatCellWrap02d(problem.contrastResolutionTypes); problem_def.backgroundParams = pyArrayFromRatArray1d>(problem.backgroundParams); - problem_def.qzshifts = pyArrayFromRatArray1d>(problem.qzshifts); problem_def.scalefactors = pyArrayFromRatArray1d>(problem.scalefactors); problem_def.bulkIns = pyArrayFromRatArray1d>(problem.bulkIns); problem_def.bulkOuts = pyArrayFromRatArray1d>(problem.bulkOuts); @@ -512,16 +501,13 @@ ProblemDefinition problemDefinitionFromStruct(const RAT::b_ProblemDefinition pro problem_def.numberOfDomainContrasts = problem.numberOfDomainContrasts; problem_def.domainContrastLayers = pyList1DFromRatCellWrap2D>(problem.domainContrastLayers); problem_def.fitParams = pyArrayFromRatArray1d>(problem.fitParams); - problem_def.otherParams = pyArrayFromRatArray1d>(problem.otherParams); problem_def.fitLimits = pyArrayFromRatArray2d(problem.fitLimits); - problem_def.otherLimits = pyArrayFromRatArray2d(problem.otherLimits); problem_def.priorNames = pyListFromRatCellWrap01d(problem.priorNames); problem_def.priorValues = pyArrayFromRatArray2d(problem.priorValues); problem_def.names.params = pyListFromRatCellWrap02d(problem.names.params); problem_def.names.backgroundParams = pyListFromRatCellWrap02d(problem.names.backgroundParams); problem_def.names.scalefactors = pyListFromRatCellWrap02d(problem.names.scalefactors); - problem_def.names.qzshifts = pyListFromRatCellWrap02d(problem.names.qzshifts); problem_def.names.bulkIns = pyListFromRatCellWrap02d(problem.names.bulkIns); problem_def.names.bulkOuts = pyListFromRatCellWrap02d(problem.names.bulkOuts); problem_def.names.resolutionParams = pyListFromRatCellWrap02d(problem.names.resolutionParams); @@ -531,7 +517,6 @@ ProblemDefinition problemDefinitionFromStruct(const RAT::b_ProblemDefinition pro problem_def.checks.params = pyArrayFromRatArray1d>(problem.checks.params); problem_def.checks.backgroundParams = pyArrayFromRatArray1d>(problem.checks.backgroundParams); problem_def.checks.scalefactors = pyArrayFromRatArray1d>(problem.checks.scalefactors); - problem_def.checks.qzshifts = pyArrayFromRatArray1d>(problem.checks.qzshifts); problem_def.checks.bulkIns = pyArrayFromRatArray1d>(problem.checks.bulkIns); problem_def.checks.bulkOuts = pyArrayFromRatArray1d>(problem.checks.bulkOuts); problem_def.checks.resolutionParams = pyArrayFromRatArray1d>(problem.checks.resolutionParams); @@ -864,7 +849,6 @@ PYBIND11_MODULE(rat_core, m) { .def_readwrite("params", &NameStore::params) .def_readwrite("backgroundParams", &NameStore::backgroundParams) .def_readwrite("scalefactors", &NameStore::scalefactors) - .def_readwrite("qzshifts", &NameStore::qzshifts) .def_readwrite("bulkIns", &NameStore::bulkIns) .def_readwrite("bulkOuts", &NameStore::bulkOuts) .def_readwrite("resolutionParams", &NameStore::resolutionParams) @@ -873,11 +857,11 @@ PYBIND11_MODULE(rat_core, m) { .def(py::pickle( [](const NameStore &names) { // __getstate__ /* Return a tuple that fully encodes the state of the object */ - return py::make_tuple(names.params, names.backgroundParams, names.scalefactors, names.qzshifts, names.bulkIns, names.bulkOuts, names.resolutionParams, + return py::make_tuple(names.params, names.backgroundParams, names.scalefactors, names.bulkIns, names.bulkOuts, names.resolutionParams, names.domainRatios, names.contrasts); }, [](py::tuple t) { // __setstate__ - if (t.size() != 9) + if (t.size() != 8) throw std::runtime_error("Encountered invalid state unpickling NameStore object!"); /* Create a new C++ instance */ @@ -886,12 +870,11 @@ PYBIND11_MODULE(rat_core, m) { names.params = t[0].cast(); names.backgroundParams = t[1].cast(); names.scalefactors = t[2].cast(); - names.qzshifts = t[3].cast(); - names.bulkIns = t[4].cast(); - names.bulkOuts = t[5].cast(); - names.resolutionParams = t[6].cast(); - names.domainRatios = t[7].cast(); - names.contrasts = t[8].cast(); + names.bulkIns = t[3].cast(); + names.bulkOuts = t[4].cast(); + names.resolutionParams = t[5].cast(); + names.domainRatios = t[6].cast(); + names.contrasts = t[7].cast(); return names; })); @@ -901,7 +884,6 @@ PYBIND11_MODULE(rat_core, m) { .def_readwrite("params", &Checks::params) .def_readwrite("backgroundParams", &Checks::backgroundParams) .def_readwrite("scalefactors", &Checks::scalefactors) - .def_readwrite("qzshifts", &Checks::qzshifts) .def_readwrite("bulkIns", &Checks::bulkIns) .def_readwrite("bulkOuts", &Checks::bulkOuts) .def_readwrite("resolutionParams", &Checks::resolutionParams) @@ -909,11 +891,11 @@ PYBIND11_MODULE(rat_core, m) { .def(py::pickle( [](const Checks &chk) { // __getstate__ /* Return a tuple that fully encodes the state of the object */ - return py::make_tuple(chk.params, chk.backgroundParams, chk.scalefactors, chk.qzshifts, chk.bulkIns, chk.bulkOuts, + return py::make_tuple(chk.params, chk.backgroundParams, chk.scalefactors, chk.bulkIns, chk.bulkOuts, chk.resolutionParams, chk.domainRatios); }, [](py::tuple t) { // __setstate__ - if (t.size() != 8) + if (t.size() != 7) throw std::runtime_error("Encountered invalid state unpickling Checks object!"); /* Create a new C++ instance */ @@ -921,12 +903,11 @@ PYBIND11_MODULE(rat_core, m) { chk.params = t[0].cast>(); chk.backgroundParams = t[1].cast>(); - chk.scalefactors = t[2].cast>(); - chk.qzshifts = t[3].cast>(); - chk.bulkIns = t[4].cast>(); - chk.bulkOuts = t[5].cast>(); - chk.resolutionParams = t[6].cast>(); - chk.domainRatios = t[7].cast>(); + chk.scalefactors = t[2].cast>(); + chk.bulkIns = t[3].cast>(); + chk.bulkOuts = t[4].cast>(); + chk.resolutionParams = t[5].cast>(); + chk.domainRatios = t[6].cast>(); return chk; })); @@ -936,7 +917,6 @@ PYBIND11_MODULE(rat_core, m) { .def_readwrite("params", &Limits::params) .def_readwrite("backgroundParams", &Limits::backgroundParams) .def_readwrite("scalefactors", &Limits::scalefactors) - .def_readwrite("qzshifts", &Limits::qzshifts) .def_readwrite("bulkIns", &Limits::bulkIns) .def_readwrite("bulkOuts", &Limits::bulkOuts) .def_readwrite("resolutionParams", &Limits::resolutionParams) @@ -944,11 +924,11 @@ PYBIND11_MODULE(rat_core, m) { .def(py::pickle( [](const Limits &lim) { // __getstate__ /* Return a tuple that fully encodes the state of the object */ - return py::make_tuple(lim.params, lim.backgroundParams, lim.scalefactors, lim.qzshifts, lim.bulkIns, lim.bulkOuts, + return py::make_tuple(lim.params, lim.backgroundParams, lim.scalefactors, lim.bulkIns, lim.bulkOuts, lim.resolutionParams, lim.domainRatios); }, [](py::tuple t) { // __setstate__ - if (t.size() != 8) + if (t.size() != 7) throw std::runtime_error("Encountered invalid state unpickling Limits object!"); /* Create a new C++ instance */ @@ -957,11 +937,10 @@ PYBIND11_MODULE(rat_core, m) { lim.params = t[0].cast>(); lim.backgroundParams = t[1].cast>(); lim.scalefactors = t[2].cast>(); - lim.qzshifts = t[3].cast>(); - lim.bulkIns = t[4].cast>(); - lim.bulkOuts = t[5].cast>(); - lim.resolutionParams = t[6].cast>(); - lim.domainRatios = t[7].cast>(); + lim.bulkIns = t[3].cast>(); + lim.bulkOuts = t[4].cast>(); + lim.resolutionParams = t[5].cast>(); + lim.domainRatios = t[6].cast>(); return lim; })); @@ -1055,7 +1034,6 @@ PYBIND11_MODULE(rat_core, m) { .def_readwrite("dataPresent", &ProblemDefinition::dataPresent) .def_readwrite("dataLimits", &ProblemDefinition::dataLimits) .def_readwrite("simulationLimits", &ProblemDefinition::simulationLimits) - .def_readwrite("oilChiDataPresent", &ProblemDefinition::oilChiDataPresent) .def_readwrite("numberOfContrasts", &ProblemDefinition::numberOfContrasts) .def_readwrite("geometry", &ProblemDefinition::geometry) .def_readwrite("useImaginary", &ProblemDefinition::useImaginary) @@ -1063,14 +1041,12 @@ PYBIND11_MODULE(rat_core, m) { .def_readwrite("contrastBackgroundParams", &ProblemDefinition::contrastBackgroundParams) .def_readwrite("contrastBackgroundTypes", &ProblemDefinition::contrastBackgroundTypes) .def_readwrite("contrastBackgroundActions", &ProblemDefinition::contrastBackgroundActions) - .def_readwrite("contrastQzshifts", &ProblemDefinition::contrastQzshifts) .def_readwrite("contrastScalefactors", &ProblemDefinition::contrastScalefactors) .def_readwrite("contrastBulkIns", &ProblemDefinition::contrastBulkIns) .def_readwrite("contrastBulkOuts", &ProblemDefinition::contrastBulkOuts) .def_readwrite("contrastResolutionParams", &ProblemDefinition::contrastResolutionParams) .def_readwrite("contrastResolutionTypes", &ProblemDefinition::contrastResolutionTypes) .def_readwrite("backgroundParams", &ProblemDefinition::backgroundParams) - .def_readwrite("qzshifts", &ProblemDefinition::qzshifts) .def_readwrite("scalefactors", &ProblemDefinition::scalefactors) .def_readwrite("bulkIns", &ProblemDefinition::bulkIns) .def_readwrite("bulkOuts", &ProblemDefinition::bulkOuts) @@ -1087,9 +1063,7 @@ PYBIND11_MODULE(rat_core, m) { .def_readwrite("numberOfDomainContrasts", &ProblemDefinition::numberOfDomainContrasts) .def_readwrite("domainContrastLayers", &ProblemDefinition::domainContrastLayers) .def_readwrite("fitParams", &ProblemDefinition::fitParams) - .def_readwrite("otherParams", &ProblemDefinition::otherParams) .def_readwrite("fitLimits", &ProblemDefinition::fitLimits) - .def_readwrite("otherLimits", &ProblemDefinition::otherLimits) .def_readwrite("priorNames", &ProblemDefinition::priorNames) .def_readwrite("priorValues", &ProblemDefinition::priorValues) .def_readwrite("names", &ProblemDefinition::names) @@ -1097,21 +1071,21 @@ PYBIND11_MODULE(rat_core, m) { .def(py::pickle( [](const ProblemDefinition &p) { // __getstate__ /* Return a tuple that fully encodes the state of the object */ - return py::make_tuple(p.TF, p.resample, p.data, p.dataPresent, p.dataLimits, p.simulationLimits, p.oilChiDataPresent, + return py::make_tuple(p.TF, p.resample, p.data, p.dataPresent, p.dataLimits, p.simulationLimits, p.numberOfContrasts, p.geometry, p.useImaginary, p.repeatLayers, p.contrastBackgroundParams, p.contrastBackgroundTypes, p.contrastBackgroundActions, - p.contrastQzshifts, p.contrastScalefactors, p.contrastBulkIns, p.contrastBulkOuts, - p.contrastResolutionParams, p.contrastResolutionTypes, p.backgroundParams, p.qzshifts, p.scalefactors, - p.bulkIns, p.bulkOuts, p.resolutionParams, p.params, p.numberOfLayers, p.contrastLayers, p.layersDetails, + p.contrastScalefactors, p.contrastBulkIns, p.contrastBulkOuts, p.contrastResolutionParams, + p.contrastResolutionTypes, p.backgroundParams, p.scalefactors, p.bulkIns, p.bulkOuts, + p.resolutionParams, p.params, p.numberOfLayers, p.contrastLayers, p.layersDetails, p.customFiles, p.modelType, p.contrastCustomFiles, p.contrastDomainRatios, p.domainRatios, - p.numberOfDomainContrasts, p.domainContrastLayers, p.fitParams, p.otherParams, p.fitLimits, - p.otherLimits, p.priorNames, p.priorValues, p.names.params, p.names.backgroundParams, p.names.scalefactors, - p.names.qzshifts, p.names.bulkIns, p.names.bulkOuts, p.names.resolutionParams, p.names.domainRatios, - p.names.contrasts, p.checks.params, p.checks.backgroundParams, p.checks.scalefactors, p.checks.qzshifts, + p.numberOfDomainContrasts, p.domainContrastLayers, p.fitParams, p.fitLimits, p.priorNames, p.priorValues, + p.names.params, p.names.backgroundParams, p.names.scalefactors, p.names.bulkIns, + p.names.bulkOuts, p.names.resolutionParams, p.names.domainRatios, p.names.contrasts, + p.checks.params, p.checks.backgroundParams, p.checks.scalefactors, p.checks.bulkIns, p.checks.bulkOuts, p.checks.resolutionParams, p.checks.domainRatios); }, [](py::tuple t) { // __setstate__ - if (t.size() != 60) + if (t.size() != 53) throw std::runtime_error("Encountered invalid state unpickling ProblemDefinition object!"); /* Create a new C++ instance */ @@ -1123,62 +1097,55 @@ PYBIND11_MODULE(rat_core, m) { p.dataPresent = t[3].cast>(); p.dataLimits = t[4].cast(); p.simulationLimits = t[5].cast(); - p.oilChiDataPresent = t[6].cast>(); - p.numberOfContrasts = t[7].cast(); - p.geometry = t[8].cast(); - p.useImaginary = t[9].cast(); - p.repeatLayers = t[10].cast(); - p.contrastBackgroundParams = t[11].cast(); - p.contrastBackgroundTypes = t[12].cast(); - p.contrastBackgroundActions = t[13].cast(); - p.contrastQzshifts = t[14].cast>(); - p.contrastScalefactors = t[15].cast>(); - p.contrastBulkIns = t[16].cast>(); - p.contrastBulkOuts = t[17].cast>(); - p.contrastResolutionParams = t[18].cast(); - p.contrastResolutionTypes = t[19].cast(); - p.backgroundParams = t[20].cast>(); - p.qzshifts = t[21].cast>(); - p.scalefactors = t[22].cast>(); - p.bulkIns = t[23].cast>(); - p.bulkOuts = t[24].cast>(); - p.resolutionParams = t[25].cast>(); - p.params = t[26].cast>(); - p.numberOfLayers = t[27].cast(); - p.contrastLayers = t[28].cast(); - p.layersDetails = t[29].cast(); - p.customFiles = t[30].cast(); - p.modelType = t[31].cast(); - p.contrastCustomFiles = t[32].cast>(); - p.contrastDomainRatios = t[33].cast>(); - p.domainRatios = t[34].cast>(); - p.numberOfDomainContrasts = t[35].cast(); - p.domainContrastLayers = t[36].cast(); - p.fitParams = t[37].cast>(); - p.otherParams = t[38].cast>(); - p.fitLimits = t[39].cast>(); - p.otherLimits = t[40].cast>(); - p.priorNames = t[41].cast(); - p.priorValues = t[42].cast>(); + p.numberOfContrasts = t[6].cast(); + p.geometry = t[7].cast(); + p.useImaginary = t[8].cast(); + p.repeatLayers = t[9].cast(); + p.contrastBackgroundParams = t[10].cast(); + p.contrastBackgroundTypes = t[11].cast(); + p.contrastBackgroundActions = t[12].cast(); + p.contrastScalefactors = t[13].cast>(); + p.contrastBulkIns = t[14].cast>(); + p.contrastBulkOuts = t[15].cast>(); + p.contrastResolutionParams = t[16].cast(); + p.contrastResolutionTypes = t[17].cast(); + p.backgroundParams = t[18].cast>(); + p.scalefactors = t[19].cast>(); + p.bulkIns = t[20].cast>(); + p.bulkOuts = t[21].cast>(); + p.resolutionParams = t[22].cast>(); + p.params = t[23].cast>(); + p.numberOfLayers = t[24].cast(); + p.contrastLayers = t[25].cast(); + p.layersDetails = t[26].cast(); + p.customFiles = t[27].cast(); + p.modelType = t[28].cast(); + p.contrastCustomFiles = t[29].cast>(); + p.contrastDomainRatios = t[30].cast>(); + p.domainRatios = t[31].cast>(); + p.numberOfDomainContrasts = t[32].cast(); + p.domainContrastLayers = t[33].cast(); + p.fitParams = t[34].cast>(); + p.fitLimits = t[35].cast>(); + p.priorNames = t[36].cast(); + p.priorValues = t[37].cast>(); - p.names.params = t[43].cast(); - p.names.backgroundParams = t[44].cast(); - p.names.scalefactors = t[45].cast(); - p.names.qzshifts = t[46].cast(); - p.names.bulkIns = t[47].cast(); - p.names.bulkOuts = t[48].cast(); - p.names.resolutionParams = t[49].cast(); - p.names.domainRatios = t[50].cast(); - p.names.contrasts = t[51].cast(); - - p.checks.params = t[52].cast>(); - p.checks.backgroundParams = t[53].cast>(); - p.checks.scalefactors = t[54].cast>(); - p.checks.qzshifts = t[55].cast>(); - p.checks.bulkIns = t[56].cast>(); - p.checks.bulkOuts = t[57].cast>(); - p.checks.resolutionParams = t[58].cast>(); - p.checks.domainRatios = t[59].cast>(); + p.names.params = t[38].cast(); + p.names.backgroundParams = t[39].cast(); + p.names.scalefactors = t[40].cast(); + p.names.bulkIns = t[41].cast(); + p.names.bulkOuts = t[42].cast(); + p.names.resolutionParams = t[43].cast(); + p.names.domainRatios = t[44].cast(); + p.names.contrasts = t[45].cast(); + + p.checks.params = t[46].cast>(); + p.checks.backgroundParams = t[47].cast>(); + p.checks.scalefactors = t[48].cast>(); + p.checks.bulkIns = t[49].cast>(); + p.checks.bulkOuts = t[50].cast>(); + p.checks.resolutionParams = t[51].cast>(); + p.checks.domainRatios = t[52].cast>(); return p; })); diff --git a/tests/test_inputs.py b/tests/test_inputs.py index f9bf3ae8..d931ff5f 100644 --- a/tests/test_inputs.py +++ b/tests/test_inputs.py @@ -118,7 +118,6 @@ def test_names(): names.params = ["Substrate Roughness", "Test Thickness", "Test SLD", "Test Roughness"] names.backgroundParams = ["Background Param 1"] names.scalefactors = ["Scalefactor 1"] - names.qzshifts = [] names.bulkIns = ["SLD Air"] names.bulkOuts = ["SLD D2O"] names.resolutionParams = ["Resolution Param 1"] @@ -135,7 +134,6 @@ def test_checks(): checks.params = np.array([1, 0, 0, 0]) checks.backgroundParams = np.array([0]) checks.scalefactors = np.array([0]) - checks.qzshifts = np.array([]) checks.bulkIns = np.array([0]) checks.bulkOuts = np.array([0]) checks.resolutionParams = np.array([0]) @@ -155,14 +153,12 @@ def standard_layers_problem(test_names, test_checks): problem.params = [3.0, 0.0, 0.0, 0.0] problem.bulkIns = [0.0] problem.bulkOuts = [6.35e-06] - problem.qzshifts = [] problem.scalefactors = [0.23] problem.domainRatios = [] problem.backgroundParams = [1e-06] problem.resolutionParams = [0.03] problem.contrastBulkIns = [1] problem.contrastBulkOuts = [1] - problem.contrastQzshifts = [] problem.contrastScalefactors = [1] problem.contrastBackgroundParams = [[1]] problem.contrastBackgroundActions = [BackgroundActions.Add] @@ -176,7 +172,6 @@ def standard_layers_problem(test_names, test_checks): problem.data = [np.array([[1.0, 1.0, 1.0, 0.0, 0.0, 0.0]])] problem.dataLimits = [[1.0, 1.0]] problem.simulationLimits = [[1.0, 1.0]] - problem.oilChiDataPresent = [0] problem.numberOfContrasts = 1 problem.numberOfLayers = 1 problem.repeatLayers = [[0, 1]] @@ -185,18 +180,7 @@ def standard_layers_problem(test_names, test_checks): problem.numberOfDomainContrasts = 0 problem.domainContrastLayers = [] problem.fitParams = [3.0] - problem.otherParams = [0.0, 0.0, 0.0, 1e-06, 0.23, 0.0, 6.35e-06, 0.03] problem.fitLimits = [[1.0, 5.0]] - problem.otherLimits = [ - [0.0, 0.0], - [0.0, 0.0], - [0.0, 0.0], - [1e-07, 1e-05], - [0.02, 0.25], - [0.0, 0.0], - [6.2e-06, 6.35e-06], - [0.01, 0.05], - ] problem.priorNames = [ "Substrate Roughness", "Test Thickness", @@ -237,14 +221,12 @@ def domains_problem(test_names, test_checks): problem.params = [3.0, 0.0, 0.0, 0.0] problem.bulkIns = [0.0] problem.bulkOuts = [6.35e-06] - problem.qzshifts = [] problem.scalefactors = [0.23] problem.domainRatios = [0.5] problem.backgroundParams = [1e-06] problem.resolutionParams = [0.03] problem.contrastBulkIns = [1] problem.contrastBulkOuts = [1] - problem.contrastQzshifts = [] problem.contrastScalefactors = [1] problem.contrastBackgroundParams = [[1]] problem.contrastBackgroundActions = [BackgroundActions.Add] @@ -258,7 +240,6 @@ def domains_problem(test_names, test_checks): problem.data = [np.array([[1.0, 1.0, 1.0, 0.0, 0.0, 0.0]])] problem.dataLimits = [[1.0, 1.0]] problem.simulationLimits = [[1.0, 1.0]] - problem.oilChiDataPresent = [0] problem.numberOfContrasts = 1 problem.numberOfLayers = 1 problem.repeatLayers = [[0, 1]] @@ -267,19 +248,7 @@ def domains_problem(test_names, test_checks): problem.numberOfDomainContrasts = 2 problem.domainContrastLayers = [[1], [1]] problem.fitParams = [3.0] - problem.otherParams = [0.0, 0.0, 0.0, 1e-06, 0.23, 0.0, 6.35e-06, 0.03, 0.5] problem.fitLimits = [[1.0, 5.0]] - problem.otherLimits = [ - [0.0, 0.0], - [0.0, 0.0], - [0.0, 0.0], - [1e-07, 1e-05], - [0.02, 0.25], - [0.0, 0.0], - [6.2e-06, 6.35e-06], - [0.01, 0.05], - [0.4, 0.6], - ] problem.priorNames = [ "Substrate Roughness", "Test Thickness", @@ -323,14 +292,12 @@ def custom_xy_problem(test_names, test_checks): problem.params = [3.0, 0.0, 0.0, 0.0] problem.bulkIns = [0.0] problem.bulkOuts = [6.35e-06] - problem.qzshifts = [] problem.scalefactors = [0.23] problem.domainRatios = [] problem.backgroundParams = [1e-06] problem.resolutionParams = [0.03] problem.contrastBulkIns = [1] problem.contrastBulkOuts = [1] - problem.contrastQzshifts = [] problem.contrastScalefactors = [1] problem.contrastBackgroundParams = [[1]] problem.contrastBackgroundActions = [BackgroundActions.Add] @@ -344,7 +311,6 @@ def custom_xy_problem(test_names, test_checks): problem.data = [np.empty([0, 6])] problem.dataLimits = [[0.0, 0.0]] problem.simulationLimits = [[0.005, 0.7]] - problem.oilChiDataPresent = [0] problem.repeatLayers = [[0, 1]] problem.layersDetails = [] problem.contrastLayers = [[]] @@ -353,18 +319,7 @@ def custom_xy_problem(test_names, test_checks): problem.numberOfDomainContrasts = 0 problem.domainContrastLayers = [] problem.fitParams = [3.0] - problem.otherParams = [0.0, 0.0, 0.0, 1e-06, 0.23, 0.0, 6.35e-06, 0.03] problem.fitLimits = [[1.0, 5.0]] - problem.otherLimits = [ - [0.0, 0.0], - [0.0, 0.0], - [0.0, 0.0], - [1e-07, 1e-05], - [0.02, 0.25], - [0.0, 0.0], - [6.2e-06, 6.35e-06], - [0.01, 0.05], - ] problem.priorNames = [ "Substrate Roughness", "Test Thickness", @@ -403,7 +358,6 @@ def normal_limits(): limits.params = [[1.0, 5.0], [0.0, 0.0], [0.0, 0.0], [0.0, 0.0]] limits.backgroundParams = [[1e-7, 1e-5]] limits.scalefactors = [[0.02, 0.25]] - limits.qzshifts = [] limits.bulkIns = [[0.0, 0.0]] limits.bulkOuts = [[6.2e-6, 6.35e-6]] limits.resolutionParams = [[0.01, 0.05]] @@ -419,7 +373,6 @@ def domains_limits(): limits.params = [[1.0, 5.0], [0.0, 0.0], [0.0, 0.0], [0.0, 0.0]] limits.backgroundParams = [[1e-7, 1e-5]] limits.scalefactors = [[0.02, 0.25]] - limits.qzshifts = [] limits.bulkIns = [[0.0, 0.0]] limits.bulkOuts = [[6.2e-6, 6.35e-6]] limits.resolutionParams = [[0.01, 0.05]] @@ -540,7 +493,6 @@ def test_make_input(test_project, test_problem, test_limits, test_controls, requ "params", "backgroundParams", "scalefactors", - "qzshifts", "bulkIns", "bulkOuts", "resolutionParams", @@ -723,7 +675,6 @@ def check_problem_equal(actual_problem, expected_problem) -> None: array_fields = [ "params", "backgroundParams", - "qzshifts", "scalefactors", "bulkIns", "bulkOuts", @@ -731,7 +682,6 @@ def check_problem_equal(actual_problem, expected_problem) -> None: "domainRatios", "contrastBackgroundParams", "contrastBackgroundActions", - "contrastQzshifts", "contrastScalefactors", "contrastBulkIns", "contrastBulkOuts", @@ -741,21 +691,17 @@ def check_problem_equal(actual_problem, expected_problem) -> None: "dataPresent", "dataLimits", "simulationLimits", - "oilChiDataPresent", "repeatLayers", "contrastLayers", "domainContrastLayers", "fitParams", - "otherParams", "fitLimits", - "otherLimits", "priorValues", ] checks_fields = [ "params", "backgroundParams", "scalefactors", - "qzshifts", "bulkIns", "bulkOuts", "resolutionParams", diff --git a/tests/test_run.py b/tests/test_run.py index 85f7b64c..f488de4a 100644 --- a/tests/test_run.py +++ b/tests/test_run.py @@ -56,14 +56,12 @@ def reflectivity_calculation_problem(): ) problem.bulkIns = np.array([2.073e-06]) problem.bulkOuts = np.array([5.98e-06, 2.21e-06]) - problem.qzshifts = np.array([0.0]) problem.scalefactors = np.array([0.1, 0.15]) problem.domainRatios = np.array([]) problem.backgroundParams = np.array([2.23e-06, 3.38e-06]) problem.resolutionParams = np.array([0.03]) problem.contrastBulkIns = np.array([1.0, 1.0]) problem.contrastBulkOuts = np.array([1.0, 2.0]) - problem.contrastQzshifts = np.array([0.0, 0.0]) problem.contrastScalefactors = np.array([1.0, 2.0]) problem.contrastBackgroundParams = [[1.0], [2.0]] problem.contrastBackgroundTypes = ["constant", "constant"] @@ -76,7 +74,6 @@ def reflectivity_calculation_problem(): problem.dataPresent = np.array([1.0, 1.0]) problem.dataLimits = [[0.011403, 0.59342], [0.011403, 0.59342]] problem.simulationLimits = [[0.011403, 0.59342], [0.011403, 0.59342]] - problem.oilChiDataPresent = np.array([0.0, 0.0]) problem.numberOfContrasts = 2.0 problem.numberOfLayers = 6.0 problem.repeatLayers = [[0.0, 1.0], [0.0, 1.0]] @@ -116,21 +113,6 @@ def reflectivity_calculation_problem(): 2.210e-06, ], ) - problem.otherParams = np.array( - [ - 3.390e-06, - -4.010e-07, - 0.000e00, - 1.750e-06, - 1.470e-06, - -4.610e-07, - 1.000e02, - 1.000e-01, - 1.500e-01, - 2.073e-06, - 3.000e-02, - ], - ) problem.fitLimits = np.array( [ [1.00e00, 1.00e01], @@ -153,21 +135,6 @@ def reflectivity_calculation_problem(): [1.00e-06, 4.99e-06], ], ) - problem.otherLimits = np.array( - [ - [3.39e-06, 3.41e-06], - [-5.00e-07, -3.00e-07], - [0.00e00, 1.00e-09], - [1.00e-07, 2.00e-06], - [5.00e-07, 1.50e-06], - [-5.00e-07, 0.00e00], - [9.99e01, 1.00e02], - [5.00e-02, 2.00e-01], - [5.00e-02, 2.00e-01], - [2.00e-06, 2.10e-06], - [1.00e-02, 5.00e-02], - ], - ) problem.names.params = [ "Substrate Roughness", "Oxide Thickness", @@ -193,7 +160,6 @@ def reflectivity_calculation_problem(): ] problem.names.backgroundParams = ["Background parameter D2O", "Background parameter SMW"] problem.names.scalefactors = ["Scalefactor 1", "Scalefactor 2"] - problem.names.qzshifts = [] problem.names.bulkIns = ["Silicon"] problem.names.bulkOuts = ["D2O", "SMW"] problem.names.resolutionParams = ["Resolution Param 1"] @@ -204,7 +170,6 @@ def reflectivity_calculation_problem(): ) problem.checks.backgroundParams = np.array([1.0, 1.0]) problem.checks.scalefactors = np.array([0.0, 0.0]) - problem.checks.qzshifts = np.array([]) problem.checks.bulkIns = np.array([0.0]) problem.checks.bulkOuts = np.array([1.0, 1.0]) problem.checks.resolutionParams = np.array([0.0]) @@ -252,14 +217,12 @@ def dream_problem(): ) problem.bulkIns = np.array([2.073e-06]) problem.bulkOuts = np.array([6.01489149e-06, 1.59371685e-06]) - problem.qzshifts = np.array([0.0]) problem.scalefactors = np.array([0.1, 0.15]) problem.domainRatios = np.array([]) problem.backgroundParams = np.array([2.37113128e-06, 1.99006694e-06]) problem.resolutionParams = np.array([0.03]) problem.contrastBulkIns = np.array([1.0, 1.0]) problem.contrastBulkOuts = np.array([1.0, 2.0]) - problem.contrastQzshifts = np.array([0.0, 0.0]) problem.contrastScalefactors = np.array([1.0, 2.0]) problem.contrastBackgroundParams = [[1.0], [2.0]] problem.contrastBackgroundTypes = ["constant", "constant"] @@ -272,7 +235,6 @@ def dream_problem(): problem.dataPresent = np.array([1.0, 1.0]) problem.dataLimits = [[0.011403, 0.59342], [0.011403, 0.59342]] problem.simulationLimits = [[0.011403, 0.59342], [0.011403, 0.59342]] - problem.oilChiDataPresent = np.array([0.0, 0.0]) problem.numberOfContrasts = 2.0 problem.numberOfLayers = 6.0 problem.repeatLayers = [[0.0, 1.0], [0.0, 1.0]] @@ -312,22 +274,6 @@ def dream_problem(): 1.59371685e-06, ], ) - problem.otherParams = np.array( - [ - 3.390e-06, - -4.010e-07, - 0.000e00, - 1.750e-06, - 1.470e-06, - -4.610e-07, - 1.000e02, - 1.000e-01, - 1.500e-01, - 2.073e-06, - 3.000e-02, - 0.000e00, - ], - ) problem.fitLimits = np.array( [ [1.00e00, 1.00e01], @@ -350,22 +296,6 @@ def dream_problem(): [1.00e-06, 4.99e-06], ], ) - problem.otherLimits = np.array( - [ - [3.39e-06, 3.41e-06], - [-5.00e-07, -3.00e-07], - [0.00e00, 1.00e-09], - [1.00e-07, 2.00e-06], - [5.00e-07, 1.50e-06], - [-5.00e-07, 0.00e00], - [9.99e01, 1.00e02], - [5.00e-02, 2.00e-01], - [5.00e-02, 2.00e-01], - [2.00e-06, 2.10e-06], - [1.00e-02, 5.00e-02], - [0.00e00, 0.00e00], - ], - ) problem.names.params = [ "Substrate Roughness", "Oxide Thickness", @@ -391,7 +321,6 @@ def dream_problem(): ] problem.names.backgroundParams = ["Background parameter D2O", "Background parameter SMW"] problem.names.scalefactors = ["Scalefactor 1", "Scalefactor 2"] - problem.names.qzshifts = [] problem.names.bulkIns = ["Silicon"] problem.names.bulkOuts = ["D2O", "SMW"] problem.names.resolutionParams = ["Resolution Param 1"] @@ -402,7 +331,6 @@ def dream_problem(): ) problem.checks.backgroundParams = np.array([1.0, 1.0]) problem.checks.scalefactors = np.array([0.0, 0.0]) - problem.checks.qzshifts = np.array([]) problem.checks.bulkIns = np.array([0.0]) problem.checks.bulkOuts = np.array([1.0, 1.0]) problem.checks.resolutionParams = np.array([0.0]) From 805bdf3cf5214727ef1e50069a1af65ad6139630 Mon Sep 17 00:00:00 2001 From: Paul Sharp <44529197+DrPaulSharp@users.noreply.github.com> Date: Fri, 28 Feb 2025 14:43:27 +0000 Subject: [PATCH 2/2] Updates "define.h" --- cpp/includes/defines.h | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/cpp/includes/defines.h b/cpp/includes/defines.h index a9a59b7f..ffecaec3 100644 --- a/cpp/includes/defines.h +++ b/cpp/includes/defines.h @@ -397,8 +397,6 @@ backgroundParams : np.ndarray[np.float] Limits for backgroundParams in the problem definition. scalefactors : np.ndarray[np.float] Limits for scalefactors in the problem definition. -qzshifts : np.ndarray[np.float] - Limits for qzshifts in the problem definition. bulkIns : np.ndarray[np.float] Limits for bulkIns in the problem definition. bulkOuts : np.ndarray[np.float] @@ -413,7 +411,6 @@ struct Limits { py::array_t params; py::array_t backgroundParams; py::array_t scalefactors; - py::array_t qzshifts; py::array_t bulkIns; py::array_t bulkOuts; py::array_t resolutionParams; @@ -431,8 +428,6 @@ backgroundParams : list Names of backgroundParams in the problem definition. scalefactors : list Names of scalefactors in the problem definition. -qzshifts : list - Names of qzshifts in the problem definition. bulkIns : list Names of bulkIns in the problem definition. bulkName: list @@ -447,7 +442,6 @@ struct NameStore { py::list params; py::list backgroundParams; py::list scalefactors; - py::list qzshifts; py::list bulkIns; py::list bulkOuts; py::list resolutionParams; @@ -469,8 +463,6 @@ backgroundParams : np.ndarray[np.float] Non-zero values indicates which backgroundParams is fitted. scalefactors : np.ndarray[np.float] Non-zero values indicates which scalefactors is fitted. -qzshifts : np.ndarray[np.float] - Non-zero values indicates which qzshifts is fitted. bulkIns : np.ndarray[np.float] Non-zero values indicates which bulkIns is fitted. bulkOuts : np.ndarray[np.float] @@ -484,7 +476,6 @@ domainRatios : np.ndarray[np.float] struct Checks { py::array_t params; py::array_t backgroundParams; - py::array_t qzshifts; py::array_t scalefactors; py::array_t bulkIns; py::array_t bulkOuts; @@ -508,8 +499,6 @@ dataLimits : list Data limits for each contrast. simulationLimits : list; Simulation for each contrast. -oilChiDataPresent : np.ndarray[np.float] - If ``dataPresent[i]`` is non-zero, then contrast ``i`` has oilChi data. This is currently not being used. numberOfContrasts : int Number of contrasts. geometry : str @@ -525,8 +514,6 @@ contrastBackgroundTypes : list Background type for each contrast. contrastBackgroundActions : list Background action for each contrast. -contrastQzshifts : np.ndarray[np.float] - Indices of Qzshifts used for each contrast. This is currently not being used. contrastScalefactors : np.ndarray[np.float] Indices of scalefactors used for each contrast. contrastBulkIns : np.ndarray[np.float] @@ -539,8 +526,6 @@ contrastResolutionTypes : list Resolution type for each contrast. backgroundParams : np.ndarray[np.float] Background parameter values. -qzshifts : np.ndarray[np.float] - Qzshift values. This currently not being used. scalefactors : np.ndarray[np.float] Scalefactors values. bulkIns : np.ndarray[np.float] @@ -573,12 +558,8 @@ domainContrastLayers : list Indices of layers added to the model of each domain contrast. fitParams : np.ndarray[np.float] Values of fitted parameters. -otherParams : np.ndarray[np.float] - Values of non-fitted parameters. fitLimits : np.ndarray[np.float] Limits of fitted parameters. -otherLimits : np.ndarray[np.float] - Limits of non fitted parameters. priorNames : list Parameter names for for all parameters in the problem definition. priorValues : np.ndarray[np.float] @@ -596,7 +577,6 @@ struct ProblemDefinition { py::array_t dataPresent; py::list dataLimits; py::list simulationLimits; - py::array_t oilChiDataPresent; real_T numberOfContrasts; std::string geometry {}; boolean_T useImaginary {}; @@ -604,14 +584,12 @@ struct ProblemDefinition { py::list contrastBackgroundParams; py::list contrastBackgroundTypes; py::list contrastBackgroundActions; - py::array_t contrastQzshifts; py::array_t contrastScalefactors; py::array_t contrastBulkIns; py::array_t contrastBulkOuts; py::list contrastResolutionParams; py::list contrastResolutionTypes; py::array_t backgroundParams; - py::array_t qzshifts; py::array_t scalefactors; py::array_t bulkIns; py::array_t bulkOuts; @@ -628,9 +606,7 @@ struct ProblemDefinition { real_T numberOfDomainContrasts {}; py::list domainContrastLayers; py::array_t fitParams; - py::array_t otherParams; py::array_t fitLimits; - py::array_t otherLimits; py::list priorNames; py::array_t priorValues; NameStore names;