pytorch / benchmark
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
  • 39% duplication:
    • 52,862 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 20,660 duplicated lines
  • 165,182 duplicates
system39% (20,660 lines)
Duplication per Extension
cfg99% (11,745 lines)
py20% (7,741 lines)
ipynb46% (745 lines)
yaml19% (395 lines)
yml43% (34 lines)
Duplication per Component (primary)
torchbenchmark/models/yolov381% (11,898 lines)
torchbenchmark/models/tacotron263% (2,328 lines)
torchbenchmark/models/LearningToPaint72% (1,780 lines)
torchbenchmark/models/dlrm25% (1,289 lines)
torchbenchmark/models/pytorch_CycleGAN_and_pix2pix20% (459 lines)
torchbenchmark/models/moco43% (414 lines)
scripts67% (326 lines)
torchbenchmark/models/Super_SloMo16% (234 lines)
torchbenchmark/models/demucs7% (157 lines)
torchbenchmark/models/nvidia_deeprecommender14% (150 lines)
torchbenchmark/models/pytorch_stargan21% (146 lines)
torchbenchmark/models/pyhpc_isoneutral_mixing41% (146 lines)
torchbenchmark/models/pyhpc_turbulent_kinetic_energy34% (137 lines)
torchbenchmark/util/framework9% (88 lines)
torchbenchmark/models/timm_efficientdet18% (78 lines)
torchbenchmark/models/Background_Matting6% (76 lines)
torchbenchmark/models/soft_actor_critic6% (76 lines)
torchbenchmark/e2e_models/hf_bert22% (65 lines)
torchbenchmark/score8% (64 lines)
torchbenchmark/util/torchtext_legacy5% (52 lines)
torchbenchmark/models/speech_transformer5% (52 lines)
torchbenchmark/models/drq9% (48 lines)
torchbenchmark9% (38 lines)
torchbenchmark/models/attention_is_all_you_need_pytorch3% (38 lines)
torchbenchmark/util3% (35 lines)
torchbenchmark/models/BERT_pytorch4% (30 lines)
torchbenchmark/models/tts_angular6% (30 lines)
torchbenchmark/models/resnet50_quantized_qat48% (23 lines)
torchbenchmark/models/mobilenet_v2_quantized_qat51% (23 lines)
torchbenchmark/util/backends30% (21 lines)
torchbenchmark/models/pyhpc_equation_of_state5% (16 lines)
torchbenchmark/models/hf_Bart71% (15 lines)
torchbenchmark/models/hf_T568% (15 lines)
torchbenchmark/models/hf_Albert71% (15 lines)
torchbenchmark/models/hf_GPT271% (15 lines)
torchbenchmark/models/maml_omniglot20% (15 lines)
torchbenchmark/models/hf_DistilBert71% (15 lines)
torchbenchmark/models/hf_Reformer71% (15 lines)
torchbenchmark/models/hf_Longformer71% (15 lines)
torchbenchmark/models/hf_Bert71% (15 lines)
torchbenchmark/models/hf_BigBird71% (15 lines)
torchbenchmark/models/maml4% (15 lines)
torchbenchmark/models/vision_maskrcnn9% (13 lines)
torchbenchmark/models/detectron2_maskrcnn18% (13 lines)
install_utils75% (12 lines)
torchbenchmark/models/opacus_cifar1012% (8 lines)
torchbenchmark/models/pytorch_unet1% (8 lines)
torchbenchmark/models/fastNLP_Bert2% (8 lines)
torchbenchmark/models/squeezenet1_125% (7 lines)
torchbenchmark/models/densenet12141% (7 lines)
torchbenchmark/models/mobilenet_v3_large42% (6 lines)
torchbenchmark/models/dcgan3% (6 lines)
torchbenchmark/models/pytorch_struct4% (6 lines)
torchbenchmark/models/vgg1642% (6 lines)
torchbenchmark/models/mobilenet_v242% (6 lines)
torchbenchmark/models/timm_nfnet42% (6 lines)
torchbenchmark/models/resnext50_32x4d42% (6 lines)
torchbenchmark/models/timm_resnest42% (6 lines)
torchbenchmark/models/timm_regnet42% (6 lines)
torchbenchmark/models/resnet5042% (6 lines)
torchbenchmark/models/alexnet42% (6 lines)
torchbenchmark/models/timm_vovnet42% (6 lines)
torchbenchmark/models/timm_vision_transformer42% (6 lines)
torchbenchmark/models/resnet1842% (6 lines)
torchbenchmark/models/mnasnet1_042% (6 lines)
torchbenchmark/models/shufflenet_v2_x1_042% (6 lines)
torchbenchmark/models/timm_efficientnet42% (6 lines)
ROOT0% (0 lines)
torchbenchmark/score/configs0% (0 lines)
torchbenchmark/microbenchmarks/nvfuser0% (0 lines)
torchbenchmark/e2e_models/fambench_xlmr0% (0 lines)
components/_impl/tasks0% (0 lines)
components/_impl0% (0 lines)
components/_impl/workers0% (0 lines)
components0% (0 lines)

Duplication Between Components (50+ lines)

G torchbenchmark/models/pyhpc_isoneutral_mixing torchbenchmark/models/pyhpc_isoneutral_mixing torchbenchmark/models/pyhpc_turbulent_kinetic_energy torchbenchmark/models/pyhpc_turbulent_kinetic_energy torchbenchmark/models/pyhpc_isoneutral_mixing--torchbenchmark/models/pyhpc_turbulent_kinetic_energy 164 torchbenchmark/models/timm_efficientdet torchbenchmark/models/timm_efficientdet torchbenchmark/util/framework torchbenchmark/util/framework torchbenchmark/models/timm_efficientdet--torchbenchmark/util/framework 110 torchbenchmark/models/drq torchbenchmark/models/drq torchbenchmark/models/soft_actor_critic torchbenchmark/models/soft_actor_critic torchbenchmark/models/drq--torchbenchmark/models/soft_actor_critic 96 torchbenchmark/models/LearningToPaint torchbenchmark/models/LearningToPaint torchbenchmark/models/pytorch_CycleGAN_and_pix2pix torchbenchmark/models/pytorch_CycleGAN_and_pix2pix torchbenchmark/models/LearningToPaint--torchbenchmark/models/pytorch_CycleGAN_and_pix2pix 66 torchbenchmark/models/Background_Matting torchbenchmark/models/Background_Matting torchbenchmark/models/Background_Matting--torchbenchmark/models/pytorch_CycleGAN_and_pix2pix 52

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 50 longest duplicates.
See data for all 165,182 duplicates...
Size#FoldersFilesLinesCode
639 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
1:819 (77%)
1:819 (69%)
view
597 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
108:829 (64%)
108:829 (62%)
view
589 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
108:819 (71%)
108:819 (61%)
view
540 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:684 (80%)
23:684 (77%)
view
519 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
7:633 (78%)
1:635 (77%)
view
519 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
1:635 (77%)
1:635 (77%)
view
508 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
21:641 (55%)
21:641 (75%)
view
506 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:641 (55%)
23:641 (72%)
view
504 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
27:633 (76%)
21:635 (55%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:635 (74%)
23:635 (71%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
29:633 (75%)
23:635 (74%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:635 (74%)
23:635 (74%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:635 (74%)
23:635 (74%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:635 (74%)
23:635 (71%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
29:633 (75%)
23:635 (74%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
29:633 (75%)
23:635 (71%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:635 (74%)
23:635 (55%)
view
502 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:635 (74%)
23:635 (55%)
view
497 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
1:602 (76%)
1:602 (76%)
view
491 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:622 (73%)
25:630 (67%)
view
491 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
29:620 (74%)
25:630 (67%)
view
491 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:622 (73%)
25:630 (67%)
view
491 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:622 (53%)
25:630 (67%)
view
491 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
25:630 (67%)
23:622 (73%)
view
491 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
25:630 (67%)
23:622 (70%)
view
467 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
10:573 (72%)
10:573 (69%)
view
467 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
16:573 (70%)
10:573 (72%)
view
467 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
10:573 (72%)
16:573 (70%)
view
467 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
10:573 (69%)
10:573 (72%)
view
457 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
21:573 (70%)
21:573 (50%)
view
457 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
21:573 (50%)
21:573 (70%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:573 (65%)
23:573 (70%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:573 (70%)
23:573 (67%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:573 (67%)
23:573 (70%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:573 (70%)
23:573 (65%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
25:581 (62%)
23:573 (70%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:573 (70%)
23:573 (67%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:573 (70%)
25:581 (62%)
view
455 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
23:573 (67%)
23:573 (70%)
view
344 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
747:1155 (35%)
747:1155 (35%)
view
183 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
599:821 (27%)
567:788 (28%)
view
183 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
567:788 (28%)
599:821 (27%)
view
162 x 2 torchbenchmark/models/dlrm
torchbenchmark/models/dlrm
376:621 (40%)
856:1102 (20%)
view
126 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
432:584 (15%)
453:604 (13%)
view
126 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
223:370 (15%)
243:390 (15%)
view
126 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
432:584 (15%)
453:604 (13%)
view
126 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
432:584 (13%)
453:604 (13%)
view
126 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
432:584 (15%)
453:604 (15%)
view
126 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
243:390 (15%)
223:370 (13%)
view
126 x 2 torchbenchmark/models/yolov3/cfg
torchbenchmark/models/yolov3/cfg
432:584 (13%)
453:604 (13%)
view
Duplicated Units
The list of top 16 duplicated units.
See data for all 16 unit duplicates...
Size#FoldersFilesLinesCode
58 x 2 torchbenchmark/models/Le...aint/baseline_modelfree
torchbenchmark/models/LearningToPaint/baseline
0:0 
0:0 
view
40 x 2 scripts
scripts
0:0 
0:0 
view
20 x 2 torchbenchmark/models/Le...line_modelfree/Renderer
torchbenchmark/models/Le...Paint/baseline/Renderer
0:0 
0:0 
view
21 x 2 torchbenchmark/util/framework/vision
torchbenchmark/util/backends
0:0 
0:0 
view
17 x 2 torchbenchmark/models/Le...aint/baseline_modelfree
torchbenchmark/models/LearningToPaint/baseline
0:0 
0:0 
view
17 x 2 torchbenchmark/models/ta...waveglow/tacotron2/text
torchbenchmark/models/tacotron2/text
0:0 
0:0 
view
30 x 2 torchbenchmark/models/Le...aseline_modelfree/utils
torchbenchmark/models/Le...gToPaint/baseline/utils
0:0 
0:0 
view
13 x 2 torchbenchmark/models/Le.../baseline_modelfree/DRL
torchbenchmark/models/LearningToPaint/baseline/DRL
0:0 
0:0 
view
13 x 2 torchbenchmark/models/tacotron2
torchbenchmark/models/tacotron2/waveglow/tacotron2
0:0 
0:0 
view
12 x 2 torchbenchmark/models/Le...line_modelfree/Renderer
torchbenchmark/models/Le...Paint/baseline/Renderer
0:0 
0:0 
view
12 x 2 torchbenchmark/models/Le.../baseline_modelfree/DRL
torchbenchmark/models/LearningToPaint/baseline/DRL
0:0 
0:0 
view
11 x 2 torchbenchmark/models/Le.../baseline_modelfree/DRL
torchbenchmark/models/LearningToPaint/baseline/DRL
0:0 
0:0 
view
37 x 2 torchbenchmark/models/tacotron2/waveglow/tacotron2
torchbenchmark/models/tacotron2
0:0 
0:0 
view
11 x 2 torchbenchmark/models/ta...waveglow/tacotron2/text
torchbenchmark/models/tacotron2/text
0:0 
0:0 
view
9 x 2 torchbenchmark/models/tacotron2/waveglow/tacotron2
torchbenchmark/models/tacotron2
0:0 
0:0 
view
7 x 2 torchbenchmark/models/tacotron2/waveglow/tacotron2
torchbenchmark/models/tacotron2
0:0 
0:0 
view