- ARM64 based EC2
- Windows + WSL2 + Ubuntu
Note: MacOS is currently not supported due to model compilation issues.
Pre-Requisites
-
You need to have an already created PEM key in your aws account and downloaded it to your local computer. Instructions on how to create a PEM key
-
You need to subscribe to the Ubuntu 18.04 LTS Bionic ARM AMI on AWS Marketplace. Please go to this link and click "Continue to Subscribe". "Accept Terms" on the next page completes the Subscription
-
An S3 bucket created in the region of your choice that you can use in the Test Utility
Launching the Samples
-
Click the Launch Stack Button below. NOTE : This process will take about
20 minutes
-
Log into the EC2 Instance (See next section) and wait for the file
INSTALLATION-COMPLETE.txt
to appear on your/home/ubuntu
. This marks the end of the EC2 instance set upOPTIONAL STEP : If you would like to monitor the set up progress, log into the EC2 instance (See Next Section), and type
tail -f /var/log/cloud-init-output.log
in a terminal session.
Logging into the EC2 Instance
-
From the AWS EC2 Console, get the Public IPv4 DNS for the instance you launched. It should look something like this
ec2-1-234-567-8.compute-1.amazonaws.com
-
Make sure the PEM key that was created is in the same folder as you are. At this point, you can do this
ssh -i "My_Awesome_Key.pem" [email protected]
-
Launch Jupyter Lab Session from the Ec2 console
sudo jupyter-lab --no-browser --allow-root
You Should see something like this
http://ip-123-45-678-910:8888/lab?token=e718819a3eb9b464aa81e14fe73439b49337e5d9fdef2676
Note the Port (8888) and the token number
-
Creating a SSH tunnel (May not be necessary).Open an another terminal session on your Computer. Make sure the port number here is the same as the output from
Step 3
ssh -i My_Awesome_Key.pem -NL 8157:localhost:8888 [email protected]
-
Launch your browser, paste the following address in your browser window
http://localhost:8157/
At this point it should ask for the token number, paste it and click Ok. You are inside your EC2 instance Jupyter Lab session
-
Once logged into Jupyter Lab session, open a terminal session and run
aws configure
. Fill in the Access Key and Secret key and Region for your account.aws configure
-
Install WSL2, Ubuntu and Docker Desktop on your Windows PC, and configure Ubuntu. Please refer to Setting up a development environment in Windows
-
Install DLR in Ubuntu by building from source code. Please refer to Building on Linux - Building for CPU
-
Install additional dependencies
sudo pip3 install boto3 sagemaker matplotlib opencv-python --upgrade
-
Install Jupyter or JupyterLab in Ubuntu
sudo pip3 install jupyterlab
-
Clone the 'aws-panorama-samples' repository in the Ubuntu filesystem.
git clone https://github.com/aws-samples/aws-panorama-samples.git
-
Run jupyter server on Ubuntu
jupyter-lab --no-browser --allow-root --port 8888 --notebook-dir ~
You will see console output like below:
Jupyter Server 1.13.0 is running at: http://localhost:8888/lab?token={token}
Copy the token to clipboard.
-
Open your browser on Windows, and browse http://localhost:8888/.
You will be asked to input the token. Please use the token you copied at previous step.