## 3 Experimental Measurements  
In this study, we use a sensing impedance approach to perform PD measurement. PD data were collected using sensing impedance sensors. The signals were sampled at a frequency of 50 MHz to capture the transient nature of the PD events. This technique involves the incorporation of a sensing impedance component whose value varies with frequency and is placed within the electrical circuit. This setup is designed to capture the occurrence of PD by detecting characteristic high-frequency pulses associated with it. The high-voltage circuit for PD measurement is shown in Figure 35 The high-voltage test transformer is powered by a sinusoidal voltage at industrial frequency from a power amplifier, which is driven by a function generator. A 1 nC coupling capacitor is placed in parallel with the measured object. The voltage and current waveform of partial discharges are measured on an AKV 9310 wide band quadripole system and automatically recorded using a fast digital scope with 16-bit vertical resolution. The electrode system consists of two cylindrical electrodes with diameters of 2.5 cm and 5 cm. The test sample, along with the electrode system, is immersed in mineral oil to suppress surface discharge. The test samples were created using Masked Stereolithography (MSLA) technology. Three types of samples were produced: solid (without internal cavities), with a single internal cavity, and with two internal cavities. The cavities were designed as spheres with a diameter of 2 mm, which were located in the middle of total a sample thickness of 3 mm. The samples were made of UV-sensitive epoxy resin. An example of an experimental sample with dimensions for two cavities is shown in Figure 36.  
Figure 34: PD charge for vertical alignment with three cavities. Figure 32: Electric field for vertical alignment with three cavities. The wavelet denoising technique is used to reduce noise while keeping signal features. A wavelet transform isolated the signal through coefficient thresholding, distinguishing it from noise. This wavelet-based method significantly reduced the noise. \[x_{denoised}(t)=\sum_{j=1}^{J}\sum_{k}c_{j,k}\psi_{j,k}(t)+\sum_{k}d_{j,k}\phi_{ j,k}(t) \tag{5}\]  
where the following are true:  
* \(\psi_{j,k}\): wavelet basis functions (sym4);
* \(c_{j,k}\): detail coefficients;
* \(d_{j,k}\): approximation coefficients;
* \(J=5\): decomposition level. Dividing PD signals into smaller segments enables the model to concentrate on distinct events:  
* Fixed-Window Segmentation: Partition the signal into consistent, equally-sized segments. * Event-Based Segmentation: Subdivide the signal according to identified PD events. The energy-based detection identifies pulses using:  
\[E[n]=\sum_{k=n-W}^{n}x^{2}[k],\quad W=\lfloor F_{s}\cdot 0.5\,\mathrm{\SIUnitSymbolMicro s }\rfloor \tag{6}\]  
The Signal Preprocessing algorithm follows these steps:  
Figure 35: High-voltage experimental circuit for PD measurement. Figure 36: Example of test sample for two cavities. Examples of the observed waveforms within one period after preprocessing using Algorithm 1 algorithm shown in Figure 37 for a single cavity sample and in Figure 38 for a two-cavity sample. ```
1:Input: Raw signal \(x(t)\), sampling frequency \(F_{s}\)
2:Apply wavelet denoising: \(x_{clean}(t)=\text{wdenoise}(x(t),\text{wavelet}=\text{'sym4}^{\prime})\)
3:Compute moving energy: \(E[n]=\sum_{k=n-\text{'W}}^{n+W}x_{clean}^{2}[k]\)
4:Determine threshold: \(\tau=\text{median}(E)+3\sigma_{E}\)
5:Identify PD region: \(t_{pd}=\{t|E(t)>\tau\}\)
6:Extract segment: \(x_{pd}(t)=x_{clean}(t_{pd}-\Delta t,t_{pd}+\Delta t)\)
7:Normalize: \(x_{norm}(t)=\frac{x_{pd}(t)-t_{pd}}{\max|x_{pd}(t)|}\)
```  
**Algorithm 1** PD Signal Preprocessing  
Figure 37: PD signal of single cavity defect: (**top**) raw applied voltage (gray) and PD response (blue), (**middle**) wavelet-denoised signal, and (**bottom**) normalized 2 μs pulse segment.