[WIP] NeuLAND experimental feature branch#1201
[WIP] NeuLAND experimental feature branch#1201YanzhaoW wants to merge 42 commits intoR3BRootGroup:devfrom
Conversation
|
Hi @YanzhaoW Be carefully with this point:
We cannot ignore the Run-ID, as it is used to change the parameter settings in-flight. The idea is to calibrate the detectors for each setting, obtain the corresponding parameters for each detector, and then merge all of them into a single ROOT file, where each setting is identified by a Run-ID or Par-ID. The latter will be associated with a master timestamp range, which defines the valid range of use for the parameters. In each experiment, we have (or should have!) someone responsible for the parameter repository, who manages the Par-ID for each setting. If this task is done properly, there's no reason to ignore it. |
|
Hi, @jose-luis-rs Thanks for your feedback. The implementation now is the run IDs are scanned in the beginning and the parameter with the same run ID will be chosen first. I could add a flag to force the compliance of Run ID of the parameters, such that if the same run ID doesn't exist, the program will abort.
First, I'm not sure the purpose of merging parameters of different detectors into a single file. In case of NeuLAND (maybe there are other detectors that are different), the final output, which can be used in higher level data analysis is just event data, containing all kinds of neutron and hit information. Here the calibration parameters are only used in the intermediate level and useless in the higher level. Second, merging parameters of different run IDs in a single ROOT file seems also confusing to me. If the end goal is to use HPC clusters to do the calibrations, the parameter output from each node must be written to a different file. Thus, we would have just one parameter in each file, which is generated/used by data files with a certain range of run IDs.
I don't quite understand the necessity of parameter repository. Like I said, mapped data can be immediately calibrated in HPC clusters once they are available after the beam time. And we will have hit level data ready for the higher level data analysis. |
|
Hello @YanzhaoW
This point might be relevant for certain experiments, but it doesn't reflect the general performance of our setups. For example, in the last experiment, we collected data for different incoming beams such as ²³F and ²⁵F. In the case of ²⁵F, the run IDs ranged from 151 to 161, but the par-ID remained the same because the detectors were very stable. Now the code is confusing because from our macros we have to pass the run-Id to R3BUcesbSource and R3BFileSource via FairRunOnline and FairRunAna, respectively, using: and this run-Id is later used to select the calibration parameters, but this is somewhat confusing because it actually represents the par-Id. This is something we need to eventually revise and rename properly in our classes. In R3BFileSource you can find a line like this:
See my comments above. The macro "unpack_data_all_levels.C" is used to produce hit-level data for all detectors. Currently, it reads many input files containing calibration parameters. This is just a first version, as we are still working on the calibration parameters for all settings. Later, we will be able to merge all the parameters into a single ROOT file and then use the previous procedure based on timestamps to manage the parameters.
I'm not sure what you mean here. For calibrations (i.e., obtaining the parameters), we can use regular PCs, and sometimes we need to extract the parameters manually by performing fits. I believe the idea behind using the HPC cluster is simply to generate high-level data for all detectors in a short time. In this process we will not produce any new parameters.
This depends on the detector. For NeuLAND, I'm sure you can run your calibration macros on the HPC cluster, but for other detectors we might need to do it manually. This isn't a problem, as most calibrations can be done using normal PCs, for example I'm using my laptop for the FRS-PID calibrations, and it's sufficient. "parameter repository" -> R3BParams_XXX repositories are needed to store all the parameters and analysis macros to have them under control, including the information about how the parameters were obtained. |
|
Yeah, the actual meanings of "par-ID" and "run-ID" are quite confusing. For the clarification, when we run
Now the logic is (if using
The so-called "par ID", if I'm not wrong, is the run ID given by the My opinion is that this run ID from a parameter file is useless and only causes trouble for the data analysis, due to the following reasons:
class Parameters
{
public:
auto get_parameter(int run_id) -> const Parameter&;
private:
std::map<int, Parameter> parameters;
}; |
|
Hello @YanzhaoW I will prepare an example to illustrate how it will work. But it might take a few days, as I am about to start my teaching duties.
Yes, you are right. But let me prepare the example to illustrate how it works. |
This reverts commit 7826525.
- fix the rebase for origin dev - create neuland_ana with JSON config - resolve issues from merge - fix r3bfield error - add neuland geo creator - set common options in app base class - complete sim json exe - finsih the program options - automate image build and push - add simcal2cal - fix the compile after rebase - fix the ci issue from doxygen
fixed attenuation and add more documentation to exe/readme - update R3BNeuland.h documentation - change back to macOS doxygen - add magic_enum - fix doxygen readme.md problem - Set conan cppstd to gnu17 - Use CMAKE_CXX_STANDARD to be 17 - Add CONAN_ENABLED guards - fix rebase problem add init simcal
- Disable CI for sub-repos and debian 10 - add PEDEDIR definition in CI - add source config.sh to ctest - cmakelists checked with dev branch - Remove the AddVolume from gGeoManager - This eliminate the duplication of volNeuland volume - Finish the transition to R3BIOConnector - Transform the neuland reconstruction algorithm to R3BIOVector
* set rank and proc in to neuland app add multiple json file inputs
format coordinates in gen improved clock added to pyfile 0.5 factor for reverasattenuationfactor format revert py satcoeff
- add millepede2 as a submodule - disable static analysis - add calibration of predecessor - add python script to check hit_par and change hit module par member names - add input and output name for ana tasks - fix the json object merging issue
* add warings to R3BFileSource2 * fixed sim energy calc
* add data processor for mille * complete mille data processor
- remove cached variables in digitizing channels - remove log of data structure to fix the performance issue - change DigitizingEingine to engine - swap hit with signal and rename with snake case - add generator option - add python module
* rewrite particle filter for neulandpoints * change to digitizer with namespace and use LOGP * remove old PdgParticle * add more docs for NeualndDigitizer
- Rebase on latest dev - Fix forward declaration problem in R3BUcesbLauncher and Pede - Use process v2 in pede launcher
- use conan for cli11 - add repo to cache name - add arm build for docker
- add R3BParView and map2calpartask to app config - add map data converter - remove plane/bar number in map data - Add BaseParCreator executable - add R3BParRootFileIo and detRootFileIo - update R3BFileSource2 to pass on EventHeader - Add same double plane entry type
- change TVector3 to XYZVector - Adapt to newer libfmt and add entrypoint - add container test to ci
NeuLAND experimental feature branch
Documentation: https://yanzhaow.github.io/R3BRoot/neuland.html
Github: https://github.com/YanzhaoW/R3BRoot
Dockerhub: https://hub.docker.com/r/yanzhaowang/r3bdev/tags
List of features
R3BParRootFileIo, which ignores the Run ID conflict and merges parameter files without creating temp par fileGithub CD to automatically build R3BRoot Apptainer container and push to sylabsTODO list
FQA
What is this branch?
This is my feature branch that has many experimental features, which hopefully will be merged into the dev branch. Each new committed added passes all CI tests and static analyzers, like clang-tidy and cpp-linter.
Is this branch complete divergent from the dev branch?
No, I will continuously rebase my branch onto the latest commit of the master branch. For the dev branch, I will also try to rebase onto the latest, except when dev branch merges lots of new commits during the beamtime period. If this happens, I will wait a month or two.
How to use this branch?
Checklist:
devbranch