[WIP] Add control to select type of inputs displayed#356
[WIP] Add control to select type of inputs displayed#356EZoni wants to merge 9 commits intoBLAST-AI-ML:mainfrom
Conversation
|
To be understood why we have the following when we inspect the columns of the experiment and simulation dataframes:
|
|
The data structure we have with the current implementation in this PR is something along the lines of {
'exp': {
'Preplasma Z (MFA)': 12.1,
'DAZZLER-LT-3rdorder value1': 80000.0
},
'sim': {
'target_to_focus_distance': 99.99999999999964,
'TOD': 80000.0
}
}if you consider, for example, the I think this is not very handy and maybe could be replaced by something along the lines of {
'input1': {
'exp_name': 'Preplasma Z (MFA)',
'sim_name': 'target_to_focus_distance',
'exp_value': 12.1,
'sim_value': 99.99999999999964,
},
'input2': {
'exp_name': 'DAZZLER-LT-3rdorder value1',
'sim_name': 'TOD',
'exp_value': 80000.0,
'sim_value': 80000.0,
},
} to make it easy to switch between experiment representation and simulation representation while pointing to a given parameter. Not sure whether the top layer should be a dictionary or a list, it is just to give an idea. This could be done for the dictionaries storing the min and max values as well, e.g., {
'input1': {
'exp_name': 'Preplasma Z (MFA)',
'sim_name': 'target_to_focus_distance',
'exp_min': 11.85,
'sim_min': ...,
},
'input2': {
'exp_name': 'DAZZLER-LT-3rdorder value1',
'sim_name': 'TOD',
'exp_min': 80000.0,
'sim_min': 80000.0,
},
} In fact, we seem to need separate state variables for the min and max values, because they can be set from the UI, but I have the feeling that it may work even if we use a single state variable that contains value, min, and max. I could try this in a separate PR. On the other hand, I noticed that for the staging injector experiment, some of the simulation inputs in the calibration section are said to depend on some of the experiment outputs. I'm not sure what this means, but it should probably be taken into account when choosing the data structure above. What do you think? |
Overview
Add a selector that allows the user to choose whether the parameters displayed in the sliders and plots are the experiment parameters or the simulation parameters (which can be mapped into each other through the calibration constants).
Comparison before (left) v. after (right) this PR:
Linked issues
Close #345.
Notes
This PR also moves the output selector to the parameters control panel. I think this looks simpler and less cluttered, but I'm ready to revert the change, should any objections be raised.
To do