A step by step guide to making Pandas available as a Lambda Layer in AWS …

This guide assumes a working knowledge of AWS Lambda functionality.

Why: When attempting to run Pandas in your AWS Lambda you receive the error code below.

“numpy: cannot import name ‘WinDLL’ from ‘ctypes’ (/var/lang/lib/python3.7/ctypes/__init__.py)”.

This is due to incompatibility between Windows compiled version of Pandas and AWS Linux.

The solution is to use an AWS Linux image with Docker to compile the Pandas libraries.

Working with Docker

Download docker at “https://www.docker.com/products/docker-desktop” and install using the default specs.

When installation is complete, open Docker. This will start Docker…

Chris Jones

Data & BI Professional

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store