@@ -93,6 +93,13 @@ class Ior(ExecutableApplication):
9393 use_mpi = True ,
9494 )
9595
96+ variant (
97+ "include_iter_foms" ,
98+ default = True ,
99+ values = [True , False ],
100+ description = "Whether to include per iteration FOMs in analyze" ,
101+ )
102+
96103 # FOMS
97104 # Match per iteration output in the format:
98105 # access bw(MiB/s) IOPS Latency(s) block(KiB) xfer(KiB) open(s) wr/rd(s) close(s) total(s) iter
@@ -112,38 +119,41 @@ class Ior(ExecutableApplication):
112119 ]
113120 units = ["MiB/s" , "count" , "s" , "KiB" , "KiB" , "s" , "s" , "s" , "s" , "count" ]
114121
115- iter_regex = ""
116- for metric in metrics [0 :3 ]: # iter is non-float
117- iter_regex += (
118- r"\s+(?P<" + metric + r">[0-9]+\.[0-9]+)"
119- ) # xfer => total
120- iter_regex += r"\s+(?P<" + metrics [3 ] + r">[0-9]+)" # handle block
121-
122- for metric in metrics [4 :- 1 ]: # iter is non-float
123- iter_regex += (
124- r"\s+(?P<" + metric + r">[0-9]+\.[0-9]+)"
125- ) # xfer => total
126- iter_regex += r"\s+(?P<" + metrics [- 1 ] + r">[0-9]+)\s*$" # handle iter
127-
128- access_regex = "(?P<access>(read|write))" + iter_regex
129- figure_of_merit_context (
130- "iter" , regex = access_regex , output_format = "iter {iter}"
131- )
132-
133122 log_str = Expander .expansion_str ("log_file" )
134123
135- # Capture Per Iteration Data
136- for metric , unit in zip (metrics , units ):
137- fom_regex = r"\w+" + iter_regex
138- figure_of_merit (
139- metric ,
140- log_file = log_str ,
141- fom_regex = fom_regex ,
142- group_name = metric ,
143- units = unit ,
144- contexts = ["iter" ],
124+ with when ("+include_iter_foms" ):
125+ iter_regex = ""
126+ for metric in metrics [0 :3 ]: # iter is non-float
127+ iter_regex += (
128+ r"\s+(?P<" + metric + r">[0-9]+\.[0-9]+)"
129+ ) # xfer => total
130+ iter_regex += r"\s+(?P<" + metrics [3 ] + r">[0-9]+)" # handle block
131+
132+ for metric in metrics [4 :- 1 ]: # iter is non-float
133+ iter_regex += (
134+ r"\s+(?P<" + metric + r">[0-9]+\.[0-9]+)"
135+ ) # xfer => total
136+ iter_regex += r"\s+(?P<" + metrics [- 1 ] + r">[0-9]+)\s*$" # handle iter
137+
138+ access_regex = "(?P<access>(read|write))" + iter_regex
139+ figure_of_merit_context (
140+ "iter" ,
141+ regex = access_regex ,
142+ output_format = "{access} iter {iter}" ,
145143 )
146144
145+ # Capture Per Iteration Data
146+ for metric , unit in zip (metrics , units ):
147+ fom_regex = r"\w+" + iter_regex
148+ figure_of_merit (
149+ metric ,
150+ log_file = log_str ,
151+ fom_regex = fom_regex ,
152+ group_name = metric ,
153+ units = unit ,
154+ contexts = ["iter" ],
155+ )
156+
147157 # Capture Summary Data in the format:
148158 # Operation Max(MiB) Min(MiB) Mean(MiB) StdDev Max(OPs) Min(OPs) Mean(OPs) StdDev Mean(s) Stonewall(s) Stonewall(MiB) Test# #Tasks tPN reps fPP reord reordoff reordrand seed segcnt blksiz xsize aggs(MiB) API RefNum
149159 # write 612.90 560.70 596.63 14.15 612.90 560.70 596.63 14.15 0.85865 NA NA 0 2 2 10 0 0 1 0 0 16 16777216 1048576 512.0 POSIX 0
0 commit comments