python - Trouble installing scipy in virtualenv on a amazon ec2 linux micro instance -


i have installed scipy in default python compiler on amazon ec2 micro instance (ubuntu 13.04). not able install scipy in virtualenv.

pip install scipy ends error

scipy/sparse/sparsetools/csr_wrap.cxx: in function ‘void init_csr()’:  scipy/sparse/sparsetools/csr_wrap.cxx:73303:21: warning: variable ‘md’ set not used [-wunused-but-set-variable]  c++: internal compiler error: killed (program cc1plus)  please submit full bug report,  preprocessed source if appropriate.  see <file:///usr/share/doc/gcc-4.7/readme.bugs> instructions.  ---------------------------------------- cleaning up... command /home/ubuntu/pnr/bin/python -c "import setuptools;__file__='/home/ubuntu/pnr/build/scipy/setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-t8drvd-record/install-record.txt --single-version-externally-managed --install-headers /home/ubuntu/pnr/include/site/python2.7 failed error code -9 in /home/ubuntu/pnr/build/scipy 

and

traceback (most recent call last):   file "/home/ubuntu/pnr/bin/pip", line 9, in <module>     load_entry_point('pip==1.4.1', 'console_scripts', 'pip')()   file "/home/ubuntu/pnr/local/lib/python2.7/site-packages/pip/__init__.py", line 148, in main     return command.main(args[1:], options)   file "/home/ubuntu/pnr/local/lib/python2.7/site-packages/pip/basecommand.py", line 169, in main     text = '\n'.join(complete_log) unicodedecodeerror: 'ascii' codec can't decode byte 0xe2 in position 53: ordinal not in range(128) 

before asks. pip freeze default compiler returns

cheetah==2.4.4 landscape-client==12.12 m2crypto==0.21.1 pam==0.4.2 pillow==2.0.0 pyyaml==3.10 twisted-core==12.3.0 twisted-names==12.3.0 twisted-web==12.3.0 apt-xapian-index==0.45 argparse==1.2.1 boto==2.3.0 chardet==2.0.1 cloud-init==0.7.2 configobj==4.7.2 distribute==0.6.34 distro-info==0.10 euca2ools==2.1.1 numpy==1.7.1 oauth==1.0.1 paramiko==1.7.7.1 prettytable==0.6.1 pyopenssl==0.13 pycrypto==2.6 pycurl==7.19.0 pygobject==3.8.0 pyserial==2.6 python-apt==0.8.8ubuntu6 python-debian==0.1.21-nmu2ubuntu1 requests==1.1.0 scipy==0.11.0 six==1.2.0 ssh-import-id==3.14 urllib3==1.5 virtualenv==1.10.1 wsgiref==0.1.2 zope.interface==4.0.5 

pip freeze command virtualenv returns

cython==0.19.2 flask==0.10.1 flask-bootstrap==3.0.0.1 flask-wtf==0.9.3 jinja2==2.7.1 markupsafe==0.18 wtforms==1.0.5 werkzeug==0.9.4 argparse==1.2.1 beautifulsoup4==4.3.2 itsdangerous==0.23 numpy==1.7.1 pymongo==2.6.2 requests==2.0.0 wsgiref==0.1.2 

one solution temporarily enable swap on micro instance. described @ so post, enable 1gb swap via:

sudo /bin/dd if=/dev/zero of=/var/swap.1 bs=1m count=1024 sudo /sbin/mkswap /var/swap.1 sudo /sbin/swapon /var/swap.1 

once swap on, install scipy via pip:

sudo apt-get install -y libatlas-base-dev gfortran python-dev build-essential g++ sudo pip install numpy sudo pip install scipy 

once scipy installs, can disable via:

sudo swapoff /var/swap.1 sudo rm /var/swap.1 

Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

jquery - javascript onscroll fade same class but with different div -