{'fraction_non_alphanumeric': 0.025286680388121142, 'fraction_numerical': 0.011246692149367833, 'mean_word_length': 4.70440251572327, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Alignment of the ATLAS inner detector

In order to reach the track parameter accuracy motivated by the physics goals of the experiment, the ATLAS tracking system needs to determine accurately its almost 700,000 degrees of freedom. The demanded precision for the alignment of the silicon sensors is below 10 μm. The implementation of the track based alignment within the ATLAS software framework unifies different alignment approaches and allows the alignment of all tracking subsystems together. The alignment software relies on the tracking information (track-hit residuals) but also includes the capability to set constraints on the beam-spot and primary vertex as well as the momentum measured by the Muon System or the E/p using the calorimetry information. The alignment chain starts at the trigger level where a stream of high pT isolated tracks is selected online. Also a cosmic ray trigger is enabled while ATLAS is recording collision data, thus a stream of cosmic-ray tracks is recorded exactly with the same detector operating conditions as the normal collision tracks. We will present results of the alignment of the ATLAS tracker using the 2011 collision data. The validation of the alignment is performed using track-hit residuals as well as using more advanced physics observables. The results of the alignment with real data reveals that the attained precision for the alignment parameters is approximately 5 μm.


Introduction
The ATLAS experiment [1] is a general purpose experiments at the Large Hadron Collider (LHC) at CERN. It records proton-proton collisions at the center-of-mass energy up to 14 TeV. The Inner Detector (ID) [2] is the most important tracking system occupying a cylindrical volume of 2.1 m in diameter and 6.2 m in length around the interaction point that surrounds the beampipe. It is enclosed inside the central superconducting solenoid providing a 2 T axial field. The ID consists of two silicon subsystems, the Pixel Detector and the Semiconductor Tracker (SCT), complemented by the Transition Radiation Tracker (TRT) composed of straw tubes. Figure 1 shows an overview of the ID.
The Pixel detector consists of a barrel region with three cylindrical layers and two symmetric end-caps each containing three disks for tracking in the forward region. All pixel modules (1744 in total) are identical, with a sensor segmented in 50 µm × 400 µm pixels providing a 2D readout with a resolution of 10 µm and 115 µm in the rφ and rz coordinates, respectively. The SCT is made of four layers in the barrel region and nine disks in each of the two end-caps. Different types of modules have been installed in the SCT, all with the same components but differing in geometry. Each one of the 4088 modules is composed of two pairs of single-sided silicon microstrip detectors glued back-to-back with a relative stereo angle of 40 mrad. The strip pitch is 80 µm for the barrel and varying from ∼ 55 µm to ∼ 90 µm for end-cap modules due to their fan-out geometry. The intrinsic resolution in the rφ and rz coordinates is 17 µm and 580 µm, respectively. The TRT is the outermost and largest of the ID sub-detectors, which is made of straw drift tubes which have a single hit resolution of 130 µm in the (rφ) coordinates. The straw tubes are arranged in 32 modules in each of the three barrel layers and 2 × 40 end-cap wheels (176 modules in total).

Alignment goals
After the assembly of the detector, the position of the individual modules is known with much worse accuracy than their intrinsic resolution. Therefore the alignment procedures have to be applied. The baseline goal of the alignment is to determine the position and orientation of the modules with such precision that the track parameters' determination is not worsened by more than 20% with respect to that expected from the perfectly aligned detector. This is crucial for efficient track reconstruction, precise momentum measurement and vertex reconstruction.

Alignment challenges
The alignment challenges come from huge numbers of DoFs to be aligned. For each module 6 alignment degrees-of-freedom (DoF) can be defined (if ignoring the module level deformation): 3 translations and 3 rotations. Thanks to the strict assembly tolerance of the sensors in the structure of the SCT modules [3][4], alignment corrections at the level of the individual singlesided sensor are not computed. This means for Pixel and SCT, considering 6 DoFs per module, in total ∼35,000 DoFs; For TRT, considering 2 DoFs per Straw, in total ∼700,000 DoFs, should be aligned respectively. In order to ensure the quality of the alignment, huge statistics such as ten million high quality tracks are needed which is rather computing intensive. Several hundred or even thousand CPUs are simultaneously used in every iteration.

Alignment strategies and algorithms
Two independent algorithms have been developed and validated in the ATLAS offline software framework [5]. All are iterative and make use of the residuals of the reconstructed hits on tracks (See the explanation in figure 2). The main idea is that the sum of the residuals over a large number of reconstructed tracks should be minimal for the aligned geometry. This can be formulated as a large χ 2 minimization problem [6] [7] : Let r(a, τ ) be the vector of the residuals of the track hits. Residuals depend on both the alignment parameters (a) and the track parameters (τ ). V is the covariance matrix of the hit measurements. The alignment χ 2 is built as follows : The alignment corrections (δa) are obtained by applying the minimization condition to the χ 2 and by making use of the linear expansion of the residuals around r 0 (their initial estimates). This requires solving linear systems of the size equal to the number of the alignment DoFs as follows: (2)

Global χ 2 alignment
In the Global χ 2 approach, the solution given by equation 2 is calculated by using the total derivatives of residuals with respect to alignment parameters : which includes all correlations between the modules. This allows it to converge quasi-instantly. The calculation is numerically very challenging as it needs an inversion of a large matrix. The Global χ 2 approach is currently the baseline alignment algorithm used for the ID.

Local χ 2 alignment
In the Local χ 2 approach, the solution is also calculated according to equation 2, but partial derivatives with respect to alignment parameters are used instead of the total ones : This way the correlations between different detector modules are neglected and the alignment matrix is reduced to a series of 6×6 matrices (2×2 for TRT), which can be inverted quickly, as opposed to the Global χ 2 approach. The inter-module correlations are restored by performing a certain number of iterations, updating the geometry of the detector and then re-fitting the tracks.

Alignment level
To address the realistic misalignments of the detector, the alignment is done at different levels of granularity motivated by the mechanical structure of the ID. First, the largest structures, subdetector barrels and end-caps, are aligned (L1). A second level of alignment (L2) treats barrel layers and end-cap disks or wheels as separate alignable objects. At this level, more structures, and consequently more degrees-of-freedom, are aligned. The final alignment level consists of the module-by-module (Pixel, SCT) or wire-by-wire (TRT) alignment. This third alignment level has the most degrees-of-freedom and requires the greatest statistics.

Each iteration
The first part is the track accumulation, in which for each selected track the first and the second order derivatives of χ 2 with respect to the alignment parameters are calculated and added to equation 2. The accumulation is split into several hundred parallel subjobs. The second part is the solving for the alignment corrections (δa). Matrices and vectors resulting from the accumulation jobs are first merged together. Based on equation 2, very large linear matrix equation is solved to get the corrections. Different matrix solvers have been implemented, some are based on the direct diagonalization libraries (like CLHEP [10] and LAPACK [8]), the others are based on the fast-solving techniques (like MA27 [9]) which typically exploit the special properties of the large matrix to be inverted, such as sparseness and symmetry. Even though the fast-solvers don't provide the errors for the solution, their speed allows them to be used for the problems of very large size. Figure 3 shows the flow diagram of the full alignment iterations chain. The alignment is mainly performed on data from a special trigger stream, the ID Calibration stream. However in some cases it is also run over high quality tracks in physics streams. Track reconstruction is followed by the alignment monitoring which checks for the quality of the current constants. Afterwards the Silicon and TRT alignment is performed sequentially as described in the flow diagram. The obtained constants are fed into the next iteration. The final alignment constants are uploaded into the database after the iteration process has been completed.

Run on Grid and automatic alignment
An infrastructure for running the alignment on Grid has been developed and is extensively used. Traditionally, the ID alignment is run on the CERN batch system (CAF). With the increasing LHC data statistics the CPU and storage resources for ID alignment are no longer sufficient. The datasets accessible on CAF are quite limited too. The Grid environment offers access to nearly all ATLAS datasets and massively larger CPU and disk storage resources. Another advantage is that there are more powerful and convenient tools and interfaces for job management.
Last year the detectors were found to be slowly moving, hence decided to perform the alignment run by run to promptly detect the movements. Thus a mechanism that can automatically run the L1/L2 alignment in the calibration loop has been implemented. The shifters watch the constants changes, if significant changes are observed then some detailed study will be triggered and an updated set of constants will be produced.

Weak modes and constraints
The minimization of track residuals is necessary but not sufficient. The global distortions which preserve the helical trajectory of tracks and leave the χ 2 unchanged while systematically biasing the track parameters are known as weak modes. These kind of distortions are difficult to be removed by the minimization of the residuals, on the other hand they are very dangerous to physics results. Figure 4 shows a few example weak modes which may potentially have big impact on physics. Two main kinds of methods can deal with the weak modes. The first is the usage of different track topologies such as cosmics, beam halo and beam gas. The second is using constraints. Several constraint tools have been implemented and work quite effectively: These include beam-spot and vertex constraint, constraint on invariant masses of well known resonant decays, constraint on momentum from other systems (such as the constraint from Muon Spectrometer standalone momentum measurement, E/p constraint from the curvature asymmetry between e + and e − ).

Overall Residuals
The currently achieved alignment delivers nearly perfect residuals (see in figure 5 the exemplary plots of SCT local x residuals. In the Pixel and the SCT the local x and local y axes are in the detector plane with the x-axis pointing along the most precise measurement direction), which indicates the algorithms work correctly [6]. Now we are focusing on effects that are beyond just getting the residuals correct.

Residuals maps
There are also huge improvements in the detailed 2-D maps of the mean of the residual after the alignment for every sub-detector. Exemple plots are shown in figure 6 and 7. They are detailed   Figure 6. Detailed residual maps of the Barrel pixel modules. Each pixel module has been split in a 4×4 grid and the average residual in each cell is plotted. Each module is identified by its position in the layer. This is given by its "η ring" and "φ sector" indices. Figure 6 Figure 7. Mean of the Gaussian fit to TRT residuals vs φ-sector and wheel before, left, and after, right, the wire-by-wire alignment. The plots illustrate the end-cap A results. The white bins are due to dead channels. Figure 8 shows an example of the alignment corrections for translations in the global x direction, which are performed on a run by run basis starting from a common set of alignment constants [11]. Sizable movements (O(10 µm)) coincide with sudden environmental changes. In other periods a generally good stability (O(1 µm)) is observed.  The performance improvement of the latest alignment constants can be attributed to the fact that they eliminate most of the momentum related weak modes. Figure 10

Summary
Alignment of the Inner detector of ATLAS is a very complex and challenging task. After a fast learning phase, already now the resolution on the reconstructed track parameters very closely approached the MC expectation for a perfect geometry. The future plans include further understanding of the alignment systematics, better description of time dependent changes and of the internal module distortions. The ID Alignment is making a significant contribution to ATLAS precision measurements and new physics searches.  The left figure requires both tracks in the barrel region |η| <1.5; the middle requires both tracks in the end-cap A region 1.05< η <2.5; the right requires at least one track in the end-cap C region -2.5< η <-1.05.