1#include "Tracking/geo/GeometryContext.h"
6#include "Framework/Configure/Parameters.h"
7#include "Framework/Exception/Exception.h"
19void GeometryContext::loadTransformations(
const tgSurfMap& surf_map) {
21 alignment_map.clear();
23 for (
auto entry : surf_map) {
24 alignment_map[entry.first] =
26 (entry.second)->associatedDetectorElement())
27 ->uncorrectedTransform();
44 const Acts::Vector3 deltaT,
45 const Acts::Vector3 deltaR,
47 Acts::Translation3 deltaTranslation{deltaT};
48 Acts::RotationMatrix3 rot = deltaRot(deltaR);
49 Acts::Transform3 correction(deltaTranslation * rot);
53 if (alignment_map.count(sensorId) < 1) {
54 throw std::logic_error(
"GeometryContext:: could not addAlignCorrection");
60 alignment_map[sensorId].rotate(correction.rotation());
61 alignment_map[sensorId].translate(correction.translation());
63 alignment_map[sensorId].translate(correction.translation());
64 alignment_map[sensorId].rotate(correction.rotation());
93 std::pair<const framework::ConditionsObject*, framework::ConditionsIOV>
Base class for provider of conditions information like pedestals, gains, electronics maps,...
#define DECLARE_CONDITIONS_PROVIDER_NS(NS, CLASS)
Macro which allows the framework to construct a producer given its name during configuration.
be configured to load conditions objects from CSV files.
Class which defines the run/event/type range for which a given condition is valid,...
Base class for all providers of conditions objects.
const Process & process() const
Get the process handle.
Base class for all conditions objects, very simple.
Class which represents the process under execution.
Class encapsulating parameters for configuring a processor.
std::pair< const framework::ConditionsObject *, framework::ConditionsIOV > getCondition(const ldmx::EventHeader &context) final override
Get the context as a conditions object.
GeometryContextProvider(const std::string &name, const std::string &tagname, const framework::config::Parameters ¶meters, framework::Process &process)
Create the context conditions object.
The context for a specific geometry.
static const std::string NAME
Conditions object name.
const Acts::GeometryContext & get() const
get an Acts::GeometryContext wrapping the pointer to the instance of this GeometryContext
Acts::GeometryContext acts_gc_
Wrap this instance in an Acts::GeometryContext any object for passing it down to the various acts too...
GeometryContext()
TODO it should be private == KEEPING IT PUBLIC FOR TESTING PURPOSE.
void addAlignCorrection(unsigned int sensorId, const Acts::Vector3 deltaT, const Acts::Vector3 deltaR, const bool active=true)
Fill an internal map holding the alignment transformations sensorId : id of the alignable element in ...
All classes in the ldmx-sw project use this namespace.