Amazon EC2 G4 instances, originally launched in 2019 with NVIDIA GPUs (G4dn) and 2020 with AMD GPUs (G4ad), are currently the most cost-effective and versatile GPU instances for deploying machine learning models and for graphics-intensive applications. 

The latest generation of NVIDIA GPU-based instances, Amazon EC2 G5 and Amazon EC2 G5g was released in late 2021.

Amazon EC2 G5 is powered by NVIDIA’s A10G Tensor Core GPUs and second generation AMD EPYC processors and delivers up to 3x better performance for graphics-intensive applications and machine learning inference and up to 3.3x higher performance for machine learning training compared to Amazon EC2 G4dn instances.

Amazon EC2 G5g are the first Arm-based instances to feature GPU acceleration, and are powered by AWS Graviton2 processors and feature NVIDIA T4G Tensor Core GPUs.

Amazon EC2 G5g instances provide the best price performance in Amazon EC2 for graphics workloads such as Android game streaming — reducing development effort and lowering the cost-per-stream per hour by up to 30%.

Use cases for Amazon EC2 G4 instances

They are currently the most cost-effective and versatile GPU instances for deploying machine learning models and for graphics-intensive applications such as:

  • Image classification 
  • Object detection 
  • Recommendation engines
  • Automated speech recognition
  • Language translation
  • Remote graphics workstations
  • Video transcoding
  • Photo-realistic design
  • Game streaming in the cloud

Cloud cost management from Anodot automatically recommends when an older-generation instance (like one in the EC2 G3 family) should be upgraded to a G4 or G5 instance for your compute-intensive workload.

Amazon EC2 G4dn NVIDIA-based GPU instances

Amazon G4dn instances provide the latest generation NVIDIA T4 Tensor Core GPUs, AWS custom second generation Intel® Xeon® Scalable (Cascade Lake) processors, up to 100 Gbps of networking throughput, and up to 1.8 TB of local NVMe storage.

When to use Amazon EC2 G4dn instances

G4dn instances are the best option for small-scale machine learning (ML) training and GPU-based ML inference due to included hardware optimizations like Tensor Cores. 

Amazon EC2 G4dn instances are ideal for deploying machine learning models in production such as:

  • Image classification
  • Object detection
  • Recommendation engines
  • Automated speech recognition
  • Language translation 

Furthermore, G4dn instances are best suited for graphics applications that require NVIDIA libraries such as CUDA, CuDNN, and NVENC.

  • Remote graphics workstations
  • Video transcoding 
  • Photo-realistic design
  • Game streaming in the cloud

Amazon EC2 G4dn.xlarge and G4dn.2xlarge details and pricing options

API Nameg4dn.xlargeg4dn.2xlarge
TypeSingle GPU VMSingle GPU VM
Memory16.0 GiB32.0 GiB
vCPUs4 vCPUs8 vCPUs
Storage125 GB NVMe SSD225 GB NVMe SSD
Network PerformanceUp to 25 GigabitUp to 10 Gigabit
Linux On-Demand pricing$0.1315 per Hour per vCPU$0.0940 per Hour per vCPU
Linux Reserved pricing$0.0828 per Hour per vCPU$0.0592 per Hour per vCPU
Linux Spot pricing$0.0394 per Hour per vCPU$0.0292 per Hour per vCPU
Windows On-Demand pricing$0.1775 per Hour per vCPU$0.1400 per Hour per vCPU
Windows Reserved pricing$0.1288 per Hour per vCPU$0.1052 per Hour per vCPU
Windows Spot pricing$0.0854 per Hour per vCPU$0.0742 per Hour per vCPU
* Prices shown are for the US East (Northern Virginia) AWS Region. Prices for reserved instances are for 1-year “Partial Upfront” payment option.

Amazon EC2 G4ad AMD-based GPU instances

In December 2020, AWS released the Amazon EC2 G4ad instance subfamily — powered by AMD Radeon Pro V520 GPUs and second-generation AMD EPYC processors with up to 2.4 TB of local NVMe storage — that delivers up to 40% better price performance over comparable GPU-based instances for graphics intensive applications such as virtual workstations and game streaming.

In July 2021, AWS expanded the G4ad subfamily with the g4ad.xlarge and g4ad.2xlarge sizes, which are designed to be cost-effective for workloads that don’t need the high vCPU and system memory that current larger G4ad instance sizes offer — rounding out their AMD offering and providing the lowest cost GPU instance in the AWS Cloud.

When to use Amazon EC2 G4ad instances

G4ad instances are ideal for high performance graphic workloads with no dependency on NVIDIA libraries, which can benefit from the improved price and performance.

  • Animation
  • Remote graphics workstations
  • Video transcoding
  • Photo-realistic design
  • Game streaming in the cloud

Amazon EC2 G4ad.xlarge and G4ad.2xlarge details and pricing options

API Nameg4ad.xlargeg4ad.2xlarge
TypeSingle GPU VMSingle GPU VM
Memory16.0 GiB32.0 GiB
vCPUs4 vCPUs8 vCPUs
Storage150 GB NVMe SSD300 GB NVMe SSD
Network PerformanceUp to 10 GigabitUp to 10 Gigabit
Linux On-Demand pricing$0.0946 per Hour per vCPU$0.0676 per Hour per vCPU
Linux Reserved pricing$0.0568 per Hour per vCPU$0.0406 per Hour per vCPU
Linux Spot pricing$0.0284 per Hour per vCPU$0.0204 per Hour per vCPU
Windows On-Demand pricing$0.1406 per Hour per vCPU$0.1136 per Hour per vCPU
Windows Reserved pricing$0.1028 per Hour per vCPU$0.0866 per Hour per vCPU
Windows Spot pricing$0.0744 per Hour per vCPU$0.0663 per Hour per vCPU

* Prices shown are for the US East (Northern Virginia) AWS Region. Prices for reserved instances are for 1-year “Partial Upfront” payment option.

Amazon EC2 G4dn and G4ad product details and pricing

InstanceGPUvCPUMemory (GiB)GPU Memory (GiB)Instance Storage (GB)Network Bandwidth (Gbps)EBS Bandwidth (Mbps)Linux On-Demand hourly rate for US East (N. Virginia)
g4dn.xlarge1 (NVIDIA)4 (Intel)16161 x 125 NVMe SSDUp to 25Up to 3.5$0.53
g4dn.2xlarge1 (NVIDIA)8 (Intel)32161 x 225 NVMe SSDUp to 25Up to 3.5$0.75
g4dn.4xlarge1 (NVIDIA)16 (Intel)64161 x 225 NVMe SSDUp to 254.8$1.20
g4dn.8xlarge1 (NVIDIA)32 (Intel)128161 x 900 NVMe SSD509.5$2.18
g4dn.12xlarge4 (NVIDIA)48 (Intel)192641 x 900 NVMe SSD509.5$3.91
g4dn.16xlarge1 (NVIDIA)64 (Intel)256161 x 900 NVMe SSD509.5$4.35
g4dn.metal8 (NVIDIA)96 (Intel)3841282 x 900 NVMe SSD10019.0$7.82
g4ad.xlarge1 (AMD)4 (AMD)1681 x 150 NVMe SSDUp to 10Up to 3$0.38
g4ad.2xlarge1 (AMD)8 (AMD)3281 x 300 NVMe SSDUp to 10Up to 3$0.54
g4ad.4xlarge1 (AMD)16 (AMD)6481 x 600 NVMe SSDUp to 10Up to 3$0.87
g4ad.8xlarge2 (AMD)32 (AMD)128161 x 1200 NVMe SSD153.0$1.73
g4ad.16xlarge4 (AMD)64 (AMD)256321 x 2400 NVMe SSD256.0$3.47

G4dn and G4ad instances are available through the following AWS purchasing and discount options:

  • On-Demand Instances
  • Savings Plans
  • Reserved Instances
  • Spot Instances

Written by Anodot

Anodot leads in Autonomous Business Monitoring, offering real-time incident detection and innovative cloud cost management solutions with a primary focus on partnerships and MSP collaboration. Our machine learning platform not only identifies business incidents promptly but also optimizes cloud resources, reducing waste. By reducing alert noise by up to 95 percent and slashing time to detection by as much as 80 percent, Anodot has helped customers recover millions in time and revenue.

Start optimizing your cloud costs today!

Connect with one of our cloud cost management specialists to learn how Anodot can help your organization control costs, optimize resources and reduce cloud waste.