## 5 Conclusions  
To address the challenges of temporal and spatial feature modeling in multimodal data processing, an efficient and secure computation framework based on the sliding-window attention mechanism and sliding loss function was proposed. This framework aims to overcome the limitations of traditional methods in terms of privacy protection, computational efficiency, and accuracy loss. Multimodal data, prevalent in domains such as financial forecasting, medical imaging analysis, and autonomous driving, present high complexity and dynamic characteristics that impose stringent demands on model performance. The traditional approaches, including federated learning, secure multi-party computation, homomorphic encryption, and TEE-based techniques, have shown success in privacy protection and data collaboration but often struggle to balance efficiency and accuracy due to high computational complexity or limited feature-capturing capabilities. Against this backdrop, the proposed framework employs innovative designs to significantly enhance feature modeling and dynamic data processing performance while ensuring data privacy and achieving higher computational efficiency with minimal accuracy loss. This framework provides a novel solution for privacy-preserving data security in cloud computing environments. The primary innovations of this study are twofold. First, the sliding-window attention mechanism confines the attention scope to local windows, effectively reducing the computational complexity from global \(O(n^{2})\) to \(O(n\cdot w)\), where \(w\) denotes the window size. This mechanism also captures global feature dependencies through the sliding operation, enabling efficient modeling of both local and global information. Second, the sliding loss function employs a localized loss computation approach that enhances the model's sensitivity to dynamic data variations, which is particularly advantageous in multimodal scenarios. The experimental results strongly validated the effectiveness of the proposed method. For time-series data tasks, the proposed method achieved a precision of 0.95, recall of 0.91, accuracy of 0.93, and F1-score of 0.93, representing significant improvements over the baseline methods. In spatial data tasks, these metrics reached 0.93, 0.90, 0.92, and 0.91, respectively, further demonstrating their superior performance. Additionally, in ablation experiments comparing different attention mechanisms, the sliding-window attention mechanism outperformed standard self-attention and CBAM. For time-seriesdata tasks, it increased the F1-score from 0.71 and 0.83 to 0.93, while, for spatial data tasks, the F1-score improved from 0.69 and 0.81 to 0.91, highlighting the advantages of the proposed attention mechanism. Similarly, in ablation experiments on loss functions, the sliding loss function outperformed cross-entropy loss and focal loss, increasing the F1-score from 0.67 and 0.83 to 0.93 for time-series tasks and from 0.64 and 0.82 to 0.91 for spatial tasks. These results further demonstrated the significance of modeling local dynamic characteristics. The findings indicate that the proposed method achieves higher efficiency and lower accuracy loss while maintaining data privacy and security. This work provides crucial theoretical support and practical value for multimodal data processing in cloud computing environments. Conceptualization, W.C., Q.L., J.S. and C.L. ; Data curation, X.Z., Z.L. and H.Z. ; Funding acquisition, C.L. ; Methodology, W.C., Q.L. and J.S. ; Project administration, C.L. ; Resources, X.Z., Z.L. and H.Z. ; Software, W.C., Q.L., J.S. and H.Z. ; Supervision, Y.Q. and C.L. ; Validation, Z.L. and Y.Q. ; Visualization, X.Z. and Y.Q. ; Writing--original draft, W.C., Q.L., J.S., X.Z., Z.L., H.Z., Y.Q. and C.L. All authors have read and agreed to the published version of the manuscript. This research was funded by The National Key Research and Development Program of China (2024 YFC2607600). The data presented in this study are available on request from the corresponding author.