Currently, software defect-prediction technology is being extensively researched in the design of metrics. However, the research objects are mainly limited to coarse-grained entities such as classes, files, and packages, and there is a wide range of defects that are difficult to predict in actual situations. To further explore the information between sequences of method calls and to learn the code semantics and syntactic structure between methods, we generated a method-call sequence that retains the code context structure information and the token sequence representing semantic information. We embedded the token sequence into the method-call sequence and encoded it into a fixed-length real-valued vector. We then built a defect-prediction model based on the transformer, which maps the code-vector representation containing the method-call sequences to a low-dimensional vector space to generate semantic features and syntactic structure features and also predicts the defect density of the method-call sequence. We conducted experiments on 10 open-source projects using the ELFF dataset. The experimental results show that the method-call sequence-level prediction effect is better than the class-level effect, and the prediction results are more stable than those of the method level. The mean absolute error (MAE) value of our approach was 8% lower than that of the other deep-learning methods.
Spectrum-based fault localization (SBFL), a widely recognized technique in automated fault localization, has limited effectiveness due to its disregard for the internal information of the program under test suites. To overcome this limitation, a novel TrustRank-based fault localization (TRFL) technique is introduced. TRFL enhances traditional SBFL by incorporating internal data dependencies of the program under the test suite, thereby providing a more comprehensive analysis. It constructs a node-weighted program execution network and employs the TrustRank algorithm to analyze network centrality and re-rank program entities based on their suspiciousness. Furthermore, a bidirectional TrustRank algorithm (Bi-TRFL) is extended that takes into account the influence relationship between network nodes for more accurate fault localization. When applied to large-scale datasets with real faults, such as Defects4J, TRFL, and Bi-TRFL, it significantly outperforms traditional SBFL methods in fault localization. They demonstrate up to 40% and 13% improvement in Top-1 and Top-5 rankings, respectively, proving their robustness and efficiency with minimal sensitivity to related parameters.
Multivariate sensor anomaly warning requires models that learn normal temporal dynamics,capture cross-sensor dependencies, and make online decisions without test-label feedback. In UAV monitoring, this task is further complicated by nonlinear sensor coupling, cross-flight distribution drift, and scarce abnormal annotations. We propose TCNGATRE, a Temporal Convolutional Network with Graph Attention Refinement, for temporal–graph forecasting and anomaly warning. TCNGATRE uses a TCN backbone for future sensor prediction and interleaves graph attention refinement modules that fuse a MIC-based data-derived knowledge representation of sensor dependencies with a sample-adaptive dynamic graph, enabling the model to represent both stable and time-varying sensor relations. Forecasting and temporalincrement residuals are integrated into anomaly scores, smoothed over time, and converted into label-free warning decisions through per-flight SPOT threshold adaptation. Experiments on ALFA, GPSData, and Simulate show that TCNGATRE achieves the best F1-score across all three datasets under a unified protocol, demonstrating strong generalization and reliable threshold-based decision performance for UAV sensor anomaly warning. Code release: https://github.com/ZCchou/TCNGATRE.
Suspicious training samples differ in label-error risk, making uniform deletion or relabeling potentially harmful. We propose the CLIP-based Sample Type Diagnosis and Modification Approach (CSTDMA), which diagnoses samples before classifier training using CLIP class support. Label confidence, label confidence margin, and multi-view label support categorize samples as reliable, mislabeled, ambiguous, or boundary. CSTDMA retains reliable samples, corrects mislabeled samples, downweights ambiguous samples, and preserves boundary labels while applying a class-margin constraint. Experiments on three datasets with synthetic label noise and one with human annotation noise assign 85.95%–99.55% of noisy samples to mislabeled or ambiguous categories. CSTDMA achieves the highest mean final accuracy and macro-F1 across all four datasets, improving macro-F1 by 1.25–4.05 percentage points over the strongest comparison method. Controlled experiments further show that differentiated treatment outperforms uniform deletion and relabeling.