Skip to content

Commit 4ef219a

Browse files
committed
str
1 parent 29dcb0b commit 4ef219a

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

snakemake_executor_plugin_aws_batch/batch_job_builder.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,17 +77,23 @@ def build_job_definition(self):
7777
"jobRoleArn": self.settings.job_role,
7878
"privileged": True,
7979
"resourceRequirements": [
80-
{"type": BATCH_JOB_RESOURCE_REQUIREMENT_TYPE.VCPU.value, "value": vcpu},
80+
{
81+
"type": BATCH_JOB_RESOURCE_REQUIREMENT_TYPE.VCPU.value,
82+
"value": vcpu_str,
83+
},
8184
{
8285
"type": BATCH_JOB_RESOURCE_REQUIREMENT_TYPE.MEMORY.value,
83-
"value": mem,
86+
"value": mem_str,
8487
},
8588
],
8689
}
8790

88-
if int(gpu) > 0:
91+
if gpu > 0:
8992
container_properties["resourceRequirements"].append(
90-
{"type": BATCH_JOB_RESOURCE_REQUIREMENT_TYPE.GPU.value, "value": gpu}
93+
{
94+
"type": BATCH_JOB_RESOURCE_REQUIREMENT_TYPE.GPU.value,
95+
"value": gpu_str,
96+
}
9197
)
9298

9399
timeout = {"attemptDurationSeconds": self.settings.task_timeout}

0 commit comments

Comments
 (0)