## 3 Methods
### Efficient Channel Attention Temporal Convolutional Network
#### 3.1.3 Attention Temporal Convolution Module  
The ATC block consists of MHA and TC blocks. MHA first receives the local sequence \(\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}}\), highlighting valuable time features (sequences) in \(\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}}\). Then, TCN extracts high-level time features from the highlighted sequences. These high-level time features are fused and converted into probabilities for each category through a fully connected (FC) layer with SoftMax activation.  
(1) Multi-head Self-attention: MHA consists of several self-attention layers, called heads, which are shown in Figure 4. Each self-attention layer contains query Q, key K, and value V. Q and K interact to obtain the attention matrix. Given a local sequence \(\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}}\), for each head, the matrices Q, K, and V are further transformed through linear transformation matrices \(\mathrm{W_{Q}^{h}},\mathrm{W_{K}^{h}},\mathrm{W_{V}^{h}}\in\mathbb{R}^{\mathrm{ F_{2}}\times\mathrm{d_{H}}}\) to obtain the results, and the calculation formulas are as follows:  
\[\mathrm{Q_{h}} =\mathrm{W_{Q}^{h}LN}(\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}})\in \mathbb{R}^{\mathrm{d_{H}}} \tag{3}\] \[\mathrm{K_{h}} =\mathrm{W_{K}^{h}LN}(\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}})\in \mathbb{R}^{\mathrm{d_{H}}}\] (4) \[\mathrm{V_{h}} =\mathrm{W_{V}^{h}LN}(\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}})\in \mathbb{R}^{\mathrm{d_{H}}} \tag{5}\]  
In the formula, LN represents Layer Normalization [55], \(\mathrm{h}=1,\ldots,\mathrm{H}\) is the index of multiple attention heads, and H is the total number of heads. The size of each head is \(\mathrm{d_{H}}\).  
For each head, \(\mathrm{Q_{h}}\) and \(\mathrm{K_{h}}\) are scaled by dividing by the square of \(\mathrm{d_{H}}\), and then the scaled dot-product attention is computed using the SoftMax function. Finally, the output weight of a head is obtained by multiplying by \(\mathrm{V_{h}}\):  
\[\mathrm{A_{h}}=\mathrm{SoftMax}\Bigg{(}\frac{\mathrm{Q_{h}}\mathrm{K_{h}}^{ \mathrm{T}}}{\sqrt{\mathrm{d_{H}}}}\Bigg{)}\mathrm{V_{h}} \tag{6}\]  
\(\mathrm{A_{h}}\) is the self-attention weight of the single-head self-attention encoder. h refers to the index of the current head. Then, by concatenating the self-attention weights of all heads and performing a linear projection, the result is added to the input sequence \(\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}}\), as shown in Equation (7).  
\[\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}}=\mathcal{Z}_{\mathrm{i}}^{\mathrm{w}}[ \mathrm{A_{1}},\mathrm{A_{2}},\ldots,\mathrm{A_{h}}]+\mathcal{Z}_{\mathrm{i}}^{ \mathrm{w}},\mathrm{W_{O}}\in\mathbb{R}^{\mathrm{d_{H}}\times\mathrm{F_{2}}} \tag{7}\]  
(2) Temporal Convolution: The TC block consists of two dilated causal convolution layers [56], with batch normalization and ELU activation applied after each layer, as shown in Figure 5. Causal convolution can only perceive the current time step and its preceding inputs, ensuring that information does not flow from the future to the past, i.e., the output at time t depends only on the input at time t and prior. Dilated convolution increases the receptive field, allowing the network to perceive information over a longer range while increasing the depth. Therefore, dilated causal convolution effectively captures dependencies in long sequences. Residual connections optimize gradient propagation by element-wise addition of input and output feature mappings \(\mathrm{F(x)}+\mathrm{x}\), which is particularly beneficial in deep networks. These connections enable the network to learn identity mappings, significantly improving training efficiency. In the residual block, since the input and output dimensions are the same (32), we use an identity mapping; otherwise,a 1 \(\times\) 1 convolution is used for linear transformation. For more details on the TCN architecture, refer to [32].