Python: The _imagingft C module is not installed错误的解决
Python: The _imagingft C module is not installed错误的解决
By 白熊花田(http://blog.csdn.net/whiterbear) 转载需注明出处。谢谢。
在使用PIL模块给图片加入文本时发现调用字体时出现 The _imagingft C module is not installed 错误。
找到的原因是:官网的PIL版本号编译的时候缺少东西(PIL was compiled without libfreetype)。
解决的方法是:
- brew install freetype
- sudo pip uninstall pil
- sudo pip install pillow
我的是OSX系统,其它情况能够參考stackoverflow.
$(function () {
$('pre.prettyprint code').each(function () {
var lines = $(this).text().split('\n').length;
var $numbering = $('
$(this).addClass('has-numbering').parent().append($numbering);
for (i = 1; i ').text(i));
};
$numbering.fadeIn(1700);
});
});
Python: The _imagingft C module is not installed错误的解决的更多相关文章
- Python图片处理PIL/pillow/生成验证码/出现KeyError: 和The _imagingft C module is not installed
最近在用Python开发自己的博客,需要用到Python生成验证码,当然肯定要用到Python的图形处理库PIL,因为我用的是windows. 所以在安装好pil之后就开始写,就按照题目所说出现了Th ...
- ImportError: The _imagingft C module is not installed
添加验证码模块的时候,发布到服务器上居然报了这个错误 ImportError: The _imagingft C module is not installed 然而pillow是已经装在服务器上的, ...
- Failed to connect to MySQL server as DBD::mysql module is not installed 问题的解决
部署PXC ,卸了旧的MySQL perl-DBD-MySQL-4.013-3.el6.x86_64 这个包已经安装了,innobackup时一直在报错: Failed to connect to M ...
- Python 的PIL,可以解决ImportError The _imagingft C module is not installed
删除PIL相关文件 mv PIL /tmp pip install Pillow 安装Pillow后, 可能还会发生KeyError的错误, 检查项目源码后发现是 Image 模块的save函数中 ...
- 用pil产生验证码出现:ImportError: The _imagingft C module is not installed
这个是由于PIL没有编译freetype导致的查看 lib/python2.7/site-packages/PIL/看看 _imagingft.so 是否存在 # 需要先安装jpeg库wget htt ...
- pip install PIL The _imagingft C module is not installed
需要先删除PIL再进行安装 sudo pip uninstall -y PIL 删除PIL相关文件夹:/usr/local/bin/pil , usr/lib/python2.7/dist-packa ...
- Python Error: “ImportError: No module named six”,用自动安装解决依赖问题
在初次运行带有matplotlib包的程序时,被告知了缺少模块(如标题所示).搜索调查后发现在自己安装的python中确实缺少此安装包,接下来,进行了下载.安装.运行,又少了一个模块,再下载.再运行, ...
- 类似No module named 'bs4'等错误的解决方法
最近开始接触爬虫,写了如下源代码: from bs4 import BeautifulSoup import requests url='https://www.tripadvisor.cn/Attr ...
- 在apache上报错“The _imaging C module is not installed”
我的环境是python2.7.8.django1.6.4.apache2.2. 问题:在django自带的runserver环境下没有任何报错,但是配置在apache上出现了 “The _imagin ...
随机推荐
- flask中使用xlsxwriter导出excel文件
最近需要使用flask导出xlsxwriter生成的excel文件,在文件比较小的情况下,可以直接导出. 首先,这里使用了StringIO,导出使用的模块 import xlsxwriter impo ...
- 常用的Python代码段
过滤列表 #filter out empty strings in a sting list list = [x for x in list if x.strip()!=''] 一行一行地读文件 wi ...
- 选择排序-Python与PHP实现版
选择排序Python实现 import random # 生成待排序数组 a=[random.randint(1,999) for x in range(0,36)] # 选择排序 def selec ...
- 线性回归,附tensorflow实现
本文同步自:https://zhuanlan.zhihu.com/p/30738405 本文旨在通过介绍线性回归来引出一些基本概念:h(x),J(θ),梯度下降法 有一组数据: x=[1,2,3,4, ...
- 01_Python简介
Python 简介 *为什么学习python http://bbs.fishc.com/thread-35584-1-1.html Python 特点 易于学习:Python有相对较少的关键字,结构简 ...
- 记一次改造react脚手架的过程
公司突然组织需要重新搭建一个基于node的论坛系统,前端采用react,上网找了一些脚手架,或多或少不能满足自己的需求,最终在基于YeoMan的react脚手架generator-react-webp ...
- Less的!important关键字
Less的!important关键字 在调用 mixin 时,如果在后面追加 !important 关键字,就可以将 mixin 里面的所有属性都标记为 !important.如,以下Less代码: ...
- Activity讲解
Activity Activity 是 Android 应用的重要组成单元之一(另外三个是 Service.BroadcastReceiver 和 ContentProvider),而 Activit ...
- ajax处理级联访问数据库显示
首先创建简单的html页面,写出如下代码: 静态页相关代码: js代码:
- Cracking the Coding Interview 题目分析笔记—— Array and String
1.Determine if a string has all unique characters learn: 为了减少空间利用率,其比较优秀的算法一般都适用位操作 返回值的命名方法,我们需要学习 ...