-
Notifications
You must be signed in to change notification settings - Fork 6
/
parsing.jl
60 lines (52 loc) · 1.98 KB
/
parsing.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
function build_arg_table()
settings = ArgParseSettings(
description="\033[32mPooled Screen Optimizer\033[0m\n\n\n\n" *
"\033[31mHigh performance simulation and exploratory analysis code "*
"for studying the behavior of pooled screens under common " *
"experimental conditions.\033[0m"
)
@add_arg_table! settings begin
"config"
action = :command
help = "run simulation using a YAML config file (easy)"
"exp"
action = :command
help = "run modified simulation from src/exps/ (hard)"
"ls"
action = :command
help = "list all modified simulations available"
end
settings["ls"].description = "Prints out the available modified simulation " *
"code. Simply prints out files in src/exps/."
@add_arg_table! settings["exp"] begin
"--debug"
help = "Use smaller parameter space for diagnosing issues"
action = :store_true
"--addprocs", "-p"
help = "Add additional processors"
arg_type = Int
default = 0
"analysis_file"
help = "Run a modified simulation from the src/exps directory"
required = true
"output_file"
help = "File to output results to [.CSV, .TSV, etc]"
required = true
end
settings["exp"].description = "Run a modified simulation. Much more" *
" flexible than using the configuration files, but also more complex"
@add_arg_table! settings["config"] begin
"--no-graph", "-g"
help = "Suppress graphical output"
action = :store_true
"config_file"
help = "path to YAML configuration file to load"
required = true
"output_dir"
help = "path to output directory"
required = true
end
settings["config"].description
settings.epilog = read(normpath(joinpath(@__DIR__,"LICENSE")), String)
return settings
end