Python
Java
PHP
IOS
Android
Nodejs
JavaScript
Html5
Windows
Ubuntu
Linux
如何将 PIL 图像转换为 NumPy 数组?
如何转换 PILImage来回转换为 NumPy 数组 这样我就可以比 PIL 进行更快的像素级转换PixelAccess允许 我可以通过以下方式将其转换为 NumPy 数组 pic Image open foo jpg pix numpy
python
image
NumPy
pythonimaginglibrary
numpyndarray
使用 PIL 用附近的颜色填充空白图像空间(也称为修复)
我用 PIL 创建一个图像 我需要填充空白区域 显示为黑色 我可以轻松地用静态颜色填充它 但我想做的是用附近的颜色填充像素 例如 边框之后的第一个像素可能是填充像素的高斯模糊 或者可能是中描述的推拉型算法Lumigraph Gortler
python
imageprocessing
NumPy
pythonimaginglibrary
如何将文件夹中的所有图像添加到按钮(在我的框架中)[关闭]
Closed 这个问题需要细节或清晰度 help closed questions 目前不接受答案 我想存储 jpg数组中文件夹中的图像 然后使用它们将其添加到我的 Python 框架中的按钮中 我正在 Python 3 4 3 中使用 t
python
Tkinter
pythonimaginglibrary
PIL 的 Image.show() 带来*两个*不同的查看器
在 python shell 中处理图像时 我使用 image show 其中 image 是 Image 的实例 很久以前什么也没发生 但在定义了一个名为 xv 的 Mirage 符号链接后 我很高兴 最近几天 show 将显示 Imag
python
Linux
pythonimaginglibrary
Django / PIL - 上传图像时保存缩略图版本
这是我的 forms py class UploadImageForm forms ModelForm class Meta model UserImages fields photo 这是我的 models py class UserIm
django
image
thumbnails
pythonimaginglibrary
安装 Pillow 和 PIL
I have Ubuntu 12 04 http en wikipedia org wiki List of Ubuntu releases Ubuntu 12 04 LTS 28Precise Pangolin 29 Precise Pa
python
pythonimaginglibrary
使用OIL自动旋转手机和加速度计拍摄的照片
我在网络应用程序中使用 Django PIL Amazon boto 用户发送图片 然后 Web 应用程序显示它 大多数情况下 人们会发送用手机拍摄的照片 有时 图像以错误的方向显示 有没有办法使用 PIL 或 Django 的 Image
python
django
pythonimaginglibrary
djangomodels
对同色像素块的边界进行着色
我有一张有 5 种不同颜色的图像 在这种情况下 随机生成 w h 40 27 img Image new RGB w h pixels img load available colors r 255 13 18 b 72 64 255 y
python
opencv
imageprocessing
pythonimaginglibrary
如何保存 numpy 数组图像并将它们放入单个文件夹中?
我有一个 numpy 数组 其中包含 5000 个 28 x 28 图像 5000 28 28 我想将所有这些图像保存为 jpg 文件并将它们全部保存在一个文件夹中 实现这一目标最快 最有效的方法是什么 我尝试使用以下命令将 50 000
NumPy
matplotlib
scipy
pythonimaginglibrary
PIL/scipy.misc 中的 imresize 仅适用于 uint8 图像?有什么替代方案吗?
看来imresize实施于PIL scipy misc仅适用于 uint8 图像 gt gt gt import scipy misc gt gt gt im np random rand 100 200 gt gt gt print im
python
NumPy
scipy
pythonimaginglibrary
Python PIL 标签中的图像自动调整大小
我正在尝试制作一个小部件来保存图像 该图像将自动调整大小以适合其容器 例如如果直接打包到窗口中 则扩展该窗口将扩展图像 我有一些半功能的代码 但我必须在其中一个例程中添加几个常量 以防止自动调整大小重新触发自身 导致其大小不断增长 我确信这
python
python3x
Tkinter
pythonimaginglibrary
PhotoImage 实例没有属性“调整大小”
我收到错误 PhotoImage 实例没有属性 调整大小 尽管多个在线资源声称这是使用 PIL 调整图像大小的方法 有任何想法吗 相关代码 Deathwing ImageTk PhotoImage Image open Deathwing
python27
Tkinter
pythonimaginglibrary
如何使用PIL将灰度图转为伪彩色?
我似乎不知道如何获取我的灰度函数并将其更改为给我假颜色 我知道我需要将每种颜色 R G B 分成范围 然后根据每种颜色的范围分配颜色 有谁知道这是如何运作的 def grayscale pic width height pic size f
python
imageprocessing
Colors
pythonimaginglibrary
grayscale
Python 3.x 中的 PIL ImageTk 等效项
我正在使用 Tkinter 开发一个应用程序 它使用以下数据库png图标的图像文件 为了在应用程序中使用所述图像 我使用 PIL 打开它们Image open 运行它通过ImageTk PhotoImage函数 然后将其传递给小部件构造函数
python
PNG
Tkinter
pythonimaginglibrary
将 RGB 转换为黑色或白色
我如何在Python中获取RGB图像并将其转换为黑白图像 不是灰度 我希望每个像素要么是全黑 0 0 0 要么是全白 255 255 255 流行的 Python 图像处理库中是否有任何内置功能可以完成此任务 如果不是 最好的方法是循环遍历
python
opencv
NumPy
pythonimaginglibrary
Django:上传前调整图像大小
我想调整图像大小 Pillow 在上传之前 我在下面编写了代码但不起作用 并得到错误 myapp list 处的属性错误 坚定的 请求方式 POST 请求网址 http 127 0 0 1 8000 myapp list http 127
python
django
pythonimaginglibrary
在 while 循环中更改 tkinter 画布中的图像
我的完整代码是here https gist github com ItsBerry de245ba70376cb07f4dbe2d25c223f5f 我正在尝试使用 tkinter 的画布创建一个小游戏 让人们练习学习高音谱号上的音符 最
python
python3x
Tkinter
pythonimaginglibrary
tkintercanvas
Python获取图像矩阵PIL
我正在尝试加载图像 转换它并打印矩阵 我有以下代码 im Image open 1 jpg im im convert L print im 当我打印 im 时我得到这个
python
NumPy
pythonimaginglibrary
无法在 PIL 中对 16 位 TIF 应用图像滤镜
我尝试使用 python 应用图像过滤器PIL http www pythonware com products pil 代码很简单 im Image open fnImage im im filter ImageFilter BLUR 此
python
image
imageprocessing
pythonimaginglibrary
Django - 获取 PIL 图像保存方法以与 Amazon s3boto 存储一起使用
为了在上传时调整图像大小 使用 PIL 我重写了文章模型的保存方法 如下所示 def save self super Article self save if self image size 160 160 image Image open
django
amazons3
pythonimaginglibrary
boto
1
2
3
4
5
6
...22
»