-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbayesian.wdl
81 lines (74 loc) · 2.97 KB
/
bayesian.wdl
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
version 1.0
task run_bayesian {
input {
File setup_os_script
File clone_repository_script
File copy_cromwell_logs_script
File copy_model_output_script
String name_of_this_model_run
String state
String start_date
String end_date
String model_git_repository
File install_model_script
File run_model_script
String model_output_folder
String model_output_file_types
String model_runtime_docker
Int scatter_levels
}
String model_output_file_listing = "${name_of_this_model_run}_output_files.txt"
command {
${setup_os_script}
${clone_repository_script} "${model_git_repository}"
${install_model_script} "${model_git_repository}"
${run_model_script} "${model_git_repository}" "${state}" "${start_date}" "${end_date}"
python3 ${copy_model_output_script} "${scatter_levels}" "${model_output_folder}" "${model_output_file_types}" "${model_output_file_listing}" "${name_of_this_model_run}"
${copy_cromwell_logs_script} "${scatter_levels}" "${model_output_folder}" "${name_of_this_model_run}"
}
runtime {
docker: "${model_runtime_docker}"
}
}
workflow bayesianWorkflow {
input {
File setup_os_script
File clone_repository_script
File copy_cromwell_logs_script
File copy_model_output_script
String name_of_this_model_run
Array[String] state_array
Array[String] start_date_array
Array[String] end_date_array
String model_git_repository
File install_model_script
File run_model_script
String model_output_folder
String model_output_file_types
String model_runtime_docker
}
scatter (state in state_array) {
scatter (start_date in start_date_array) {
scatter (end_date in end_date_array) {
call run_bayesian {
input:
setup_os_script = setup_os_script,
clone_repository_script = clone_repository_script,
copy_cromwell_logs_script = copy_cromwell_logs_script,
copy_model_output_script = copy_model_output_script,
name_of_this_model_run = name_of_this_model_run + "_" + state + "_" + start_date + "_" + end_date,
state = state,
start_date = start_date,
end_date = end_date,
model_git_repository = model_git_repository,
install_model_script = install_model_script,
run_model_script = run_model_script,
model_output_folder = model_output_folder,
model_output_file_types = model_output_file_types,
model_runtime_docker = model_runtime_docker,
scatter_levels = 3
}
}
}
}
}