Skip to content

Improved video generation , performance and quality #742

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

overcrash66
Copy link

This pull request introduces several enhancements and fixes across multiple files, focusing on improving error handling, refining video streaming and downloading functionality, and adding utility updates. Below is a summary of the most important changes grouped by theme.

Error Handling Improvements:

  • Improved error handling in the stream_video function to validate file existence, ensure range values are within valid bounds, and handle parsing errors gracefully.
  • Enhanced the download_video function to check file existence, readability, and determine appropriate media types dynamically, with detailed logging for errors.

Video Streaming and Downloading Enhancements:

  • Fixed a bug in the get_task function by correcting a variable name (v to file) for generating URI paths.
  • Updated stream_video to handle partial content requests more robustly by ensuring valid byte ranges and fallback behavior for invalid ranges.

Dependency and Configuration Updates:

  • Added Query import in app/controllers/v1/video.py to support query parameters in API endpoints.
  • Introduced conditional Redis URL construction based on the presence of a password in the configuration.

Utility and Code Cleanups:

  • Removed an unused Query import from the create_task function.

Script Enhancements:

  • Modified webui.bat to activate a Python virtual environment if it exists and added optional Hugging Face mirror settings.

Improve video Quality and performance:

  • Advanced Encoding Parameter
  • Enhanced FFmpeg Configuration
  • Memory Management Improvements
  • Two-Pass Encoding (non-Windows)
  • Advanced Image Processing
  • Performance Optimizations (Adaptive thread count)
  • Resolution and Dimension Handling

Manual tests:

Tested only on windows 10 , with python 3.10

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.

1 participant