-
Notifications
You must be signed in to change notification settings - Fork 4
/
MP_performance.txt
154 lines (127 loc) · 3.8 KB
/
MP_performance.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
#############################################
Seiral_execution:
extract_vertex_mp
time: 0.0
get_vertical_line_mp
time: 0.007972478866577148
generate_naive_polygon_mp
time: 0.06489014625549316
refine_quad_cells_mp
time: 0.0019757747650146484
generate_node_set_mp
time: 0.007008790969848633
generate_path_mp
time: 0.001008749008178711
#############################################
MP_naive:
extract_vertex_mp
time: 1.8201844692230225
get_vertical_line_mp
time: 2.8649649620056152
generate_naive_polygon_mp
time: 3.1596450805664062
refine_quad_cells_mp
time: 14.845367670059204
generate_node_set_mp
time: 8.617656230926514
generate_path_mp
time: 12.870764970779419
#############################################
MP_Manager_Pool:
extract_vertex_mp
time: 0.010967254638671875
get_vertical_line_mp
time: 0.0498809814453125
generate_naive_polygon_mp
time: 0.13163256645202637
refine_quad_cells_mp
time: 0.5465390682220459
generate_node_set_mp
time: 0.03690600395202637
generate_path_mp
time: 0.06582427024841309
#############################################
MP_Add_Unit_to_func(generate_naive_polygon_mp)_and_func(refine_quad_cells_mp)
The reason that other funcs doesn't involve unit:
extract_vertex_mp: already use Pool.map()
get_vertical_line_mp: need to sort based on the x-value, adding unit needs to use Queue or Manager. Unnecessary memory operation.
generate_node_set_mp: same as above
generate_path_mp: sort based on the shortest path sequence, others same as above
extract_vertex_mp
time: 0.012777566909790039
get_vertical_line_mp
time: 0.04588055610656738
generate_naive_polygon_mp
time: 0.08850908279418945
refine_quad_cells_mp
time: 0.43067455291748047
generate_node_set_mp
time: 0.0400240421295166
generate_path_mp
time: 0.06182122230529785
#############################################
MP_Add_Unit_to_func(generate_node_set_mp)
The reason that other funcs doesn't involve unit:
extract_vertex_mp: already use Pool.map()
get_vertical_line_mp: need to sort based on the x-value, adding unit needs to use Queue or Manager. Unnecessary memory operation.
Will use more shared data if add unit parameter
generate_path_mp: sort based on the shortest path sequence, others same as above
Will use more shared data if add unit parameter
Improve a little.
extract_vertex_mp
time: 0.012952327728271484
get_vertical_line_mp
time: 0.04485511779785156
generate_naive_polygon_mp
time: 0.08941411972045898
refine_quad_cells_mp
time: 0.4919850826263428
generate_node_set_mp
time: 0.038895606994628906
generate_path_mp
time: 0.059841156005859375
#############################################
Final Comparation
################
Serial execution
################
############ Inside generate_cells function ############
extract_vertex_se
time: 0.0
get_vertical_line_se
time: 0.015609025955200195
generate_naive_polygon_se
time: 0.07808542251586914
refine_quad_cells_se
time: 0.0
########################################################
generate_cells_se
time: 0.09369444847106934
generate_node_set_se
time: 0.015627622604370117
generate_path_se
time: 0.0
Total time: 0.12496781349182129
path generated
################
Parallel execution
################
############ Inside generate_cells function ############
extract_vertex_mp
time: 0.0
get_vertical_line_mp
time: 0.04686307907104492
generate_naive_polygon_mp
time: 0.09372949600219727
refine_quad_cells_mp
time: 0.42177653312683105
########################################################
generate_cells_mp
time: 0.5936136245727539
generate_node_set_mp
time: 0.062489986419677734
generate_path_mp
time: 0.06249570846557617
Total time without process start and end: 0.7498338222503662
Total time: 2.202620506286621
path generated