hacksider / Deep-Live-Cam

real time face swap and one-click video deepfake with only a single image
GNU Affero General Public License v3.0
34.93k stars 4.93k forks source link

Dynamic requirements with pyproject.toml #391

Open 0x78f1935 opened 3 weeks ago

0x78f1935 commented 3 weeks ago

Description

I was using a different version of Python (3.12.2) but within the requirements.txt various libraries where hardcoded.

Type of change

How Has This Been Tested?

This has not been fully tested. It seems to work on my machine with the exception that my face gets a black square. I'm suspecting ffmpeg is the issue here. In addition I don't have darwin or arm64 hardware to my disposal.

Checklist:

Summary by Sourcery

Introduce pyproject.toml for dynamic dependency management, update documentation for environment setup, and enhance code quality with linting and refactoring.

New Features:

Enhancements:

Documentation:

sourcery-ai[bot] commented 3 weeks ago

Reviewer's Guide by Sourcery

This pull request introduces several significant changes to the project, primarily focusing on improving the development environment, code quality, and dependency management. The main changes include:

  1. Introduction of pyproject.toml for dynamic requirements management.
  2. Addition of a Python linter (Flake8) and fixing of linting violations.
  3. Refactoring of code to improve readability and adhere to best practices.
  4. Updates to the README.md file to reflect new setup instructions.
  5. Minor adjustments to various modules for consistency and better code organization.

File-Level Changes

Files Changes
README.md
pyproject.toml
Introduced pyproject.toml for managing project dependencies and added instructions for compiling requirements
modules/core.py
modules/ui.py
modules/utilities.py
modules/processors/frame/core.py
modules/processors/frame/face_enhancer.py
modules/processors/frame/face_swapper.py
Refactored code to improve readability, including breaking long lines and improving function signatures
README.md Updated README.md with new setup instructions for virtual environment and dependency management
modules/core.py
modules/ui.py
modules/utilities.py
modules/processors/frame/core.py
modules/processors/frame/face_enhancer.py
modules/processors/frame/face_swapper.py
modules/globals.py
Added Flake8 linter and fixed linting violations across the project
modules/processors/frame/face_enhancer.py
modules/processors/frame/face_swapper.py
Adjusted import statements and file paths for consistency across modules
modules/ui.py
modules/globals.py
Removed commented-out code and unused variables

Tips - Trigger a new Sourcery review by commenting `@sourcery-ai review` on the pull request. - Continue your discussion with Sourcery by replying directly to review comments. - You can change your review settings at any time by accessing your [dashboard](https://app.sourcery.ai): - Enable or disable the Sourcery-generated pull request summary or reviewer's guide; - Change the review language; - You can always [contact us](mailto:support@sourcery.ai) if you have any questions or feedback.
0x78f1935 commented 3 weeks ago

I don't wanna talk anymore to chatGPT (sourcery-ai). If there are issues, please let me know.