I'd like to capture an image at a specified shutter speed and ISO, and write it to disk. I thought that'd be pretty straightforward but... apparently not? In searching, I found people complaining of the same thing 2 years ago but no answers... I guess I'm hoping something has changed.
import picamera
import time
from fractions import Fraction
start = time.time()
print "Initializing...",
camera = picamera.PiCamera()
camera.resolution = (2592,1944)
camera.awb_mode = 'sunlight'
camera.framerate = Fraction(1,15)
camera.exposure_mode = 'off'
camera.iso = 800
camera.shutter_speed = 6000000
print "Done! ",
stop = time.time()
print (stop-start), "seconds"
for i in range(0,10):
start = time.time()
print "capturing...",
camera.capture('image.jpg', format='jpeg', quality=100)
print "done ",
stop = time.time()
print (stop-start), "seconds"
Initialization takes 0.59 seconds, fine no problem
First image takes 37.44 seconds
The rest take 24.9 seconds each
I'm fine with a bit of overhead, but the overhead is 3 times as long as the actual exposure! Any way around this? Or even an explanation of what's happening for the half-minute it's not taking the picture?
use_video_port=True
) which should bring things down to a single frame's worth of time (plus I/O) but the results will be much more "grainy". – Dave Jones Aug 24 '15 at 11:53