-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstartup.jl
70 lines (56 loc) · 1.87 KB
/
startup.jl
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
# deactivate plot GUI, which is not available in Docker
ENV["GKSwstype"] = "100"
# instantiate project
import Pkg
Pkg.activate(@__DIR__)
Pkg.instantiate()
const TEST_LONG = true # if true, the longer test suite is run; may take > 1 hour
# and requires at least 16gb RAM
global const TARGET_FOLDER = "results"
const RESULTS_FILE = "results.csv"
function main()
if !isdir(TARGET_FOLDER)
mkdir(TARGET_FOLDER)
end
global io = open(joinpath(TARGET_FOLDER, RESULTS_FILE), "w")
print(io, "benchmark,instance,result,time\n")
println("Running AFF benchmarks...")
# Heat 3D benchmark
println("###\nRunning Heat 3D benchmark\n###")
include("models/Heat3D/heat3d_benchmark.jl")
# Clamped Beam benchmark
println("###\nRunning Clamped Beam benchmark\n###")
include("models/Clamped/clamped_benchmark.jl")
# Spacecraft benchmark
if TEST_LONG
println("###\nRunning Spacecraft benchmark\n###")
include("models/Spacecraft/Spacecraft_benchmark.jl")
end
# Powertrain benchmark
println("###\nRunning Powertrain benchmark\n###")
include("models/Powertrain/Powertrain_benchmark.jl")
# Platoon benchmark
println("###\nRunning Platoon benchmark\n###")
include("models/Platoon/Platoon_benchmark.jl")
# Gearbox benchmark
println("###\nRunning Gearbox benchmark\n###")
include("models/Gearbox/gearbox_benchmark.jl")
# Brake benchmark
if TEST_LONG
println("###\nRunning Electromechanic Brake benchmark\n###")
include("models/EMBrake/embrake_benchmark.jl")
end
# Random benchmark
println("###\nRunning Random benchmark\n###")
try
include("models/Random/random_benchmark.jl")
catch e
showerror(stdout, e)
println()
end
print(io, "\n")
println("Finished running benchmarks.")
close(io)
nothing
end
main()