설치


sudo pip install opencv-python

sudo pip install opencv-contrib-python

(추가)

sudo pip install matplotlib


예제



실행결과




참고


https://pypi.org/project/opencv-python/

# 1. Install a package with repository for your system:
# On CentOS, install package centos-release-scl available in CentOS repository:
$ sudo yum install centos-release-scl

# On RHEL, enable RHSCL repository for you system:
$ sudo yum-config-manager --enable rhel-server-rhscl-7-rpms

# 2. Install the collection:
$ sudo yum install python27

# 3. Start using software collections:
$ scl enable python27 bash


- add source to the path

 cp /opt/rh/python27/root/usr/lib/python2.7 /usr/lib/python2.7

 cp /opt/rh/python27/root/usr/bin/python2.7 /usr/bin/

 cp /opt/rh/python27/root/usr/bin/python2.7-config /usr/bin/

 ln -snf /usr/bin/python2.7

 ln -snf /usr/bin/python2.7-config /usr/bin

 cp /opt/rh/python27/root/usr/lib64/libpython2.7.so /usr/lib64/

 cp /opt/rh/python27/root/usr/lib64/libpython2.7.so.1.0 /usr/lib64//usr/lib64/

 cp python27/root/usr/bin/pip2.7 /usr/bin/

 cp /opt/rh/python27/root/usr/bin/easy_install-2.7 /usr/bin/

 easy_install --upgrade pip


[ref]

https://github.com/h2oai/h2o-2/wiki/installing-python-2.7-on-centos-6.3.-follow-this-sequence-exactly-for-centos-machine-only

https://www.softwarecollections.org/en/scls/rhscl/python27/

'Programming > Python' 카테고리의 다른 글

pip 설치 및 재설치  (0) 2018.10.22
[python] 다양한 정규식 패턴 표현  (0) 2018.10.12
[argparse] FLAGS parser 사용법  (0) 2017.08.24
matplotlib.pyplot 설치하기  (0) 2017.08.24
사용자 입력 / 옵션으로 입력 받기  (0) 2017.08.14

1. 개발도구 및 라이브러리 설치

yum groupinstall -y "Development tools"


2. EPEL Repository 추가, pip 설치

yum install -y epel-release

yum install -y python-pip


3. tensorflow 설치 (GPU용은 별도 문서 참고)

pip install --upgrade https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-1.0.1-cp27-none-linux_x86_64.whl 


출처: http://lux.cuenet.kr/100 [(주)큐넷]

+ Recent posts