facebookresearch / fairmotion
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
  • 7% duplication:
    • 5,841 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 441 duplicated lines
  • 36 duplicates
system7% (441 lines)
Duplication per Extension
py7% (441 lines)
Duplication per Component (primary)
fairmotion/viz7% (115 lines)
fairmotion/tasks/motion_prediction12% (98 lines)
fairmotion/tasks/clustering12% (84 lines)
fairmotion/data6% (50 lines)
fairmotion/models7% (32 lines)
fairmotion/tasks/motion_graph6% (30 lines)
fairmotion/core2% (16 lines)
fairmotion/ops3% (16 lines)
ROOT0% (0 lines)
fairmotion/tasks/changepoint_detection0% (0 lines)
fairmotion/tasks0% (0 lines)
fairmotion0% (0 lines)
fairmotion/utils0% (0 lines)
Longest Duplicates
The list of 20 longest duplicates.
See data for all 36 duplicates...
Size#FoldersFilesLinesCode
14 x 2 fairmotion/tasks/motion_prediction
fairmotion/tasks/motion_prediction
test.py
training.py
181:194 (7%)
177:190 (6%)
view
14 x 2 fairmotion/tasks/motion_prediction
fairmotion/tasks/motion_prediction
test.py
training.py
210:223 (7%)
212:225 (6%)
view
11 x 2 fairmotion/data
fairmotion/data
amass_dip.py
bvh.py
97:107 (7%)
10:20 (4%)
view
11 x 2 fairmotion/tasks/clustering/features
fairmotion/tasks/clustering/features
utils.py
utils.py
141:151 (7%)
166:176 (7%)
view
10 x 2 fairmotion/models
fairmotion/models
transformer.py
transformer.py
54:65 (7%)
117:128 (7%)
view
10 x 2 fairmotion/tasks/clustering/features
fairmotion/tasks/clustering/features
kinetic.py
kinetic.py
35:44 (16%)
50:59 (16%)
view
9 x 2 fairmotion/tasks/clustering/features
fairmotion/tasks/clustering/features
utils.py
utils.py
107:115 (6%)
167:175 (6%)
view
9 x 2 fairmotion/tasks/motion_prediction
fairmotion/tasks/motion_prediction
test.py
training.py
124:132 (4%)
42:50 (4%)
view
9 x 2 fairmotion/viz
fairmotion/viz
gl_render.py
gl_render.py
153:164 (1%)
174:185 (1%)
view
9 x 2 fairmotion/viz
fairmotion/viz
gl_render.py
gl_render.py
76:84 (1%)
88:96 (1%)
view
9 x 2 fairmotion/tasks/motion_graph
fairmotion/tasks/motion_graph
motion_graph.py
motion_graph.py
281:289 (2%)
392:405 (2%)
view
9 x 2 fairmotion/tasks/clustering/features
fairmotion/tasks/clustering/features
utils.py
utils.py
107:115 (6%)
142:150 (6%)
view
8 x 2 fairmotion/core
fairmotion/core
motion.py
motion.py
309:316 (2%)
467:474 (2%)
view
8 x 2 fairmotion/ops
fairmotion/ops
conversions.py
conversions.py
126:133 (5%)
144:151 (5%)
view
8 x 2 fairmotion/viz
fairmotion/viz
gl_render.py
gl_render.py
129:136 (1%)
138:145 (1%)
view
7 x 2 fairmotion/data
fairmotion/data
amass_dip.py
frankmocap.py
100:106 (4%)
18:24 (23%)
view
7 x 2 fairmotion/data
fairmotion/data
bvh.py
bvh.py
168:174 (2%)
188:194 (2%)
view
7 x 2 fairmotion/tasks/clustering
fairmotion/tasks/clustering
clustering.py
clustering.py
77:83 (4%)
105:112 (4%)
view
7 x 2 fairmotion/data
fairmotion/data
bvh.py
bvh.py
178:184 (2%)
188:194 (2%)
view
7 x 2 fairmotion/data
fairmotion/data
bvh.py
frankmocap.py
13:19 (2%)
18:24 (23%)
view
Duplicated Units
The list of top 2 duplicated units.
See data for all 2 unit duplicates...
Size#FoldersFilesLinesCode
8 x 2 fairmotion/data
fairmotion/data
bvh.py
amass_dip.py
0:0 
0:0 
view
7 x 2 fairmotion/models
fairmotion/models
transformer.py
transformer.py
0:0 
0:0 
view