deepghs / waifuc

Efficient Train Data Collector for Anime Waifu
https://deepghs.github.io/waifuc/
MIT License
292 stars 25 forks source link

dev(narugo): allow to scrap all the frames #54

Closed narugo1992 closed 8 months ago

narugo1992 commented 8 months ago
from waifuc.source import VideoSource

# extract all frames, with minimal time interval 0.5s 
s = VideoSource('1.mp4', key_frames_only=False)
s.export('/data/video_frames')
from waifuc.source import VideoSource

# extract key frames only, with minimal time interval 0.2s
s = VideoSource.from_directory('/your/directory', min_frame_interval=0.2)
s.export('/data/video_frames')
codecov[bot] commented 8 months ago

Codecov Report

Attention: Patch coverage is 80.00000% with 3 lines in your changes are missing coverage. Please review.

Project coverage is 57.09%. Comparing base (91c1f20) to head (cadc87f).

Files Patch % Lines
waifuc/source/video.py 80.00% 3 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #54 +/- ## ========================================== + Coverage 57.01% 57.09% +0.08% ========================================== Files 50 50 Lines 2631 2641 +10 ========================================== + Hits 1500 1508 +8 - Misses 1131 1133 +2 ``` | [Flag](https://app.codecov.io/gh/deepghs/waifuc/pull/54/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=deepghs) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/deepghs/waifuc/pull/54/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=deepghs) | `57.09% <80.00%> (+0.08%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=deepghs#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.