In the Serverless.yml file, we need to define access to the S3 bucket as that's where we will keep our model. Other than that, it will look exactly as the previously mentioned serverless CML files for other Lambdas:
service: deeplearninglambdaframeworkVersion: ">=1.2.0 <2.0.0"provider: name: aws region: us-east-1 runtime: python3.6 memorySize: 1536 timeout: 60iamRoleStatements: - Effect: "Allow" Action: - "s3:ListBucket" Resource: - arn:aws:s3:::serverlessdeeplearning - Effect: "Allow" Action: - "s3:GetObject" Resource: - arn:aws:s3:::serverlessdeeplearning/*functions: main: handler: index.handler
Also, the we need inputimage.jpg image for the inception model.
Let's look at the files that we need to upload to S3 bucket: