Discovering Repetitive Code Changes in Python-based ML Systems

Here we present four supplementary materials for the paper submitted to ICSE-2022

Item 1 - Examples for each analyzed pattern and trends that shown in the Table 1 in the paper - Analyzed Patterns and Trends

Item 2 - Raw dataset for all the code patterns detected by R-CPatMiner

Pattern Group Projects Commits Change Graphs Total unique patterns Total instances Multi author patterns Single author patterns Links
ICSE 1000 4,166,520 349,406 28,323 100866 17941(63%) 10271(36%)
  • https://mlcodepatterns.github.io/icse_sp8/directory.html
  • Item 3 - Validated Refactoring dataset detected by Python version of RefactoringMiner (Table 2)

    Refactoring Kind Evidences Precision True positives Total manual validations
    Add Parameter Link 100.0% 192 192
    Rename Method Link 96.32% 183 190
    Rename Class Link 99.2% 124 125
    Remove Parameter Link 97.56% 160 164
    Move Method Link 96.3% 156 162
    Rename Parameter Link 93.59% 146 156
    Move And Rename Method Link 88.08% 133 151
    Move And Rename Class Link 96.67% 116 120
    Reorder Parameter Link 98.11% 104 106
    Extract Method Link 97.03% 98 101
    Extract Class Link 98.82% 84 85
    Move Class Link 100.0% 160 160
    Push Down Method Link 89.36% 84 94
    Pull Up Method Link 86.46% 83 96
    Parameterize Variable Link 87.23% 82 94
    Merge Parameter Link 91.07% 51 56
    Extract Subclass Link 100.0% 45 45
    Extract Superclass Link 95.24% 40 42
    Extract And Move Method Link 100.0% 37 37
    Inline Method Link 85.71% 24 28
    Split Parameter Link 91.67% 22 24
    Extract Variable Link 100.0% 10 10
    Change Parameter Type Link 90.0% 9 10
    Change Variable Type Link 100.0% 5 5
    Move And Inline Method Link 100.0% 1 1
    Inline Variable Link in progress 0 0
    Merge Variable Link in progress 0 0
    Rename Attribute Link in progress 0 0
    Rename Variable Link in progress 0 0
    +Total 95% 2149 2254

    Item 4 - All the tools present in the paper

  • RefactoringMiner
  • R-CPATMiiner
  • JavaFyPy