This code borrows heavily from [[pytorch-CycleGAN-and-pix2pix]](https://github.com/junyanz/pytorch-CycleGAN-and-pix2pix)[[Pytorch-UNet]](https://github.com/milesial/Pytorch-UNet)[[pix2pixHD]](https://github.com/NVIDIA/pix2pixHD).
self.parser.add_argument('--use_gpu',action='store_true',help='if input it, use gpu')
self.parser.add_argument('--use_gpu',type=bool,default=True,help='if True, use gpu')
# self.parser.add_argument('--use_gpu', action='store_true', help='if input it, use gpu')
self.parser.add_argument('--media_path',type=str,default='./hands_test.mp4',help='your videos or images path')
self.parser.add_argument('--mode',type=str,default='auto',help='add or clean mosaic into your media auto | add | clean')
self.parser.add_argument('--model_path',type=str,default='./pretrained_models/add_hands_128.pth',help='pretrained model path')
...
...
@@ -24,7 +26,7 @@ class Options():
self.parser.add_argument('--output_size',type=int,default=0,help='size of output file,if 0 -> origin')
#CleanMosaic
self.parser.add_argument('--netG',type=str,default='auto',help='select model to use for netG(clean mosaic) -> auto | unet_128 | resnet_9blocks | HD')
self.parser.add_argument('--netG',type=str,default='auto',help='select model to use for netG(clean mosaic) -> auto | unet_128 | resnet_9blocks | HD | video')
self.parser.add_argument('--mosaic_position_model_path',type=str,default='auto',help='name of model use to find mosaic position')
self.parser.add_argument('--no_feather',action='store_true',help='if true, no edge feather and color correction, but run faster')
self.parser.add_argument('--medfilt_num',type=int,default=11,help='medfilt window of mosaic movement in the video')