Skip to content

Feature to loop extracted video to make up required lenght#91

Open
adradr wants to merge 1 commit into
RayVentura:stablefrom
adradr:feature/looper
Open

Feature to loop extracted video to make up required lenght#91
adradr wants to merge 1 commit into
RayVentura:stablefrom
adradr:feature/looper

Conversation

@adradr
Copy link
Copy Markdown

@adradr adradr commented Aug 13, 2023

✨ feat(handle_videos.py): add loop_video_until_target_length function and improve extract_random_clip_from_video function

A new function called loop_video_until_target_length is added, which loops the video by concatenating it with itself until it reaches the target length. The extract_random_clip_from_video function is also improved to handle cases where the video duration is too short by doubling its length until it meets the minimum requirement.

Proposed changes

Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue. 👀🔧

Types of changes

What types of changes does your code introduce to this project?
Put an x in the boxes that apply 😄🚀

  • Bugfix (non-breaking change which fixes an issue) 🐛
  • New feature (non-breaking change which adds functionality) ✨
  • Breaking change (fix or feature that would cause existing functionality to not work as expected) 💥
  • Documentation Update (if none of the other choices apply) 📖

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING.md 📚
  • I have added tests that prove my fix is effective or that my feature works ✅✔️
  • I have added necessary documentation (if appropriate) 📝

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc... 💡❓

References and related issues (e.g. #1234)

N/A 📌

✨ feat(handle_videos.py): add loop_video_until_target_length function and improve extract_random_clip_from_video function

The changes in this commit fix the indentation in the handle_videos.py file and add missing imports. Additionally, a new function called loop_video_until_target_length is added, which loops the video by concatenating it with itself until it reaches the target length. The extract_random_clip_from_video function is also improved to handle cases where the video duration is too short by doubling its length until it meets the minimum requirement.
@adradr adradr requested a review from RayVentura as a code owner August 13, 2023 22:28
@vercel
Copy link
Copy Markdown

vercel Bot commented Aug 13, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
short-gpt-dcs ⬜️ Ignored (Inspect) Visit Preview Aug 13, 2023 10:28pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants