aws-samples / amazon-rekognition-video-analyzer
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
  • 3% duplication:
    • 9,484 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 336 duplicated lines
  • 17 duplicates
system3% (336 lines)
Duplication per Extension
yaml34% (142 lines)
py18% (114 lines)
js<1% (80 lines)
Duplication per Component (primary)
aws-infra34% (142 lines)
web-ui/src/js<1% (80 lines)
client47% (64 lines)
ROOT13% (44 lines)
lambda/imageprocessor5% (6 lines)
web-ui/src0% (0 lines)
web-ui0% (0 lines)
lambda/framefetcher0% (0 lines)
Longest Duplicates
The list of 17 longest duplicates.
See data for all 17 duplicates...
Size#FoldersFilesLinesCode
32 x 2 client
client
video_cap.py
video_cap_ipcam.py
32:71 (50%)
38:78 (44%)
view
17 x 2 aws-infra
aws-infra
aws-infra-cfn.yaml
aws-infra-cfn.yaml
135:151 (4%)
203:219 (4%)
view
17 x 2 aws-infra
aws-infra
aws-infra-cfn.yaml
aws-infra-cfn.yaml
99:115 (4%)
191:207 (4%)
view
15 x 2 ROOT
ROOT
build.py
build.py
151:169 (4%)
191:209 (4%)
view
15 x 2 aws-infra
aws-infra
aws-infra-cfn.yaml
aws-infra-cfn.yaml
157:171 (3%)
225:239 (3%)
view
13 x 2 aws-infra
aws-infra
aws-infra-cfn.yaml
aws-infra-cfn.yaml
85:97 (3%)
174:186 (3%)
view
8 x 2 web-ui/src/js
web-ui/src/js
axios.js
axios.js
1810:1818 (<1%)
1923:1931 (<1%)
view
8 x 2 aws-infra
aws-infra
aws-infra-cfn.yaml
aws-infra-cfn.yaml
348:355 (1%)
381:388 (1%)
view
8 x 2 web-ui/src/js
web-ui/src/js
axios.js
axios.js
1542:1550 (<1%)
1606:1614 (<1%)
view
7 x 2 ROOT
ROOT
build.py
build.py
174:180 (2%)
215:221 (2%)
view
6 x 2 client
lambda/imageprocessor
video_cap.py
imageprocessor.py
59:64 (9%)
86:91 (5%)
view
6 x 2 client
lambda/imageprocessor
video_cap_ipcam.py
imageprocessor.py
66:71 (8%)
86:91 (5%)
view
6 x 2 aws-infra
aws-infra
aws-infra-cfn.yaml
aws-infra-cfn.yaml
117:122 (1%)
134:139 (1%)
view
6 x 2 web-ui/src/js
web-ui/src/js
axios.js
axios.js
1762:1768 (<1%)
1881:1887 (<1%)
view
6 x 2 web-ui/src/js
web-ui/src/js
axios.js
axios.js
1704:1709 (<1%)
1723:1728 (<1%)
view
6 x 2 web-ui/src/js
web-ui/src/js
vue.js
vue.js
5973:5978 (<1%)
6004:6009 (<1%)
view
6 x 2 web-ui/src/js
web-ui/src/js
axios.js
axios.js
1775:1781 (<1%)
1894:1900 (<1%)
view