PeterL1n / BackgroundMattingV2

Real-Time High-Resolution Background Matting
MIT License
6.81k stars 950 forks source link

basic information about inference_video.py #112

Closed Adorablepet closed 3 years ago

Adorablepet commented 3 years ago

Thanks for you sharing codes. This is so a greate project.But when running inference_video.py, appeared a problem with characters standing upside down. This is my command, as follows:

python inference_video.py --model-type mattingrefine --model-backbone resnet50 --model-backbone-scale 0.25 --model-refine-mode sampling --model-refine-sample-pixels 80000 --model-checkpoint checkpoint/pytorch_resnet50.pth --video-src
video/nv_green.mov --video-bgr video/nv_green.png --video-resize 1920 1080 --preprocess-alignment --output-dir output/nv --output-type com

nv_green.mov 1920x1080 nv_green.png 1920x1080

You can look at test.zip test.zip

I don't know how to solve it, can you tell me, thankss again,

PeterL1n commented 3 years ago

Hum...

I guess you captured the footage using a mobile phone? I suspect somehow the video reading part is wrong. Why don't you just simply rotate the output video back.

Also just curious. You are already using a green-screen, what do you feel about our method compared to using chroma-keying?

Adorablepet commented 3 years ago

Yes, I captured the footage using a mobile phone. I will check the video reading part. Mainly before my character background is a bit complicated, the effect is not good, so I just use green-screen. Your method is very good, don not captured the footage without green-screen, Just a little more complex scenes don't work well, expect your new model. Thanks again.