の続きをしたいので、まとめていく。
計算機: Google Cloud Pricing Calculator
Tokyo
- Provisioning model はすべて Spot (Preemptible VM)
- Threads per core = 2
で、月額 10,000 円と 20,000 円の予算でどれだけ使えるか計算してみた:
Series | disk type | size | cost | 10000 | 20000 |
---|---|---|---|---|---|
n1-highmem-4+T4 | standard PD | 100 | 5.2+(0.06+0.07)*hrs | ||
n1-highmem-4+T4 | standard PD | 200 | 10.4+(0.06+0.07)*hrs | ||
a2-highgpu-1g | standard PD | 300 | 15.6+(0.22+0.88)*hrs | ||
a2-highgpu-1g | standard PD | 400 | 20.8+(0.22+0.88)*hrs | 48 | 115 |
a2-highgpu-1g | balanced PD | 300 | 39.0+(0.22+0.88)*hrs | 31 | 99 |
a2-highgpu-1g | SSD PD | 300 | 66.3+(0.22+0.88)*hrs |
- Threads per core: Set the number of threads per core | Compute Engine Documentation | Google Cloud
- Configure disks: Configure disks to meet performance requirements | Compute Engine Documentation | Google Cloud
Regular インスタンスの場合は
Series | disk type | size | cost | 10000 | 20000 |
---|---|---|---|---|---|
n1-highmem-4+T4 | balanced PD | 300 | 39.0+(0.30+0.37)*hrs |
Oregon
- Provisioning model はすべて Spot (Preemptible VM)
- Threads per core = 2
Series | disk type | size | cost | 10000 | 20000 |
---|---|---|---|---|---|
n1-highmem-4+T4 | standard PD | 70 | 1.6+(0.05+0.11)*hrs | ||
n1-highmem-4+T4 | standard PD | 100 | 2.8+(0.05+0.11)*hrs | ||
n1-highmem-4+T4 | standard PD | 200 | 6.8+(0.05+0.11)*hrs | ||
n1-highmem-4+V100 | balanced PD | 300 | 30.0+(0.05+0.74)*hrs | 55 | 149 |
a2-highgpu-1g | standard PD | 300 | 10.8+(0.22+0.88)*hrs | ||
a2-highgpu-1g | standard PD | 400 | 14.8+(0.22+0.88)*hrs | 53 | 121 |
a2-highgpu-1g | balanced PD | 300 | 31.1+(0.22+0.88)*hrs | 39 | 106 |
a2-highgpu-1g | SSD PD | 300 | 51.0+(0.22+0.88)*hrs |
$1 = ¥135
ディスクの比較
参考 (AWS EC2)
A100 x 8
インスタンス | 時間単価 | vCPU | メモリ | ストレージ | ネットワーク |
---|---|---|---|---|---|
p3.2xlarge | 4.194 USD | 8 | 61 GiB | ESB のみ | 10 Gbps |
p4d.24xlarge | 44.92215 USD | 96 | 1152 GiB | 8 x 1000 SSD | 400 Gbps |
ハイパフォーマンスブロックストレージの料金 – Amazon EBS の料金 – Amazon Web Services
- 汎用 SSD (gp3) - ストレージ: 0.08USD/GB 月
なので、
- p3.2xlarge:
24.0+4.194*hrs
: 11 hrs/10000, 29hrs/20000 - p3.2xlarge:
44.92215*hrs
: 1 hrs/10000, 3hrs/20000
作成コマンド
- gcloud compute instances create | Google Cloud CLI Documentation
- Operating system details | Compute Engine Documentation | Google Cloud
- https://console.cloud.google.com/marketplace/details/click-to-deploy-images/deeplearning
- Overview | Compute Engine Documentation | Google Cloud
- Install GPU drivers | Compute Engine Documentation | Google Cloud
- CUDA Toolkit 11.8 Downloads | NVIDIA Developer
gcloud compute --project=プロジェクトID instances create ml-dev --zone=asia-northeast1-a --image-family=ubuntu-2004-lts --image-project=ubuntu-os-cloud --subnet=VPCで作成したサブネット名 --network-tier=PREMIUM --no-restart-on-failure --maintenance-policy=TERMINATE --preemptible --deletion-protection --machine-type=a2-highgpu-1g --labels=env=ml-dev --create-disk="name=ディスク名,image-family=ubuntu-2004-lts,image-project=ubuntu-os-cloud,size=300GB,type=pd-balanced,boot=yes"
- プロジェクトID:
gcloud projects list
で調べられる。