From 1ce364cb240e52dfd07094cdef5beb9177e2ac1e Mon Sep 17 00:00:00 2001 From: Juraj Smiesko <34742917+kjvbrt@users.noreply.github.com> Date: Thu, 18 Jul 2024 18:07:59 +0200 Subject: [PATCH] Adding manual pages for final and pin sub-commands (#393) * Adding manual pages for final and pin sub-commands * Using clang format from the stack * Adding safe directory * Using stable stack --- .github/workflows/format.yml | 11 +++--- .github/workflows/test.yml | 40 +++++++++---------- man/man1/fccanalysis-build.1 | 4 +- man/man1/fccanalysis-final.1 | 58 +++++++++++++++++++++++++++ man/man1/fccanalysis-pin.1 | 74 +++++++++++++++++++++++++++++++++++ man/man1/fccanalysis-plots.1 | 8 ++-- man/man1/fccanalysis-run.1 | 2 +- man/man1/fccanalysis-test.1 | 2 +- man/man1/fccanalysis.1 | 2 +- man/man7/fccanalysis-script.7 | 2 +- 10 files changed, 168 insertions(+), 35 deletions(-) create mode 100644 man/man1/fccanalysis-final.1 create mode 100644 man/man1/fccanalysis-pin.1 diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml index cb72016f5d..6884af8ae7 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/format.yml @@ -19,15 +19,16 @@ jobs: /bin/bash - name: Add upstream run: | - docker exec CI_container /bin/bash -c 'cd ./Package - git remote add upstream https://github.com/HEP-FCC/FCCAnalyses.git + docker exec CI_container /bin/bash -c 'cd Package; \ + git config --global --add safe.directory /Package; \ + git remote add upstream https://github.com/HEP-FCC/FCCAnalyses.git; \ git fetch upstream' - name: Run formatter run: | - docker exec CI_container /bin/bash -c 'cd ./Package - source /cvmfs/sft.cern.ch/lcg/contrib/clang/14.0.6/x86_64-centos7/setup.sh + docker exec CI_container /bin/bash -c 'cd ./Package; \ + source /cvmfs/sw.hsf.org/key4hep/setup.sh;\ git clang-format --style=file $(git merge-base upstream/master HEAD)' - name: Check cleanliness run: | - docker exec CI_container /bin/bash -c 'cd ./Package + docker exec CI_container /bin/bash -c 'cd ./Package; \ git diff' diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 1929698cff..4b0fad4ffc 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -24,32 +24,32 @@ jobs: /bin/bash - name: CMake Configure run: | - docker exec CI_container /bin/bash -c 'cd Package;\ - mkdir -p build install;\ - source ${{ matrix.STACK }};\ - cd build;\ - cmake -DCMAKE_INSTALL_PREFIX=../install -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_FLAGS=" -fdiagnostics-color=always " -DWITH_DD4HEP=ON -DWITH_ACTS=OFF -DWITH_ONNX=ON -G Ninja ..;' + docker exec CI_container /bin/bash -c 'cd Package; \ + mkdir -p build install; \ + source ${{ matrix.STACK }}; \ + cd build; \ + cmake -DCMAKE_INSTALL_PREFIX=../install -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_FLAGS=" -fdiagnostics-color=always " -DWITH_DD4HEP=ON -DWITH_ACTS=OFF -DWITH_ONNX=ON -G Ninja ..;' - name: Compile run: | - docker exec CI_container /bin/bash -c 'cd ./Package;\ - source ${{ matrix.STACK }};\ - cd build;\ - ninja -k0;' + docker exec CI_container /bin/bash -c 'cd ./Package; \ + source ${{ matrix.STACK }}; \ + cd build; \ + ninja -k0;' - name: Install run: | - docker exec CI_container /bin/bash -c 'cd ./Package;\ - source ${{ matrix.STACK }};\ - cd build;\ + docker exec CI_container /bin/bash -c 'cd ./Package; \ + source ${{ matrix.STACK }}; \ + cd build; \ ninja -k0 install;' - name: Test run: | - docker exec CI_container /bin/bash -c 'cd ./Package;\ - source ${{ matrix.STACK }};\ - cd build;\ - ninja -k0 && ctest --output-on-failure;' + docker exec CI_container /bin/bash -c 'cd ./Package; \ + source ${{ matrix.STACK }}; \ + cd build; \ + ninja -k0 && ctest --output-on-failure' - name: Test using local Setup.sh run: | - docker exec CI_container /bin/bash -c 'cd ./Package;\ - source ${{ matrix.STACK }};\ - source ./setup.sh;\ - fccanalysis run examples/FCCee/higgs/mH-recoil/mumu/analysis_stage1.py --output myoutput.root --files-list root://eospublic.cern.ch//eos/experiment/fcc/ee/generation/DelphesEvents/spring2021/IDEA/p8_ee_Zbb_ecm91_EvtGen_Bc2TauNuTAUHADNU/events_131527278.root' + docker exec CI_container /bin/bash -c 'cd ./Package; \ + source ${{ matrix.STACK }}; \ + source ./setup.sh; \ + fccanalysis run examples/FCCee/higgs/mH-recoil/mumu/analysis_stage1.py --output myoutput.root --files-list root://eospublic.cern.ch//eos/experiment/fcc/ee/generation/DelphesEvents/spring2021/IDEA/p8_ee_Zbb_ecm91_EvtGen_Bc2TauNuTAUHADNU/events_131527278.root' diff --git a/man/man1/fccanalysis-build.1 b/man/man1/fccanalysis-build.1 index 517166dfa7..a4eea54a8a 100644 --- a/man/man1/fccanalysis-build.1 +++ b/man/man1/fccanalysis-build.1 @@ -26,7 +26,7 @@ Completely clean build directory before compilation\&. \fB\-j\fR \fIBUILD_THREADS\fR, \fB\-\-build\-threads\fR \fIBUILD_THREADS\fR Specify number of threads used when compiling (equivalent to `make -j`) .SH SEE ALSO -fccanalysis(1), fccanalysis\-test(7), cmake(1) +fccanalysis(1), fccanalysis\-test(1), cmake(1) .SH BUGS Many .SH AUTHORS @@ -35,7 +35,7 @@ authors are: .in +4 Clement Helsens .br -Valentin Volk +Valentin Volkl .br Gerardo Ganis .SH FCCANALYSES diff --git a/man/man1/fccanalysis-final.1 b/man/man1/fccanalysis-final.1 new file mode 100644 index 0000000000..2de50049c9 --- /dev/null +++ b/man/man1/fccanalysis-final.1 @@ -0,0 +1,58 @@ +.\" Manpage for fccanalysis-final +.\" Contact FCC-PED-SoftwareAndComputing-Analysis@cern.ch to correct errors or typos. +.TH FCCANALYSIS\-FINAL 1 "18 Jul 2024" "0.9.0" "fccanalysis-final man page" +.SH NAME +\fBfccanalysis\-final\fR \(en finalize your analysis into histograms +.SH SYNOPSIS +.B fccanalysis final +[\fB\-h\fR | \fB\-\-help\fR] +[\fB\-g\fR | \fB\-\-graph\fR] +[\fB\-\-graph\-path\fR \fIGRAPH_PATH\fR] +.SH DESCRIPTION +.PP +.B fccanalysis\-final runs the last stage of the analysis, where one defines +final cuts and histograms\&. This stage can also output ROOT and LaTeX files for +further use\&. +.SH OPTIONS +.TP +.BR \-h ", " \-\-help +Prints short help message and exits\&. +.TP +.BR \-g ", " \-\-graph +Generates computational graph of the analysis\&. +.TP +\fB\-\-graph\-path\fR \fIGRAPH_PATH\fR +Analysis graph save path, should end with '.dot' or '.png'\&. +.SH SEE ALSO +fccanalysis(1) +.SH BUGS +Many +.SH AUTHORS +There are many contributors to the FCCAnalyses framework, but the principal +authors are: +.in +4 +Clement Helsens +.br +Valentin Volkl +.br +Gerardo Ganis +.SH FCCANALYSES +Part of the FCCAnalyses framework\&. +.SH LINKS +.PP +.UR https://hep-fcc\&.github\&.io/FCCAnalyses/ +FCCAnalyses webpage +.UE +.PP +.UR https://github\&.com/HEP\-FCC/FCCAnalyses/ +FCCAnalysises GitHub repository +.UE +.PP +.UR https://fccsw\-forum\&.web\&.cern\&.ch/ +FCCSW Forum +.UE +.SH CONTACT +.pp +.MT FCC-PED-SoftwareAndComputing-Analysis@cern.ch +FCC-PED-SoftwareAndComputing-Analysis +.ME diff --git a/man/man1/fccanalysis-pin.1 b/man/man1/fccanalysis-pin.1 new file mode 100644 index 0000000000..9cc48ed138 --- /dev/null +++ b/man/man1/fccanalysis-pin.1 @@ -0,0 +1,74 @@ +.\" Manpage for fccanalysis-pin +.\" Contact FCC-PED-SoftwareAndComputing-Analysis@cern.ch to correct errors or typos. +.TH FCCANALYSIS\-PIN 1 "18 Jul 2024" "0.9.0" "fccanalysis-pin man page" +.SH NAME +\fBfccanalysis\-pin\fR \(en pin version of the Key4hep stack +.SH SYNOPSIS +.B fccanalysis pin +[\fB\-h\fR | \fB\-\-help\fR] +[\fB\-c\fR | \fB\-\-clear\fR] +[\fB\-f\fR | \fB\-\-force\fR] +[\fB\-s\fR | \fB\-\-show\fR] +.SH DESCRIPTION +.PP +.B fccanalysis\-pin allows one to freeze the Key4hep stack version for the local +copy of the FCCAnalyses\&. To create the "pin" first make sure that you have +sourced Key4hep stack and after that simply run +.IP +fccanalysis pin + +.RE +.PP +which will save the currently sourced stack into the pin\&. +.PP +In order to pin the analysis to any other stack source this stack first\&. +.PP +The information about the stack (if pin is active) is stored in file +\&.fccana/stackpin inside the root of the FCCAnalyses\&. +.SH OPTIONS +.TP +.BR \-h ", " \-\-help +Prints short help message and exits\&. +.TP +.BR \-c ", " \-\-clear +Clear current analysis pin (if active)\&. +.TP +.BR \-f ", " \-\-force +Force recreation of the analysis pin (can be used to overwrite the current +pin)\&. +.TP +.BR \-s ", " \-\-show +Show current stack in the pin (if active)\&. +.SH SEE ALSO +fccanalysis(1) +.SH BUGS +Many +.SH AUTHORS +There are many contributors to the FCCAnalyses framework, but the principal +authors are: +.in +4 +Clement Helsens +.br +Valentin Volkl +.br +Gerardo Ganis +.SH FCCANALYSES +Part of the FCCAnalyses framework\&. +.SH LINKS +.PP +.UR https://hep-fcc\&.github\&.io/FCCAnalyses/ +FCCAnalyses webpage +.UE +.PP +.UR https://github\&.com/HEP\-FCC/FCCAnalyses/ +FCCAnalysises GitHub repository +.UE +.PP +.UR https://fccsw\-forum\&.web\&.cern\&.ch/ +FCCSW Forum +.UE +.SH CONTACT +.pp +.MT FCC-PED-SoftwareAndComputing-Analysis@cern.ch +FCC-PED-SoftwareAndComputing-Analysis +.ME diff --git a/man/man1/fccanalysis-plots.1 b/man/man1/fccanalysis-plots.1 index b8602d8d2d..2f8d957b39 100644 --- a/man/man1/fccanalysis-plots.1 +++ b/man/man1/fccanalysis-plots.1 @@ -30,13 +30,13 @@ Specify text size for the legend elements\&. The default value is: 0.035\&. \fB\-\-legend\-x\-min\fR \fILEGEND_X_MIN\fR Specify minimal x position of the legend\&. The default value: automatic\&. .TP -\fB--legend-x-max\fR \fILEGEND_X_MAX\fR +\fB\-\-legend-x-max\fR \fILEGEND_X_MAX\fR Specify maximal x position of the legend\&. The default value: automatic\&. .TP -\fB--legend-y-min\fR \fILEGEND_Y_MIN\fR +\fB\-\-legend-y-min\fR \fILEGEND_Y_MIN\fR Specify minimal y position of the legend\&. The default value: automatic\&. .TP -\fB--legend-y-max\fR \fILEGEND_Y_MAX\fR +\fB\-\-legend-y-max\fR \fILEGEND_Y_MAX\fR Specify maximal y position of the legend\&. The default value: automatic\&. .SH SEE ALSO fccanalysis(1), fccanalysis\-run(1), fccanalysis\-final(1) @@ -48,7 +48,7 @@ authors are: .in +4 Clement Helsens .br -Valentin Volk +Valentin Volkl .br Gerardo Ganis .SH FCCANALYSES diff --git a/man/man1/fccanalysis-run.1 b/man/man1/fccanalysis-run.1 index 4a20f611da..06f6f01bdb 100644 --- a/man/man1/fccanalysis-run.1 +++ b/man/man1/fccanalysis-run.1 @@ -73,7 +73,7 @@ authors are: .in +4 Clement Helsens .br -Valentin Volk +Valentin Volkl .br Gerardo Ganis .SH FCCANALYSES diff --git a/man/man1/fccanalysis-test.1 b/man/man1/fccanalysis-test.1 index f1bd4d1908..a82071d8c4 100644 --- a/man/man1/fccanalysis-test.1 +++ b/man/man1/fccanalysis-test.1 @@ -38,7 +38,7 @@ authors are: .in +4 Clement Helsens .br -Valentin Volk +Valentin Volkl .br Gerardo Ganis .SH FCCANALYSES diff --git a/man/man1/fccanalysis.1 b/man/man1/fccanalysis.1 index b6620ee06b..3218965d64 100644 --- a/man/man1/fccanalysis.1 +++ b/man/man1/fccanalysis.1 @@ -61,7 +61,7 @@ authors are: .in +4 Clement Helsens .br -Valentin Volk +Valentin Volkl .br Gerardo Ganis .SH FCCANALYSES diff --git a/man/man7/fccanalysis-script.7 b/man/man7/fccanalysis-script.7 index b9446e356f..2f1b22c4d7 100644 --- a/man/man7/fccanalysis-script.7 +++ b/man/man7/fccanalysis-script.7 @@ -188,7 +188,7 @@ authors are: .in +4 Clement Helsens .br -Valentin Volk +Valentin Volkl .br Gerardo Ganis .SH FCCANALYSES