aws-samples / sagemaker-custom-project-templates
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
  • 97% duplication:
    • 67,337 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 65,653 duplicated lines
  • 1,477 duplicates
system97% (65,653 lines)
Duplication per Extension
py98% (63,492 lines)
yml70% (1,160 lines)
yaml67% (1,001 lines)
Duplication per Component (primary)
mlops-template-gitlab/lambda_functions99% (62,272 lines)
multi-branch-mlops-train/cloud_formation62% (1,001 lines)
mlops-template-gitlab/seedcode70% (532 lines)
batch-inference/seedcode59% (257 lines)
multi-branch-mlops-train/pipelines79% (251 lines)
batch-inference100% (244 lines)
asynchronous-inference-endpoint100% (244 lines)
multi-model-endpoint98% (232 lines)
encrypted-buckets54% (210 lines)
asynchronous-inference-endpoint/seedcode83% (200 lines)
multi-model-endpoint/seedcode94% (186 lines)
mlops-template-gitlab13% (24 lines)
multi-branch-mlops-train0% (0 lines)

Duplication Between Components (50+ lines)

G mlops-template-gitlab/seedcode mlops-template-gitlab/seedcode multi-branch-mlops-train/pipelines multi-branch-mlops-train/pipelines mlops-template-gitlab/seedcode--multi-branch-mlops-train/pipelines 503 multi-model-endpoint/seedcode multi-model-endpoint/seedcode mlops-template-gitlab/seedcode--multi-model-endpoint/seedcode 320 asynchronous-inference-endpoint asynchronous-inference-endpoint batch-inference batch-inference asynchronous-inference-endpoint--batch-inference 488 multi-model-endpoint multi-model-endpoint asynchronous-inference-endpoint--multi-model-endpoint 443 encrypted-buckets encrypted-buckets asynchronous-inference-endpoint--encrypted-buckets 211 batch-inference--multi-model-endpoint 443 batch-inference--encrypted-buckets 211 batch-inference/seedcode batch-inference/seedcode batch-inference/seedcode--mlops-template-gitlab/seedcode 476 batch-inference/seedcode--multi-model-endpoint/seedcode 248 asynchronous-inference-endpoint/seedcode asynchronous-inference-endpoint/seedcode asynchronous-inference-endpoint/seedcode--mlops-template-gitlab/seedcode 326 asynchronous-inference-endpoint/seedcode--batch-inference/seedcode 254 asynchronous-inference-endpoint/seedcode--multi-model-endpoint/seedcode 336 encrypted-buckets--multi-model-endpoint 183

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 1,477 duplicates...
Size#FoldersFilesLinesCode
8271 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
8:8438 (100%)
8:8438 (100%)
view
2048 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
idnadata.py
idnadata.py
3:2050 (100%)
3:2050 (100%)
view
1210 x 2 mlops-template-gitlab/la...arset_normalizer/assets
mlops-template-gitlab/la...arset_normalizer/assets
__init__.py
__init__.py
10:1219 (100%)
10:1219 (100%)
view
725 x 2 mlops-template-gitlab/la...rigger/urllib3/packages
mlops-template-gitlab/la...gitlab/urllib3/packages
six.py
six.py
31:1077 (100%)
31:1077 (100%)
view
576 x 2 mlops-template-gitlab/la...igger/gitlab/v4/objects
mlops-template-gitlab/la...itlab/gitlab/v4/objects
projects.py
projects.py
10:1049 (100%)
10:1049 (100%)
view
559 x 2 mlops-template-gitlab/la...ipeline-trigger/urllib3
mlops-template-gitlab/la...-checkin-gitlab/urllib3
connectionpool.py
connectionpool.py
12:1078 (100%)
12:1078 (100%)
view
527 x 2 mlops-template-gitlab/la...pipeline-trigger/gitlab
mlops-template-gitlab/la...e-checkin-gitlab/gitlab
mixins.py
mixins.py
21:976 (100%)
21:976 (100%)
view
527 x 2 mlops-template-gitlab/la...pipeline-trigger/gitlab
mlops-template-gitlab/la...e-checkin-gitlab/gitlab
client.py
client.py
31:988 (100%)
31:988 (100%)
view
525 x 2 mlops-template-gitlab/la...trigger/urllib3/contrib
mlops-template-gitlab/la...-gitlab/urllib3/contrib
securetransport.py
securetransport.py
73:922 (100%)
73:922 (100%)
view
501 x 2 mlops-template-gitlab/la...peline-trigger/requests
mlops-template-gitlab/la...checkin-gitlab/requests
models.py
models.py
22:966 (100%)
22:966 (100%)
view
498 x 2 mlops-template-gitlab/la...peline-trigger/requests
mlops-template-gitlab/la...checkin-gitlab/requests
utils.py
utils.py
31:1013 (100%)
31:1013 (100%)
view
483 x 2 mlops-template-gitlab/la...ipeline-trigger/urllib3
mlops-template-gitlab/la...-checkin-gitlab/urllib3
response.py
response.py
10:821 (100%)
10:821 (100%)
view
453 x 2 mlops-template-gitlab/la...gger/charset_normalizer
mlops-template-gitlab/la...tlab/charset_normalizer
constant.py
constant.py
8:471 (100%)
8:471 (100%)
view
421 x 2 mlops-template-gitlab/la...gger/charset_normalizer
mlops-template-gitlab/la...tlab/charset_normalizer
md.py
md.py
6:570 (100%)
6:570 (100%)
view
420 x 2 mlops-template-gitlab/la...gger/charset_normalizer
mlops-template-gitlab/la...tlab/charset_normalizer
api.py
api.py
4:546 (100%)
4:546 (100%)
view
383 x 2 mlops-template-gitlab/la...eline-trigger/gitlab/v4
mlops-template-gitlab/la...heckin-gitlab/gitlab/v4
cli.py
cli.py
30:497 (100%)
30:497 (100%)
view
375 x 2 mlops-template-gitlab/la...ontrib/_securetransport
mlops-template-gitlab/la...ontrib/_securetransport
bindings.py
bindings.py
36:519 (100%)
36:519 (100%)
view
345 x 2 mlops-template-gitlab/la...ipeline-trigger/urllib3
mlops-template-gitlab/la...-checkin-gitlab/urllib3
connection.py
connection.py
17:569 (100%)
17:569 (100%)
view
335 x 2 mlops-template-gitlab/la...peline-trigger/requests
mlops-template-gitlab/la...checkin-gitlab/requests
sessions.py
sessions.py
19:781 (100%)
19:781 (100%)
view
328 x 2 mlops-template-gitlab/la...igger/gitlab/v4/objects
mlops-template-gitlab/la...itlab/gitlab/v4/objects
users.py
users.py
6:507 (100%)
6:507 (100%)
view
Duplicated Units
The list of top 20 duplicated units.
See data for all 839 unit duplicates...
Size#FoldersFilesLinesCode
221 x 2 mlops-template-gitlab/la.../charset_normalizer/cli
mlops-template-gitlab/la.../charset_normalizer/cli
normalizer.py
normalizer.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view
103 x 2 mlops-template-gitlab/la...b-pipeline-trigger/idna
mlops-template-gitlab/la...ode-checkin-gitlab/idna
uts46data.py
uts46data.py
0:0 
0:0 
view