facebookresearch / SLIP
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 16% duplication:
    • 3,072 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 496 duplicated lines
  • 28 duplicates
system16% (496 lines)
Duplication per Extension
py16% (496 lines)
Duplication per Component (primary)
ROOT20% (352 lines)
beit_finetuning10% (144 lines)
redcaps0% (0 lines)

Duplication Between Components (50+ lines)

G beit_finetuning beit_finetuning ROOT ROOT beit_finetuning--ROOT 234

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 20 longest duplicates.
See data for all 28 duplicates...
Size#FoldersFilesLinesCode
37 x 2 ROOT
ROOT
run_with_submitit.py
run_with_submitit_linear.py
61:112 (48%)
61:112 (48%)
view
23 x 2 ROOT
ROOT
run_with_submitit.py
run_with_submitit_linear.py
26:58 (30%)
26:58 (30%)
view
23 x 2 beit_finetuning
ROOT
run_with_submitit_finetune.py
run_with_submitit_linear.py
87:115 (29%)
84:112 (30%)
view
23 x 2 beit_finetuning
ROOT
run_with_submitit_finetune.py
run_with_submitit.py
87:115 (29%)
84:112 (30%)
view
23 x 2 beit_finetuning
ROOT
utils.py
utils.py
218:254 (5%)
25:61 (17%)
view
15 x 2 ROOT
ROOT
main.py
main_linear.py
406:423 (4%)
393:410 (4%)
view
14 x 2 beit_finetuning
ROOT
run_with_submitit_finetune.py
run_with_submitit_linear.py
34:52 (17%)
33:51 (18%)
view
14 x 2 beit_finetuning
ROOT
run_with_submitit_finetune.py
run_with_submitit.py
34:52 (17%)
33:51 (18%)
view
14 x 2 beit_finetuning
beit_finetuning
modeling_finetune.py
modeling_finetune.py
87:103 (4%)
208:224 (4%)
view
13 x 2 beit_finetuning
ROOT
run_with_submitit_finetune.py
run_with_submitit_linear.py
63:84 (16%)
61:82 (17%)
view
13 x 2 beit_finetuning
ROOT
run_with_submitit_finetune.py
run_with_submitit.py
63:84 (16%)
61:82 (17%)
view
13 x 2 ROOT
ROOT
main.py
main_linear.py
434:450 (3%)
410:426 (4%)
view
12 x 2 ROOT
ROOT
eval_zeroshot.py
main.py
168:182 (8%)
462:476 (3%)
view
10 x 2 ROOT
ROOT
models.py
models.py
176:185 (4%)
213:222 (4%)
view
10 x 2 ROOT
ROOT
main_linear.py
main_linear.py
286:299 (3%)
332:345 (3%)
view
7 x 2 ROOT
ROOT
main.py
main_linear.py
77:83 (2%)
58:64 (2%)
view
7 x 2 ROOT
ROOT
run_with_submitit.py
run_with_submitit_linear.py
116:126 (9%)
116:126 (9%)
view
7 x 2 beit_finetuning
ROOT
utils.py
utils.py
282:290 (1%)
81:89 (5%)
view
6 x 2 ROOT
ROOT
main.py
main_linear.py
472:479 (1%)
451:458 (1%)
view
6 x 2 ROOT
ROOT
utils.py
utils.py
128:134 (4%)
174:181 (4%)
view
Duplicated Units
The list of top 7 duplicated units.
See data for all 7 unit duplicates...
Size#FoldersFilesLinesCode
12 x 2 ROOT
ROOT
eval_zeroshot.py
main.py
0:0 
0:0 
view
9 x 2 ROOT
ROOT
models.py
models.py
0:0 
0:0 
view
8 x 3 beit_finetuning
ROOT
ROOT
run_with_submitit_finetune.py
run_with_submitit.py
run_with_submitit_linear.py
0:0 
0:0 
0:0 
view
10 x 2 beit_finetuning
ROOT
utils.py
utils.py
0:0 
0:0 
view
6 x 3 beit_finetuning
ROOT
ROOT
run_with_submitit_finetune.py
run_with_submitit.py
run_with_submitit_linear.py
0:0 
0:0 
0:0 
view
6 x 3 beit_finetuning
ROOT
ROOT
run_with_submitit_finetune.py
run_with_submitit.py
run_with_submitit_linear.py
0:0 
0:0 
0:0 
view
6 x 3 beit_finetuning
ROOT
ROOT
run_with_submitit_finetune.py
run_with_submitit.py
run_with_submitit_linear.py
0:0 
0:0 
0:0 
view