Quantcast
Channel: Active questions tagged python - Stack Overflow
Viewing all articles
Browse latest Browse all 23160

Numpy on AWS GovCloud Lambda

$
0
0

I seem to have a unique issue which is quite surprising! I need to add Numpy to my Lambda function and I'm using a layer rather than Docker (not interested in using Docker at the moment). I use cloudwatch, which is on X86 architecture, to pip install numpy -t ./python, then zip up the python folder and use that as my layer. I'm also running my Lambda function on an x86 architecture. This method works for every other package I need, so there seems to be something wrong with the way Numpy is getting compiled. Also, unfortunately on GovCloud the AWS provided package AWS SDK for Pandas is not available.

The error that I get is:

numpy: Error importing numpy: you should not try to import numpy from its source directory;please exit the numpy source tree, and relaunch your python interpreter from there.

Anyone know how to fix this?


Viewing all articles
Browse latest Browse all 23160

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>