From 63569314656cc32cb5229bd10b7044cf3f56d067 Mon Sep 17 00:00:00 2001 From: Mateusz Jakub Fila Date: Tue, 10 Dec 2024 17:56:04 +0100 Subject: [PATCH 1/3] fix typos --- doc/starterkit/k4MarlinWrapperCLIC/Readme.md | 2 +- k4MarlinWrapper/scripts/convertMarlinSteeringToGaudi.py | 4 ++-- k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp | 7 +++---- k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp | 3 +-- k4MarlinWrapper/src/components/LcioEventOutput.cpp | 2 +- k4MarlinWrapper/src/components/MarlinProcessorWrapper.cpp | 2 +- test/CMakeLists.txt | 2 +- test/README.md | 4 ++-- 8 files changed, 12 insertions(+), 14 deletions(-) diff --git a/doc/starterkit/k4MarlinWrapperCLIC/Readme.md b/doc/starterkit/k4MarlinWrapperCLIC/Readme.md index e30111c9..f26108a3 100644 --- a/doc/starterkit/k4MarlinWrapperCLIC/Readme.md +++ b/doc/starterkit/k4MarlinWrapperCLIC/Readme.md @@ -136,7 +136,7 @@ included with k4MarlinWrapper. Note that: + *MarlinProcessorWrappers* need input in LCIO format: EDM4hep collections need to be converted to LCIO + The output collections of *MarlinProcessorWrappers* may be used later by other algorithms: * Output collections of *MarlinProcessorWrappers* will be in LCIO format unless these are explicitly converted - * Some *MarlinProcessorWrappers* may modify collections instead of producing new ones: the original EDM4hep collection wont be updated in this case and would need conversion from LCIO to EDM4hep. + * Some *MarlinProcessorWrappers* may modify collections instead of producing new ones: the original EDM4hep collection won't be updated in this case and would need conversion from LCIO to EDM4hep. - To run *clicReconstruction* with EDM4hep format, use the steering file found in the `examples` folder of k4MarlinWrapper: `k4MarlinWrapper/examples/clicRec_e4h_input.py` (this also gets installed to `$K4MARLINWRAPPER/examples` in Key4hep releases) diff --git a/k4MarlinWrapper/scripts/convertMarlinSteeringToGaudi.py b/k4MarlinWrapper/scripts/convertMarlinSteeringToGaudi.py index 6c1dbb15..edfa24fe 100755 --- a/k4MarlinWrapper/scripts/convertMarlinSteeringToGaudi.py +++ b/k4MarlinWrapper/scripts/convertMarlinSteeringToGaudi.py @@ -225,7 +225,7 @@ def verbosityTranslator(marlinLogLevel): def convertParameters(params, proc, globParams, constants): - """convert json of parameters to gaudi""" + """convert json of parameters to Gaudi""" lines = [] if "Verbosity" in params: lines.append( @@ -259,7 +259,7 @@ def convertProcessors(lines, tree, globParams, constants): def findWarnIncludes(tree): - """Check the parsed XML structure for include statments and issue a warning""" + """Check the parsed XML structure for include statements and issue a warning""" if any(True for _ in tree.iter("include")): print( 'ERROR: Found at least one statement in the Marlin steering file' diff --git a/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp b/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp index 2f9eb39c..aef90fee 100644 --- a/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp +++ b/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp @@ -302,7 +302,7 @@ podio::CollectionBase* EDM4hep2LcioTool::getEDM4hepCollection(const std::string& throw GaudiException("Collection could not be casted to the expected type", name(), StatusCode::FAILURE); } -// Select the appropiate method to convert a collection given its type +// Select the appropriate method to convert a collection given its type void EDM4hep2LcioTool::convertAdd(const std::string& e4h_coll_name, const std::string& lcio_coll_name, lcio::LCEventImpl* lcio_event, CollectionPairMappings& collection_pairs, std::vector& pidCollections, @@ -412,8 +412,7 @@ StatusCode EDM4hep2LcioTool::convertCollections(lcio::LCEventImpl* lcio_event) { EDM4hep2LCIOConv::attachDqdxInfo(collection_pairs.tracks, dQdxCollections); - // We want one "global" map that is created the first time it is use in the - // event. + // We want one "global" map that is created the first time it is used in the event. DataObject* obj = nullptr; auto sc = evtSvc()->retrieveObject(GlobalConvertedObjectsMap::TESpath.data(), obj); if (sc.isFailure()) { @@ -434,7 +433,7 @@ StatusCode EDM4hep2LcioTool::convertCollections(lcio::LCEventImpl* lcio_event) { EDM4hep2LCIOConv::resolveRelations(collection_pairs, globalObjMap); - // Now we can convert the assocations and add them to the event + // Now we can convert the associations and add them to the event for (auto& [name, coll] : EDM4hep2LCIOConv::createLCRelationCollections(linkCollections, globalObjMap)) { lcio_event->addCollection(coll.release(), name); } diff --git a/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp b/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp index c843c4a5..ee5f0610 100644 --- a/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp +++ b/k4MarlinWrapper/src/components/Lcio2EDM4hep.cpp @@ -213,8 +213,7 @@ StatusCode Lcio2EDM4hepTool::convertCollections(lcio::LCEventImpl* the_event) { edm4hep::utils::PIDHandler::setAlgoInfo(metadataFrame, collName, pidInfo); } - // We want one "global" map that is created the first time it is use in the - // event. + // We want one "global" map that is created the first time it is used in the event. DataObject* obj = nullptr; auto sc = evtSvc()->retrieveObject(GlobalConvertedObjectsMap::TESpath.data(), obj); if (sc.isFailure()) { diff --git a/k4MarlinWrapper/src/components/LcioEventOutput.cpp b/k4MarlinWrapper/src/components/LcioEventOutput.cpp index 6e69711a..e238f0c0 100644 --- a/k4MarlinWrapper/src/components/LcioEventOutput.cpp +++ b/k4MarlinWrapper/src/components/LcioEventOutput.cpp @@ -107,7 +107,7 @@ void LcioEventOutput::dropCollections(lcio::LCEventImpl* event, std::vector flag(evt_coll->getFlag()); flag[lcio::LCIO::TRBIT_HITS] = 0; diff --git a/k4MarlinWrapper/src/components/MarlinProcessorWrapper.cpp b/k4MarlinWrapper/src/components/MarlinProcessorWrapper.cpp index c596b822..e2ed6f4a 100644 --- a/k4MarlinWrapper/src/components/MarlinProcessorWrapper.cpp +++ b/k4MarlinWrapper/src/components/MarlinProcessorWrapper.cpp @@ -152,7 +152,7 @@ StatusCode MarlinProcessorWrapper::instantiateProcessor(std::shared_ptr Date: Wed, 11 Dec 2024 22:06:00 +0100 Subject: [PATCH 2/3] update tbb link --- doc/starterkit/k4MarlinWrapperCLIC/howtoMultithread.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/starterkit/k4MarlinWrapperCLIC/howtoMultithread.md b/doc/starterkit/k4MarlinWrapperCLIC/howtoMultithread.md index fa123506..ceab816c 100644 --- a/doc/starterkit/k4MarlinWrapperCLIC/howtoMultithread.md +++ b/doc/starterkit/k4MarlinWrapperCLIC/howtoMultithread.md @@ -34,7 +34,7 @@ limitations under the License. ## Running Gaudi with multithreading support -Gaudi uses [Intel TBB](https://oneapi-src.github.io/oneTBB/) under the hood for multithreading. +Gaudi uses [oneTBB](https://uxlfoundation.github.io/oneTBB/) under the hood for multithreading. Gaudi exposes two main levels of parallelism: - Inter-event parallelism: running multiple events in parallel From d78df7657a96a538ef6779238a46d4143a77b0d7 Mon Sep 17 00:00:00 2001 From: Mateusz Jakub Fila Date: Wed, 11 Dec 2024 22:15:25 +0100 Subject: [PATCH 3/3] update comments referring to associations --- k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp b/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp index aef90fee..30b81a25 100644 --- a/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp +++ b/k4MarlinWrapper/src/components/EDM4hep2Lcio.cpp @@ -433,7 +433,7 @@ StatusCode EDM4hep2LcioTool::convertCollections(lcio::LCEventImpl* lcio_event) { EDM4hep2LCIOConv::resolveRelations(collection_pairs, globalObjMap); - // Now we can convert the associations and add them to the event + // Now we can convert the links and add them to the event for (auto& [name, coll] : EDM4hep2LCIOConv::createLCRelationCollections(linkCollections, globalObjMap)) { lcio_event->addCollection(coll.release(), name); }