creamy-stone-99746
02/22/2023, 9:48 PMc4.large, c4.xlarge, c4.2xlarge, c4.4xlarge, c4.8xlarge These instances don't have GPUs. Whats the recommended way of getting GPUs in aws batch?average-beach-28850
02/22/2023, 9:52 PMcreamy-stone-99746
02/22/2023, 9:55 PMaverage-beach-28850
02/22/2023, 9:58 PMaverage-beach-28850
02/22/2023, 9:59 PMcreamy-stone-99746
02/22/2023, 10:01 PMcreamy-stone-99746
02/22/2023, 10:02 PMaverage-beach-28850
02/22/2023, 10:05 PMcreamy-stone-99746
02/22/2023, 10:05 PMaverage-beach-28850
02/22/2023, 10:07 PMMinVCPUBatch is set to 0.. very easy to spend a lot of š° on gpu instances sitting aroundcreamy-stone-99746
02/22/2023, 10:07 PMcreamy-stone-99746
02/22/2023, 10:13 PMaverage-beach-28850
02/22/2023, 10:28 PMcreamy-stone-99746
02/22/2023, 10:29 PMMinVCPUBatch to 0 should I also set DesiredVCPUBatch to 0?average-beach-28850
02/22/2023, 10:30 PMcreamy-stone-99746
02/22/2023, 10:31 PMfresh-laptop-72652
02/22/2023, 11:12 PMAL2_x86_64_GPU) as part of the EC2 Configuration of the Batch Compute environment
If you run into issues, I think it's pretty common for people to split out GPU instance types into their own dedicated compute environment to specify that and also ensure that CPU workloads don't inadvertently get provisioned onto those expensive GPU instancescreamy-stone-99746
02/23/2023, 12:18 AM2023-02-22 15:05:18.529 [232/train/1431 (pid 50626)] Essential container in task exited This could be a transient error. Use @retry to retry.
2023-02-22 15:05:18.996 [232/train/1431 (pid 50626)]
2023-02-22 15:05:16.584 [232/train/1431 (pid 50626)] [820bb282-697e-406d-ab23-78824bbc44cb] File "/metaflow/training_flow.py", line 4, in <module>
2023-02-22 15:05:16.584 [232/train/1431 (pid 50626)] [820bb282-697e-406d-ab23-78824bbc44cb] import numpy as np
2023-02-22 15:05:16.584 [232/train/1431 (pid 50626)] [820bb282-697e-406d-ab23-78824bbc44cb] ModuleNotFoundError: No module named 'numpy'
2023-02-22 15:05:19.321 [232/train/1431 (pid 50626)] Task failed.fresh-laptop-72652
02/23/2023, 12:44 AM@conda step decorator (or @conda_base flow decorator) to define the python environment
⢠if not using one of those decorators, you would need to prebake it into the base python environment of your docker image used in Batchfresh-laptop-72652
02/23/2023, 1:00 AMComputeEnvironment resource, give it another name like gpu-... , specify some GPU instance types like p3/g4dn, if you want it to be on-demand/spot, and so on before also adding it to a Batch job queue
Then in your code you could specify it as part of the @batch decorator, e.g. @batch(cpu=8, memory=64000, gpu=1, queue="gpu")fresh-laptop-72652
02/23/2023, 1:02 AMfresh-laptop-72652
02/23/2023, 1:20 AM