facebookresearch / swav
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
  • 38% duplication:
    • 1,581 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 616 duplicated lines
  • 41 duplicates
system38% (616 lines)
Duplication per Extension
py38% (616 lines)
Duplication per Component (primary)
ROOT52% (574 lines)
src8% (42 lines)
Longest Duplicates
The list of 20 longest duplicates.
See data for all 41 duplicates...
Size#FoldersFilesLinesCode
39 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
129:175 (13%)
137:183 (14%)
view
30 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
102:131 (11%)
104:133 (12%)
view
20 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
77:105 (6%)
84:112 (7%)
view
18 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
106:127 (6%)
115:136 (6%)
view
18 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
296:313 (6%)
332:349 (6%)
view
17 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
300:325 (6%)
259:284 (7%)
view
16 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
80:98 (6%)
74:92 (6%)
view
14 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
152:166 (5%)
143:157 (5%)
view
14 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
44:61 (4%)
43:60 (5%)
view
12 x 2 src
src
resnet50.py
resnet50.py
33:45 (4%)
83:95 (4%)
view
9 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
231:239 (3%)
246:254 (3%)
view
9 x 2 src
src
resnet50.py
resnet50.py
59:70 (3%)
108:119 (3%)
view
9 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
23:33 (3%)
24:34 (3%)
view
9 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
194:207 (3%)
194:207 (3%)
view
8 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
27:37 (2%)
26:36 (3%)
view
8 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
327:334 (3%)
287:294 (3%)
view
7 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
378:384 (2%)
337:343 (2%)
view
7 x 2 ROOT
ROOT
main_deepclusterv2.py
main_swav.py
222:230 (2%)
235:243 (2%)
view
7 x 2 ROOT
ROOT
eval_linear.py
eval_semisup.py
364:373 (2%)
323:332 (2%)
view
7 x 2 ROOT
ROOT
eval_semisup.py
main_deepclusterv2.py
120:126 (2%)
130:136 (2%)
view
Duplicated Units
The list of top 1 duplicated units.
See data for all 1 unit duplicate
Size#FoldersFilesLinesCode
9 x 2 src
src
resnet50.py
resnet50.py
0:0 
0:0 
view