Skip to content
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

QuickFaceSwap need update #4

Open
masterdefi opened this issue Sep 9, 2021 · 0 comments
Open

QuickFaceSwap need update #4

masterdefi opened this issue Sep 9, 2021 · 0 comments

Comments

@masterdefi
Copy link

masterdefi commented Sep 9, 2021

I think coding need update sir. Now onnx support GPU for decreasing time and need downloader from google drive, because upload direct to colab network is pretty slow.

!pip install insightface==0.2.1 onnxruntime-gpu moviepy
!pip install googledrivedownloader
!pip install imageio==2.4.1

Im using downloader like this.

GoogleDriveDownloader.download_file_from_google_drive(file_id='x',
dest_path='./demo_file/video.mp4')

x is for id file google drive.

They have itter parsing model. Im using like this.

!wget -P ./arcface_model https://github.com/neuralchen/SimSwap/releases/download/1.0/arcface_checkpoint.tar
!wget https://github.com/neuralchen/SimSwap/releases/download/1.0/checkpoints.zip
!unzip ./checkpoints.zip -d ./checkpoints
!wget -P ./parsing_model/checkpoint https://github.com/neuralchen/SimSwap/releases/download/1.0/79999_iter.pth

!wget --no-check-certificate "https://sh23tw.dm.files.1drv.com/y4mmGiIkNVigkSwOKDcV3nwMJulRGhbtHdkheehR5TArc52UjudUYNXAEvKCii2O5LAmzGCGK6IfleocxuDeoKxDZkNzDRSt4ZUlEt8GlSOpCXAFEkBwaZimtWGDRbpIGpb_pz9Nq5jATBQpezBS6G_UtspWTkgrXHHxhviV2nWy8APPx134zOZrUIbkSF6xnsqzs3uZ_SEX_m9Rey0ykpx9w" -O antelope.zip
!unzip ./antelope.zip -d ./insightface_func/models/

.
Coding on dot py need update too. so im using old style like this !python

!python test_video_swapmulti.py --no_simswaplogo --isTrain false --name people --Arc_path arcface_model/arcface_checkpoint.tar --pic_a_path ./demo_file/x.jpg --video_path ./demo_file/video.mp4 --output_path ./output/demo.mp4 --temp_path ./temp_results

That is for all swap face.

!python test_video_swapsingle.py --no_simswaplogo --isTrain false --name people --Arc_path arcface_model/arcface_checkpoint.tar --pic_a_path ./demo_file/pic.png --video_path ./demo_file/video.mp4 --output_path ./output/demo.mp4 --temp_path ./temp_results

For one face

!python test_video_swap_multispecific.py --no_simswaplogo --isTrain false --name people --Arc_path arcface_model/arcface_checkpoint.tar --video_path ./demo_file/video.mp4 --output_path ./output/demo.mp4 --temp_path ./temp_results --multisepcific_dir ./demo_file/multispecific

and last one for multi specific face.

for last time

About watermark of simswap logo

The above example command line is to add the simswap logo as the watermark by default. After discussion, they have added a hyper parameter to control whether to remove watermark.

The usage of removing the watermark is to add an argument: "--no_simswaplogo" to the command line,

I want to modification with GFPGAN but i cant.

Nice sir, for improving the development.

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

No branches or pull requests

1 participant