-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcrew_controllers.R
More file actions
68 lines (61 loc) · 1.84 KB
/
Copy pathcrew_controllers.R
File metadata and controls
68 lines (61 loc) · 1.84 KB
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
# Default local Crew controller setup.
# Simple so-called local crew-controller setup, that works with the get_tar_resources() helper, and
# fits within a 16 CPU, 256 GB RAM machine.
controller_list <- list(
crew::crew_controller_local(
name = "local-light",
workers = 4
),
crew::crew_controller_local(
name = "local-heavy",
workers = 2,
crashes_max = 1
)
)
controller_resources_tibble <- tibble::tribble(
~controller_name , ~cores , ~RAM_GB , ~gpus ,
"local-light" , 1 , 16 , 0 ,
"local-heavy" , 6 , 60 , 0
)
# Example HPC-scheduler (here SLURM) setup with tiered controllers.
# The resources table controls routing; the matching controller options below
# are where CPU, memory, and GPU requests are submitted to SLURM.
#
# controller_resources_tibble <- tibble::tribble(
# ~controller_name, ~cores, ~RAM_GB, ~gpus,
# "light", 1, 16, 0,
# "heavy", 15, 240, 0,
# "gpu", 15, 120, 1
# )
#
# controller_list <- list(
# crew.cluster::crew_controller_slurm(
# name = "light",
# workers = 30,
# options_cluster = crew.cluster::crew_options_slurm(
# cpus_per_task = 1,
# memory_gigabytes_required = 16
# )
# ),
# crew.cluster::crew_controller_slurm(
# name = "heavy",
# workers = 10,
# options_cluster = crew.cluster::crew_options_slurm(
# cpus_per_task = 15,
# memory_gigabytes_required = 240
# )
# ),
# crew.cluster::crew_controller_slurm(
# name = "gpu",
# workers = 2,
# options_cluster = crew.cluster::crew_options_slurm(
# cpus_per_task = 15,
# memory_gigabytes_required = 120,
# script_lines = "#SBATCH --gres=gpu:1"
# )
# )
# )
list(
controller_resources_tibble = controller_resources_tibble,
controller_list = controller_list
)