• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

JuliaIO / VideoIO.jl / 1034
34%

Build:
DEFAULT BRANCH: master
Ran 19 Aug 2020 06:11PM UTC
Jobs 6
Files 105
Run time 4min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
1034

push

travis-ci

web-flow
Add iterator interface to VideoReader objects (#261)

* Add iterator interface to VideoReader objects

I have added an iterator interface to the `VideoReader` type, making collecting
all frames of a video as simple as `f = openvideo(fname); imgs = collect(f)`.
The iterator returns a new array for each frame, as I think mutating the same
array on subsequent calls to `iterate` would be surprising and lead to strange
behavior when calling functions such as `collect`. Note that the VideoReader
iterator is mutable, like Channel or Stateful iterators in Julia, and will
resume iteration where it was last stopped, instead of at the beginning. I have
added some text in the documentation explaining this behavior, and also added
some tests.

* Do not collect all frames into memory to test iterator interface

Instead of collecting all frames into memory with `collect` to test the
`VideoReader` interface, I am instead testing the iterator interface with a
simple for loop. This should reduce the memory requirement for CI, and avoid
memory-related test errors on low memory CI VMs.

* Simplify test of mutability of `VideoReader` iterator

Instead of looping over the iterator to test that there are zero elements
remaining, it is simpler to just see if `iterate` returns `nothing`.

* Test that iterator interface for `VideoReader` does not mutate frames

I have added a test to verify that frames returned by the `VideoReader`
iterator interface have distinct storage.

498 of 1455 relevant lines covered (34.23%)

392822.39 hits per line

Jobs
ID Job ID Ran Files Coverage
1 1034.1 19 Aug 2020 06:12PM UTC 0
32.3
Travis Job 1034.1
2 1034.2 19 Aug 2020 06:16PM UTC 0
33.47
Travis Job 1034.2
3 1034.3 19 Aug 2020 06:12PM UTC 0
32.99
Travis Job 1034.3
4 1034.4 19 Aug 2020 06:11PM UTC 0
20.73
Travis Job 1034.4
5 1034.5 19 Aug 2020 06:14PM UTC 0
21.56
Travis Job 1034.5
6 1034.6 19 Aug 2020 06:15PM UTC 0
21.17
Travis Job 1034.6
Source Files on build 1034
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #1034
  • 004431b4 on github
  • Prev Build on master (#1029)
  • Next Build on master (#1035)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc