O'Reilly logo

Hands-On Serverless Deep Learning with TensorFlow and AWS Lambda by Rustem Feyzkhanov

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

AWS Lambda functions

Let's go through the pre-requisites of AWS Lambda as shown here:

import sys, osimport mylib...def handler(event, context):  ...  print("Hello world log")  return result

It consists of the following steps:

  1. Importing libraries, which you have already installed on AWS Lambda. This includes system libraries and a number of AWS-specific libraries. You don't have to include these libraries within your package.
  2. Importing external libraries, from other developers and companies, or your own libraries. You need to include them in your package.
  3. Implementing handler function which handles processing of the requests to the main variables as input event and context. The event is trigger-specific information and context is information ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required