AWS pandas安装给出错误:虚拟内存耗尽:无法分配内存

时间:2017-07-27 12:19:49

标签: python c++ amazon-web-services amazon-ec2

我正在尝试在AWS EC2实例上安装pandas,t2.micro RAM大小为1GB,但它在中间抛出错误

 > from pandas/_libs/join.c:435:
    >     /usr/lib64/python2.7/dist-packages/numpy/core/include/numpy/npy_deprecated_api.h:11:2:
    > warning: #warning "Using deprecated NumPy API, disable it by #defining
    > NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
    >      #warning "Using deprecated NumPy API, disable it by #defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION"
    >       ^
    >     virtual memory exhausted: Cannot allocate memory
    >     error: command 'gcc' failed with exit status 1
    >     
    >     ----------------------------------------
    >     Command "/usr/bin/python2.7 -c "import setuptools, tokenize;__file__='/tmp/pip-build-XJKxj6/pandas/setup.py';exec(compile(getattr(tokenize,
    > 'open', open)(__file__).read().replace('\r\n', '\n'), __file__,
    > 'exec'))" install --record /tmp/pip-QLWuWh-record/install-record.txt
    > --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-XJKxj6/pandas

可能是什么问题?这是t2.micro的问题吗?

pandas安装需要多少内存?

1 个答案:

答案 0 :(得分:1)

问题在于实例大小为micro。我将实例大小增加到小,然后它对我有效。