Opened 6 years ago
Last modified 6 years ago
#1153 new enhancement
Separate composition of mixture models in GUI
Reported by: | tcbennun | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | SasView Next Release +1 |
Component: | SasView | Keywords: | |
Cc: | Work Package: | Beta Approximation Project |
Description
From JIRA, SASVIEW-973:
Mixture models (a.k.a. sum/multiply models, for current intents and purposes) separate parameters of their component models using prefixes (A_sld, B_sld, and so on).
We are on the way to using sub-headings in the parameters table instead (see SASVIEW-966 [Organise parameter table by model component; trac #1116]). To implement this for mixture models, an intermediate layer (upon model loading) is needed to extract the parameters by component and display them without prefixes; then, when they are manipulated, translate from the non-prefixed version to the prefixed version, in order to interact with the model itself correctly.
The first step seems okay, since modelinfo, I think, contains the necessary information to get the name of the model component from the parameter's prefix.
The second step is a bit more involved. One possibility is to have each non-prefixed parameter in the Qt model be associated with a data item which contains the real parameter name. Whatever happens, various routines will need updating to deal with this case, because currently only the item's text is used to identify the parameter.
From email correspondence with @pkienzle:
For the 5.0 UI where you are talking about keeping the parameters for S and P separate, a cleaner version of product.py is possible. Currently, I have to tear apart the parameter structure before calling the individual S and P with their own sets of parameters. It would be better to build the two separate parameter structures independently. Similarly for mixture models, which ought to be available without having to create a plugin model for each combination.
I propose that you assume such an interface exists, and that you can call it with the individual parameter sets decoupled. Within this interface, we can either construct an existing product/mixture model on the fly, or restructure product/mixture to use the decoupled parameters, whichever is more expedient.
If you decide to follow the current scheme which views the combined model as a single parameter set (not an unreasonable option given the number of changes required on the UI and project save/load to keep them separate) then you can target the 4.3 interface directly.
Change History (3)
comment:1 Changed 6 years ago by tcbennun
comment:2 Changed 6 years ago by tcbennun
- Priority changed from critical to major
(Not working on this until more urgent beta-approximation stuff is through.)
comment:3 Changed 6 years ago by tcbennun
- Milestone changed from SasView 5.0.0 to SasView Next Release +1
The approach in the GUI of creating a mixture model easily (on-the-fly, as it were, without saving a plugin model) is tricky. The Model tab is too close to being cluttered to introduce a new section of controls as it is.
The intention is for users to easily select multiple form factors, and for the resulting model to be a sum of these. The parameter table would show each form factor's parameters under a sub-heading (this is already achieved in the case of product models). Questions arise such as: