Skip to content

Commit 77a4e19

Browse files
committed
additional format changes
1 parent f5acd70 commit 77a4e19

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

source/utils/profiler/scripts/parseMe.py

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,24 +5,24 @@
55
import os
66

77
parser = argparse.ArgumentParser(
8-
description="ADIOS json file parser step 2 (step 1 is use compare.sh to collect properties from json)"
8+
description="ADIOS json file parser inputs"
99
)
1010

1111
TAGS = {
1212
"input_dir": "dataDir", # key name for input direcory is "dataDir"
13-
"rank": "whichRank", ##
14-
"out": "plotPrefix", ##
15-
"showfig": "showFig", ##
13+
"rank": "whichRank", # which rank to peek profile
14+
"out": "plotPrefix", # for output file name
15+
"showfig": "showFig", # call plt.show or not
1616
"attr": "jsonAttr", # key refer to specific json attr
1717
"zero": "zeroIf", # key refer to a min number to be treated as 0. Spot the first rank with this value, and only plot up to this rank.
1818
"level": "levelAxis",
1919
}
2020

2121
TAGS_DEFAULT = {
2222
"input_dir": "outs/", # key name for input direcory defaults to "outs/"
23-
"rank": 0, ##
24-
"out": "plot", ##
25-
"showfig": "False", ##
23+
"rank": 0, #
24+
"out": "plot", #
25+
"showfig": "False", #
2626
"attr": "ES", # default json attr to look at is ES
2727
"zero": "0.000001", # ignore if smaller than
2828
"level": "False", # whether left/right axises (if both exist) should display same range
@@ -115,4 +115,3 @@ def parse_vars(items):
115115
if showFig_val not in ("true", "false"):
116116
parser.error(f"showFig must be 'True' or 'False', got '{command_options[TAGS['level']]}'")
117117
command_options[TAGS["showfig"]] = showFig_val == "true"
118-

source/utils/profiler/scripts/plotRanks.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -64,19 +64,20 @@ def processFile(inputFile, ax, color, tag):
6464
logScaleAxis = parseMe.command_options["logScale"]
6565

6666
jsonAttrStr = parseMe.command_options[parseMe.TAGS["attr"]]
67-
whichKind = "secs" # or 'nCalls'or 'MB'
67+
# 'secs' or 'nCalls' or 'MB'
68+
whichKind = "secs"
6869
if "whichKind" in parseMe.command_options:
6970
whichKind = "MB"
7071
for i in range(0, len(parseMe.args.ioTypes)):
7172
ioType = parseMe.args.ioTypes[i]
7273

7374
inputFile = (
74-
parseMe.command_options[parseMe.TAGS["input_dir"]]
75-
+ ioType
76-
+ "_"
77-
+ whichKind
78-
+ "_"
79-
+ jsonAttrStr
75+
parseMe.command_options[parseMe.TAGS["input_dir"]] +
76+
ioType +
77+
"_" +
78+
whichKind +
79+
"_" +
80+
jsonAttrStr
8081
)
8182
currLabel = ioType + " " + jsonAttrStr + " ( " + whichKind + " )"
8283
if i == 0:

0 commit comments

Comments
 (0)