We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c7188cf commit e919f11Copy full SHA for e919f11
utils/analyze2.awk
@@ -0,0 +1,34 @@
1
+#!/usr/bin/awk
2
+# @brief: extract fps and elpased time; calculate average of them
3
+
4
+BEGIN {
5
+ i = 1
6
+ sumFPS = 0
7
+ sumElapsed = 0
8
+}
9
10
+{
11
+ if (FNR == (3 * i - 2)) {
12
+ frames = $4
13
+ }
14
15
+ if (FNR == (3 * i - 1)) {
16
+ # print FNR, $4
17
+ sumElapsed += $4
18
19
20
+ if (FNR == (3 * i)) {
21
22
+ sumFPS += $4
23
+ ++i
24
25
26
27
28
29
+END {
30
+ # print i - 1
31
+ print "Frames : ", frames
32
+ print "Avg FPS : ", sumFPS / (i - 1)
33
+ print "Avg Elapsed Time: ", sumElapsed / (i - 1)
34
0 commit comments