[zz]Python 3.4 and Pillow 2.4 with JPEG2000 (openjpeg 2) support in Ubuntu 14.04

Pillow support for JPEG2000 comes from openjpeg 2 library. Unfortunatly, Ubuntu‘s libopenjpeg2 package is not version 2 of the openjpeg library, but actually version 1.3 which wont work with Pillow.

Installing Pillow 2.4 (pip install -I pillow) simply results in "OPENJPEG (JPEG2000) support not available".

Thus, it is needed to compile the openjpeg library 2.0 from source. For this, first lets download the openjpeg 2.0.1:http://downloads.sourceforge.net/project/openjpeg.mirror/2.0.1/openjpeg-2.0.1.tar.gz

tar xzvf openjpeg-2.0.1.tar.gz 
cd openjpeg-2.0.1/ 
cmake . 
make 
sudo make install

Please note that we install version of openjpeg 2.0, rather than newer 2.1. Pillow wont recognize openjpeg 2.1 either.

Assuming everything went fine, we can reinstall Pillow:pip install -I pillow
If openjpeg 2.0.1 was detected successfully, we should get the following info "OPENJPEG (JPEG2000) support available" among others.

NOTE: to install cmake, cmake-2.8.10.2.tar.gz

wget http://www.cmake.org/cmake/resources/software.html

[zz]Python 3.4 and Pillow 2.4 with JPEG2000 (openjpeg 2) support in Ubuntu 14.04

时间: 2024-10-29 21:15:53

[zz]Python 3.4 and Pillow 2.4 with JPEG2000 (openjpeg 2) support in Ubuntu 14.04的相关文章

How to install Pygame for Python 3.4 on Ubuntu 14.04(转)

First run this to install dependencies: sudo apt-get install mercurial python3-dev python3-numpy libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libsmpeg-dev libsdl1.2-dev libportmidi-dev libswscale-dev libavformat-dev libavcodec-dev libfre

完全卸载python for Ubuntu 14.04

1.卸载python3.4 sudo apt-get remove python3.4 2.卸载python3.4及其依赖 sudo apt-get remove --auto-remove python3.4 3.清除python3.4 sudo apt-get purge python3.4 or sudo apt-get purge --auto-remove python3.4

Intel realSense ubuntu 16.04+python 环境配置指南

1. 安装librealsense2-dkms 以及librealsense2-utils 1.Register the server's public key: sudo apt-key adv --keyserver keys.gnupg.net --recv-key C8B3A55A6F3EFCDE || sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-key C8B3A55A6F3EFCDE (In ca

python之成像库pillow

目录 python之成像库pillow 官方文档 图像模块(Image.Image) Image模块的功能 Image.new(mode,size,color): Image.open(file,mode): Image.blend(image1,image2,alpha): Image.composite(image1,image2,mask): Image.eval(image,function): Image.merge(mode,bands): Image模块的方法 im.convert

Vim 7.4.1952 with Python/Ruby/Lua/Perl/C Syntax built for Ubuntu 16.04 x86_64

The default Vim provided by Ubuntu 16.04 even did not have Python support. That's insane. I say, what if I wanted to use Vim as a Python IDE in Linux as before? Ubuntu, you can't be so careless. Using this command to check whether it has vim --versio

Ubuntu 14.02下编译及配置apache2.4(python CGI)

Ubuntu 14.02下编译及配置apache2.4(python CGI): # 下载apache2.4源码包 wget http://mirrors.cnnic.cn/apache//httpd/httpd-2.4.12.tar.gz # 安装apr依赖库 apt-get install libapr1 libaprutil1 libapr1-dev libaprutil1-dev # 解压并编译安装 tar -xvf httpd-2.4.12.tar.gz cd httpd-2.4.12

ubuntu 16.04 安装 opencv +contrib (3.2.0) + python 3.5

环境: - ubuntu 16.04 - OpenCV + contrib 3.2.0 (文中附下载链接) - Python 3.5 基于其他环境的配置应该大同小异. 没时间解释了,直接上车. 更新下系统: sudo apt-get update sudo apt-get upgrade 安装依赖项: sudo apt-get install build-essential cmake pkg-config sudo apt-get install libjpeg8-dev libtiff5-d

ubuntu 16.04 + python + matplotlib下画图显示中文设置

一.需求 因为在python画图显示的时候,经常需要展示一些中文,但是ubuntu系统下按照默认安装方式安装的时候,一般是不能显示中文的,当强行给legend.xlabel.ylabel赋予中文的时候,会显示为方块 二.参考 http://blog.csdn.net/onepiece_dn/article/details/46239581 三.配置方法 (1)  显示本机的同时可用的中文和西文字体 def dispFonts(): #显示可用的中文字体,同时支持英文的 from matplotl

转载 - Vim 的 Python 编辑器详细配置过程 (Based on Ubuntu 12.04 LTS)

出处:http://www.cnblogs.com/ifantastic/p/3185665.html Vim 的 Python 编辑器详细配置过程 (Based on Ubuntu 12.04 LTS) 为什么要用vim编辑py文件? 因为在Linux命令行中,缺少图形界面的IDE,vim是最佳的文本编辑器,而为了更好的编辑py文本,所以配置vim. 1. 安装完整版vim vi和vim的区别? 在Linux自带有vi编辑器,而vim是指vi improved,即vi升级版.区别在于vi指令和