Skip to main content

Machine Learning & Containers on AWS

1h 33m 34s
English
Paid

Embark on a comprehensive journey to build a complete data pipeline on the AWS platform. In this practical course, you will gain hands-on experience, from acquiring data with the Twitter API to analysis, storage, and visualization.

Course Overview

You will learn how to create your own machine learning algorithm and deploy it on AWS using Lambda. The course also covers setting up a Postgres database with Amazon RDS. For result visualization, you'll develop an interactive dashboard with Streamlit and learn to deploy it using Elastic Container Registry (ECR) and Elastic Container Service (ECS). Furthermore, you'll be introduced to the Poetry tool for effective project dependency management.

Course Structure

Twitter API Integration

Twitter API provides an excellent gateway for accessing open data. You will learn to configure API access and retrieve tweets from a user's feed for further processing. Delve into API configuration details and understand the data format (payload) it returns.

Setting Up RDS Database

Data storage is crucial for any platform. You will set up a Postgres database in Amazon RDS and understand the rationale behind storing JSON tweets in it. Get hands-on practice with virtual private clouds (VPC) to make your database internet-accessible. Learn to use PGAdmin to create tables and execute database queries.

Implementing NLP with Lambda

Use the Natural Language Toolkit (NLTK) library to perform text analysis with a pre-built machine learning algorithm. You will create a Lambda function to retrieve tweets, analyze their sentiment, and save the results in your database. Learn to connect necessary dependencies through layers, including how to import pre-made K-Layers and create custom layers. Discover how to set up automatic Lambda function triggers using EventBridge.

Dependency Management and Streamlit App Development

Visualize results by creating a Streamlit application. Establish a local development environment with Anaconda3 and create a conda virtual environment. Manage project dependencies using Poetry as you navigate through the provided Git repository. We will guide you step-by-step through the application code, demonstrating how to run it in a new virtual environment for testing.

Deploying Streamlit Application in ECS

Upon completing your visualization, learn to handle Docker images and containers on AWS. Create an Elastic Container Registry (ECR) and set up AWS CLI. Understand how to create user groups and set access restrictions with IAM. After building your Docker image, upload it to ECR, configure an ECS Fargate cluster, and successfully deploy your Streamlit application as a task on the platform.

About the Author: Andreas Kretz

Andreas Kretz thumbnail

I am a senior data engineer and trainer, a tech enthusiast, and a father. For more than ten years, I have been passionate about Data Engineering. Initially, I became a self-taught data engineer and then led a team of data engineers at a large company. When I realized the great demand for education in this field, I followed my passion and founded my own Data Engineering Academy. Since then, I have helped over 2,000 students achieve their goals.

Watch Online 25 lessons

This is a demo lesson (10:00 remaining)

You can watch up to 10 minutes for free. Subscribe to unlock all 25 lessons in this course and access 10,000+ hours of premium content across all courses.

View Pricing
0:00
/
#1: Introduction video
All Course Lessons (25)
#Lesson TitleDurationAccess
1
Introduction video Demo
02:39
2
Project architecture explained
02:07
3
Relational DB
01:27
4
RDS setup
02:38
5
Setting VPC inbound rules for internet access
02:13
6
PG Admin installation & S3 config
04:06
7
Lambda intro & IAM setup
03:12
8
Create Lambda function
01:25
9
The Lambda function code explained
08:23
10
Insert the code into your Lambda function
00:57
11
Add layers to Lambda from Klayers
05:33
12
Create & configure custom layers for twython & psycopg2
04:41
13
Test Lambda & set environment variables
04:54
14
Schedule your Lambda with Event Bridge
03:16
15
Setup virtual conda environment
04:08
16
Poetry dependency installs & run Streamlit UI locally
05:58
17
Streamlit app code explained
07:53
18
Setup container registry ECR
01:53
19
AWS CLI install and ECR login
05:20
20
Dockerfile explained, Docker image build & push image to ECR
02:53
21
Create ECS Fargate cluster
01:35
22
ECS task IAM configuration & Streamlit task creation
05:00
23
Fixing the ECS task
05:15
24
Stopping the task on ECS after you are finished
01:00
25
Conclusion & outlook
05:08
Unlock unlimited learning

Get instant access to all 24 lessons in this course, plus thousands of other premium courses. One subscription, unlimited knowledge.

Learn more about subscription