-
Notifications
You must be signed in to change notification settings - Fork 12
/
batchRunTemplate.mapleaf
97 lines (80 loc) · 5.86 KB
/
batchRunTemplate.mapleaf
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
ExampleFlightCase{
simDefinitionFile ./MAPLEAF/Examples/Simulations/AdaptTimeStep.mapleaf
ParameterOverrides{ # (Optional)
SimControl.EndCondition Time
SimControl.EndConditionValue 1
# SimControl.plot will always be set to None (unless overridden here)
# SimControl.loggingLevel will always be set to 2 (unless overridden here)
# SimControl.RocketPlot will always be set to 'Off' (unless overridden here)
}
ExpectedFinalValues{ # (Optional)
# Full/partial log column names or regex. Must match only a single column
# Note that the program will first try to find these columns in the simulationLog, then in the forceEvaluation log.
# Columns that exist in both logs (ex. PositionX(m)), will be taken from the mainSimulationLog
PositionX -2.768
Time(s) 0.9856
# If the value is "Record", no check will be performed, but the ending value of the specified parameter will be recorded.
# If no ExpectedResults are provided, final Position and Velocity X/Y/Z attributes will be auto-recorded
# Recorded data will be written to a new file: [origninalBatchFile]_newExpectedResultsRecorded.mapleaf
Mach Record
}
PlotsToGenerate{ # (Optional - plots saved to file)
SamplePlot{
# Generate a plot of MAPLEAF's results + comparison data
columnsToPlot PositionZ ^VelocityZ # Full/partial log column names and/or regex
saveLocation ./MAPLEAF/Examples/V&V/SamplePlot.pdf # Always saves .pdf plots
xColumnName Time(s) # (Optional) specify which column will be plotted on the x-axis (default is Time(s))
lineFormat :b :k # (Optional) matplotlib-style line format
xLabel Time (s) # (Optional)
yLabel Altitude (m) # (Optional)
xLimits 0 1 # (Optional)
yLimits 0 100 # (Optional)
xScale linear # (Optional) linear or log
yScale linear # (Optional) linear or log
scalingFactor 1 # (Optional) Use to invert data or convert units - scales MAPLEAF's results by a constant factor
offset 0 # (Optional) Add scalar to MAPLEAF's results
legendLabel Altitude Sim, Velocity Sim # (Optional) Label of MAPLEAF line - enter None for no label
overwrite True # (Optional)
# Each subdictionary is assumed to contain comparison data. Can have any number of these
flightComparisonData{ # (Optional)
# Comparison data file should be a simple .csv table
# First row should have headers, each subsequent row should have scalar numeric entries
file ./MAPLEAF/Examples/V&V/sampleComparisonData.csv
columnsToPlot posZ velZ # Full/partial .csv column names and/or regex
xColumnName Time(s) # (Optional) - supply if not 'Time(s)'
lineFormat --b --k # (Optional) matplotlib-style line format
lineColors \#003f5c red # Provide a matplotlib-compatible colour argument ex. red or,
# if hexadecimal, make sure to escape the hash symbol to avoid it being treated as a comment
# Color options: https://matplotlib.org/3.1.0/gallery/color/named_colors.html
legendLabel Altitude Comparion, Velocity Comparison # (Optional), otherwise uses column headers
validationData True # (optional) Can use to exclude certain sets of comparison data from validation metrics
}
}
}
}
ExampleWindTunnelCase{
# Each test case can only be a ParameterSweep (Wind Tunnel) case or an ExpectedFinalValues (Full Flight) case.
# If both subdictionaries are present, the ParameterSweep mode takes priority
ParameterSweep{
velocitySweep{ # SubDict name can be anything, as long as it does not contrain "Results"
sweptParameter Rocket.velocity # Can be any parameter in the simulation definition file
parameterValues (0 0 100), (0 0 200), (0 0 300) # Provide COMMA-separated list of values - can also just be a single value
# Can also specify a range of values to loop over firstValue:numSteps:finalValue
# Scalar example: 0:50:1.75
# Vector example: (0 0 100):50:(0 0 300)
}
MachResults{ # Results dictionary names must contain "Results"
column Mach # Any logged column of results
# COMMA-separated list of scalar expected result values OR 'Record'
# Number of expectedValues must match number (and order) of parameterValues
# If the result is supposed to remain constant, can also just provide a single value
expectedValues 0.2955, 0.5886, 0.8822
}
DragResults{ # Can have an arbitrary number of these dictionaries
column AeroCFZ
expectedValues Record
}
}
#### Parameter Sweep cases ignore the ExpectedFinalValues{} dictionary (expected results included in ParameterSweep{} ) ####
#### Rest same as for a flight case ####
}