shy-megabyte-7985
02/15/2024, 11:19 AM@batch decorator for example.
Does anyone have a workflow for varying the size of the ephemeral store - multiple job definitions and the flows which need higher ephemeral storage get routed to that particular job definition?ancient-application-36103
02/15/2024, 4:09 PM@batch . at the moment, you can use tmpfs to mount memory as disk https://docs.metaflow.org/scaling/data#using-metaflows3-for-in-memory-processingshy-megabyte-7985
02/15/2024, 4:20 PMshy-megabyte-7985
02/15/2024, 4:50 PM["linuxParameters"] in ["containerProperties"] in the job definition - it seems to be added if the platform is EC2 or spot, but not Fargate. I'm certainly getting an error:
File ".../metaflow/plugins/aws/batch/batch_client.py", line 302, in _register_job_definition
job_definition["containerProperties"]["linuxParameters"]["tmpfs"] = [
KeyError: 'linuxParameters'
On version 2.9.7 but couldn't see anything in later versions that would address itshy-megabyte-7985
02/15/2024, 5:13 PMdiff --git a/metaflow/plugins/aws/batch/batch_client.py b/metaflow/plugins/aws/batch/batch_client.py
index 8ef2607..fda1e4e 100644
--- a/metaflow/plugins/aws/batch/batch_client.py
+++ b/metaflow/plugins/aws/batch/batch_client.py
@@ -298,7 +298,8 @@ class BatchJob(object):
else:
+++ b/metaflow/plugins/aws/batch/batch_client.py
@@ -327,6 +327,9 @@ class BatchJob(object):
# default tmpfs behavior - <https://man7.org/linux/man-pages/man5/tmpfs.5.html>
tmpfs_size = int(float(memory)) / 2
+ if "linuxParameters" not in job_definition["containerProperties"]:
+ job_definition["containerProperties"]["linuxParameters"] = {}
+
job_definition["containerProperties"]["linuxParameters"]["tmpfs"] = [
{
"containerPath": tmpfs_path,ancient-application-36103
02/15/2024, 5:37 PMshy-megabyte-7985
02/15/2024, 5:38 PMshy-megabyte-7985
02/16/2024, 9:40 AMshy-megabyte-7985
02/16/2024, 9:49 AMshy-megabyte-7985
02/16/2024, 9:55 AMephmeral_storage parameter stronger. I've put in a new issue detailing this detailing thisshy-megabyte-7985
02/16/2024, 5:49 PMancient-application-36103
02/16/2024, 6:02 PMshy-megabyte-7985
02/26/2024, 3:13 PMshy-megabyte-7985
02/27/2024, 3:50 PM