You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are using python 3.9.13 and pims 0.6.1.
While trying to uncover some other issues, we noticed that pims shows a slightly weird behavior when iterating through frames.
pims seems to return one frame image for two indices, but then returns the same number of overall frames as imageio by leaving out the last frame:
import pims
import imageio
import hashlib
from tqdm import tqdm
hashes_pims = list()
for i_fr, img in enumerate(tqdm(reader_pims)):
hashes_pims.append(hashlib.md5(img).hexdigest())
hashes_pims = list()
for i_fr, img in enumerate(tqdm(reader_pims)):
hashes_pims.append(hashlib.md5(img).hexdigest())
for n in range(620,625):
print(f"{n} {hashes_pims[n]} {hashes_imageio[n]}")
620 fce4da92e07f132e11bdee7b44322b6a fce4da92e07f132e11bdee7b44322b6a
621 2e43a6209ad4d87a3435f5d0d9a5d5d5 2e43a6209ad4d87a3435f5d0d9a5d5d5
622 2e43a6209ad4d87a3435f5d0d9a5d5d5 c7866a3a91355e487192901951714c87
623 c7866a3a91355e487192901951714c87 7a219477137e364aa832f3f03fbea151
624 7a219477137e364aa832f3f03fbea151 e29e4fb648d37c5c99a876ca452e654b
for n in range(990,995):
print(f"{n} {hashes_pims[n]} {hashes_imageio[n]}")
990 35a18dbe59f28598b36a2a9a7ca082ae 6e72e375f58b1fe6d7c9397ca8fe0ac2
991 6e72e375f58b1fe6d7c9397ca8fe0ac2 3771c6599ad9147be24f897c69b3fb3b
992 3771c6599ad9147be24f897c69b3fb3b 7ffc6d7c2ff353fee0a85ea46925bc7f
993 7ffc6d7c2ff353fee0a85ea46925bc7f 2a8648af9e3eb0a342594dedeb49d8af
994 2a8648af9e3eb0a342594dedeb49d8af 27a18c5d62e707fbb65223e62157abc4
imageio v2 with ffmpeg, on the other hand, does not yield consistent frame image returns when doing random access to frames (querying frame n does not consistently yield the frame with the nth hash), which works for pims ...
imageio v3 with pyav seems to work fine.
I would prefer to avoid posting the video publicly, but I would be happy to provide it to anyone in direct communication who would like to take the issue on.
The text was updated successfully, but these errors were encountered:
We are using python 3.9.13 and pims 0.6.1.
While trying to uncover some other issues, we noticed that pims shows a slightly weird behavior when iterating through frames.
pims seems to return one frame image for two indices, but then returns the same number of overall frames as imageio by leaving out the last frame:
imageio v2 with ffmpeg, on the other hand, does not yield consistent frame image returns when doing random access to frames (querying frame n does not consistently yield the frame with the nth hash), which works for pims ...
imageio v3 with pyav seems to work fine.
I would prefer to avoid posting the video publicly, but I would be happy to provide it to anyone in direct communication who would like to take the issue on.
The text was updated successfully, but these errors were encountered: