#11: Cloud Computing + 🍕

Introduction

Welcome to our session today which is about Cloud Computing.

The goals for today are to:

  1. Explain what cloud computing is and how it can be useful.
  2. Give two demos including one where we speed up some Blender renders.

Before Cloud Computing

Definitions Please!

According to International Organization for Standards (ISO) there are 5 key factors:

  1. On-demand self service: unilateral and without human interaction.
  2. Broad network access: Available everywhere, not just corporate / home LANs.
  3. Resource pooling: Provider’s resources are pooled and shared.
  4. Rapid elasticity: rapid provisioning and releasing; can appear unlimited.
  5. Measured service: access to resources is monitored, logged and billed.

Advantages

In a way, cloud computing is kind of a return to that older model from the 60s and 70s, putting the power of ‘big iron’ or mainframes into the hands of anyone who’s got a few bucks (or a few thousand).

Disadvantages

Use Cases

Astral Projection

Cloud Computing is often pitched at big companies but the key point of this talk is that there’s no reason you can’t use them for your own personal projects or assignments (though you should never NEED to use a paid service for your coursework!). It’s nice to know it’s possible to access this power / hardware on a temporary basis and that’s why we’re covering it in Missing Semester.

Here are a few uses for cloud computing that might be more relevant to students:

So how does this all work?

We’re going to be demonstrating the concepts above via Amazon’s Elastic Compute Cloud (EC2) but first a few notes:

  1. This is not an advertisement for Amazon! Many other cloud providers (Google, Hetzner, Linode, Azure) exist. Amazon’s is just the oldest and the one I’m most comfortable with.
  2. The interface for AWS is a bit hairy; there might be simpler solutions out there!
  3. We’re mostly going to be talking about rentable virtual computers with EC2. However, EC2 is only a part of ‘cloud computing’ / Amazon Web Services (AWS); AWS has over 200 other services including EBS, S3, Lambda (serverless), Cloudfront, etc etc.
  4. We’re going to be working with 64-bit x86 linux instances but you can also create instances for other OSes / architectures including Windows.

Instance Types

Anyway, EC2 (and others) have a few different types of computers to rent:

Pricing

These pictures are from Missing Semester 2024; these prices have probably come down since!
Remember: if something is persisting, you're probably paying for it.

Demo Time!

Lets explore two use cases together!

Demo 1: Micro Instance

Demo 2: Rendering

Blender splash screen White Lands

Blender is FOSS 3D modeling and animation software. Whenever they release a new version, there is a new splash screen. The scenefiles that were used to make these splash screens are distributed on blender’s website as a good example of a self-contained complex scene.

Lets try to render the Blender 3.2 splash screen image, White Lands, by Oksana Dobrovolska.

Demo 3: Rendering w/ GPU acceleration

We probably don’t have time to demo this but I was able to rent a third machine with GPU hardware.

<snip>
00:03.413  render           | Fra: 1 | Mem: 1450M | Sample 0/128
00:04.230  render           | Fra: 1 | Remaining: 01:43.73 | Mem: 1699M | Sample 1/128
00:05.891  render           | Fra: 1 | Remaining: 02:36.11 | Mem: 1699M | Sample 2/128
00:09.276  render           | Fra: 1 | Remaining: 03:01.76 | Mem: 1699M | Sample 4/128
00:15.148  render           | Fra: 1 | Remaining: 02:56.02 | Mem: 1699M | Sample 8/128
00:25.253  render           | Fra: 1 | Remaining: 02:32.88 | Mem: 1699M | Sample 16/128
00:41.106  render           | Fra: 1 | Remaining: 01:53.08 | Mem: 1699M | Sample 32/128
01:08.428  render           | Fra: 1 | Remaining: 01:05.01 | Mem: 1699M | Sample 64/128
01:21.011  render           | Fra: 1 | Remaining: 00:46.55 | Mem: 1699M | Sample 80/128
01:32.969  render           | Fra: 1 | Remaining: 00:29.85 | Mem: 1699M | Sample 96/128
01:45.191  render           | Fra: 1 | Remaining: 00:14.53 | Mem: 1699M | Sample 112/128
02:19.277  render           | Fra: 1 | Mem: 1699M | Sample 128/128
02:19.277  render           | Fra: 1 | Mem: 1699M | Finished
02:19.739  render           | Saved: '/tmp/0001.png'
02:19.739  render           | Time: 02:19.28 (Saving: 00:00.31)

Final Reminder:

Please remember to turn off your instances and any EBS volumes you're not using!

Also note that terminated instances will stick around in interface for a bit...

Otherwise, have fun!


Edit this page.

Licensed under CC BY-NC-SA.