## 3 Experimental Setup  
The wavefront distortion caused by the whole laser system is considered in the wavefront compensation by using the small-aperture DM in the front stage of the high-power laser system (see Figure 2). In the laser system, the pulse seeds generated from the all-fiber structure front end with 10 nJ/3 ns at the wavelength of 1053 nm [41] passes through the preamplifier providing a high gain of 10\({}^{5}\) times, and its output energy reaches a 200 uJ level after the beam shaper. The beam shaper mainly compensates the spatial intensity of the output laser to achieve a high-quality nearfield. A four-stage Nd/glass rod amplifier is applied in the laser system with an output energy of 100 J and a beam diameter of \(D\) = 60 mm at the end [42,43]. In the complex laser system with a low operating repetition rate of approximately 2 shots per hour, an electricity-controlled DM is used for adaptive wavefront shaping. The electromagnetic DM (Imagine Eyes, Mirao-52e) is arranged as the cavity mirror (0\({}^{\circ}\) reflection) of the two-pass \(\Phi\)20 mm Nd/glass amplifier, which relatively easily calculates the DM surface to correct the wavefront distortion in the closed loop. The overall aperture of the DM is 15 mm, which matches the 13 mm beam aperture in the beam pass of the first main amplifier. The fluence is low (<0.01 J/cm\({}^{2}\)) at the cavity mirror position of the first amplifier. The DM we adopted is an active wavefront-shaping device with 52 motors providing a continuously deformable surface within a range of \(\pm\)50 um. The sensitivity is about 0.02 um RMS, which is acceptable with this device. It can compensate the wavefront distortion caused by the following amplification and transmission. The Shack-Hartmann wavefront sensor (Thorlabs WFS150-5C) is placed at the end to measure the output wavefront distribution. The cavity mirror position is the image relay plane. The DM and the Shack-Hartmann wavefront sensor are both at the image-conjugate-plane. Indeed, the DM mainly corrects the wavefront of the image-conjugate plane in the laser system.  
Figure 1: The structure of the wavefront shaping system. It consists of a small-aperture deformable mirror (DM), a laser system, and wavefront measurement (i.e., Shack–Hartmann wavefront sensor).  
We assume that an additional compensation of aberration is obtained by adjusting the position of a spatial filter lens, so the DM can be used alone. Before wavefront shaping, the beam alignment is finished and the beam passes through a series of spatial filter pinholes successfully. A laser spot angular radius at 99% of energy in the pinhole planes of the spatial filters are calculated in order to be compared with the pinhole dimensions. The laser spot angular radius is less than a 3.5 diffraction limit (DL). These pinhole radii are equal to 7.5-30 DL (pinhole size is nearly 2\(\sim\)2.5 mm). Indeed, the laser can pass through the pinholes without clipping at the pinholes.  
In this experiment, for the wavefront compensation without the main amplifiers in operation, the preamplifier operates at 1 Hz. When the DM works in a closed loop, it needs about 2 min to perform a one closed-loop operation to finish the calculation and uploading data. For wavefront compensation with the main amplifiers in operation, the interval between system shots is 30 min. Before wavefront shaping, the near-field fluence of the output laser has been shaped to be flat-top [44; 45; 46]. The stable near-field output is a necessary condition for good wavefront correction.