Imageio is a Python library that provides an easy interface to read and write a wide range of image data including animated images, volumetric data, and scientific formats. Make to use this tag for question related to it.
Questions tagged [python-imageio]
191 questions
0
votes
1 answer
Python imageio and visvis draws lines
I'm new to python
My problem is that imageio and visvis draws vertical lines instead of pixel, what's wrong?
1
def writePic(picnum,picres):
return vv.imwrite('\picsout\pic'+str(picnum)+'.png',np.array(np.uint8(picres)))
def dothisandthat(pnum):
…

Taxy
- 1
- 1
0
votes
0 answers
Upgrading from scipy to imageio
I'm quite new to Python so bear with me, I downloaded a github project for Document Forgery Detection that works with 3.6 and buried within it is scipy.misc.imsave which is deprecated.
The call to scipy.misc.imsave only has one parameter but I can't…

Jay Croghan
- 445
- 3
- 16
0
votes
1 answer
Trying to access a single array element in numpy accesses a sequence instead
I'm trying to make a program that takes random parts of various images and then adds them back together, but when i then try to access a single array element it comes out as a sequence instead.
def select_from_image(img):
…

ImNotTooGood
- 11
- 3
0
votes
0 answers
Reading Nikon raw (NEF) images with rawpy vs imageio in python
I am trying to read a Nikon RAW (NEF) image correctly, and have found there have been a few suggestions; rawpy, imageio, and simple numpy reads:
RAW Image processing in Python
However, I'm getting some odd results when reading in Nikon RAW images…

asylumax
- 781
- 1
- 8
- 34
0
votes
1 answer
Mouse cursor included when taking screenshots with imageio or pyautogui?
How is it possible to have the mouse cursor included when taking screenshots with:
imageio.imread('')
or
pyautogui.screenshot(region=(0,0,300,300))
?
imread does not seem to offer such cursor a parameter.
The goal is finally to record…

Basj
- 41,386
- 99
- 383
- 673
0
votes
1 answer
jupyter notebook won't launch due to "Library not loaded" error
Jupyter notebook always launched with no problem. Until yesterday... I tried to pip install pytesseract then went off to do something else and now when I try to start jupyter notebook, this is what I get every single time:
File…

biogeek
- 561
- 1
- 4
- 13
0
votes
1 answer
Imageio Pillow plugin requires Pillow lib
Instead of:
scipy.misc.imsave(category + '/' + str(i) + '.jpg', image)
I am using:
imageio.imwrite(category + '/' + str(i) + '.jpg', image)
And it's giving me the following error:
error in image: 6078 - Imageio Pillow plugin requires Pillow…

user12401882
- 3
- 3
0
votes
1 answer
Fatal Python error: could not acquire lock for <_io.BufferedReader name=8> at interpreter shutdown, possibly due to daemon threads
Running the following:
import imageio
class vidrdf:
def __init__(self, vidfile):
self.vid = imageio.get_reader(vidfile, 'ffmpeg')
vidfile = 'movie.mov'
rdfobj = vidrdf(vidfile)
I get:
Fatal Python error: could not acquire lock for…

JavNoor
- 402
- 2
- 11
0
votes
1 answer
Nvenc session limit per GPU
I'm using Imageio, the python library that wraps around ffmpeg to do hardware encoding via nvenc. My issue is that I can't get more than 2 sessions to launch (I am using non-quadro GPUs). Even using multiple GPUs. I looked over NVIDIA's support…

teals
- 47
- 1
- 6
0
votes
0 answers
How to convert JPG to fits in Python?
I am trying to convert a raw cr2 image into .fits using imageio and PIL. But, I am unable to convert the image into .fits format
I am currently converting .cr2 into jpg as I am unable to convert .cr2 into .fits. (if possible = best). After…

Burhan Khan
- 1
- 3
0
votes
0 answers
How to Create .fits file from numpy array
I am currently trying to convert a .cr2 into .fits file. I am currently unable to create .fits as any file I create doesn't open or work because of the wrong shape of fits.
I have tried using the solution Write 3d Numpy array to FITS file with…

Burhan Khan
- 1
- 3
0
votes
1 answer
Saving a 3D 32bit floatarray to a 48bit integer PNG in Python to match Kitti Ground Truth Format
Kitti has a benchmark for Optical Flow. They require the flow estimate to be 48bit PNG files to match the format of the ground truth files they have.
Ground Truth PNG Image is available for download here
Kitti have a Matlab DevKit for the…

CogT
- 53
- 6
0
votes
0 answers
Why is the color dimension gone after saving and loading an animated GIF with imageio?
When saving an animated GIF from a Numpy array of shape (20, 64, 64, 3) and loading it again, the shape is suddenly (20, 64, 64). I think the array may contain indices into a color palette but I'm not sure how to access that. How can I restore the…

danijar
- 32,406
- 45
- 166
- 297
0
votes
1 answer
Getting image from Firebase and creating stripe.File
I am trying transfer a file to Stripe from a firebase database using the stripe.File.create() method. Here is the code that I am using:
file_url = storage.child("/path/to/file").get_url(token=None)
response = requests.get(file_url, stream=True)
…

Brian L
- 549
- 7
- 21
0
votes
0 answers
Error importing PDF image to convert to text
I have a PDF image for transfer to image format so I am trying to read the PDF image and store the data in the text file.
import pytesseract
from PIL import Image
img = Image.open('1.pdf')
text = pytesseract.image_to_string(img)
with open('1.txt',…

Anuj Pratap Singh
- 27
- 1
- 6