Commit Graph

75 Commits

Author SHA1 Message Date
Colombo ef90316f27 1 2019-09-19 17:29:12 +04:00
Colombo dc11ec32be SAE : WARNING, RETRAIN IS REQUIRED !
fixed model sizes from previous update.
avoided bug in ML framework(keras) that forces to train the model on random noise.

Converter: added blur on the same keys as sharpness

Added new model 'TrueFace'. This is a GAN model ported from https://github.com/NVlabs/FUNIT
Model produces near zero morphing and high detail face.
Model has higher failure rate than other models.
Keep src and dst faceset in same lighting conditions.
2019-09-19 11:13:56 +04:00
Colombo b6b92bded0 converter: now writes a filename of current frame config,
SAE: removed multiscale decoder, because it's not effective
2019-09-13 08:59:00 +04:00
Colombo 7ed38a8097 Converter:
Session is now saved to the model folder.

blur and erode ranges are increased to -400+400

hist-match-bw is now replaced with seamless2 mode.

Added 'ebs' color transfer mode (works only on Windows).

FANSEG model (used in FAN-x mask modes) is retrained with new model configuration
and now produces better precision and less jitter
2019-09-07 13:57:42 +04:00
Colombo bac9d5a99d nothing interesting 2019-08-30 09:49:07 +04:00
iperov d129b5dd7f sort data for CAInitializerMP 2019-08-25 07:50:27 +04:00
iperov 407ce3b1ca Added interactive converter.
With interactive converter you can change any parameter of any frame and see the result in real time.

Converter: added motion_blur_power param.
Motion blur is applied by precomputed motion vectors.
So the moving face will look more realistic.

RecycleGAN model is removed.

Added experimental AVATAR model. Minimum required VRAM is 6GB (NVIDIA), 12GB (AMD)
Usage:
1) place data_src.mp4 10-20min square resolution video of news reporter sitting at the table with static background,
   other faces should not appear in frames.
2) process "extract images from video data_src.bat" with FULL fps
3) place data_dst.mp4 video of face who will control the src face
4) process "extract images from video data_dst FULL FPS.bat"
5) process "data_src mark faces S3FD best GPU.bat"
6) process "data_dst extract unaligned faces S3FD best GPU.bat"
7) train AVATAR.bat stage 1, tune batch size to maximum for your card (32 for 6GB), train to 50k+ iters.
8) train AVATAR.bat stage 2, tune batch size to maximum for your card (4 for 6GB), train to decent sharpness.
9) convert AVATAR.bat
10) converted to mp4.bat

updated versions of modules
2019-08-24 12:57:29 +04:00
iperov b72d5a3f9a fixed error "Failed to get convolution algorithm" on some systems
fixed error "dll load failed" on some systems
Expanded eyebrows line of face masks. It does not affect mask of FAN-x converter mode.
2019-08-11 11:17:22 +04:00
iperov c9da4cd89b fix for plaidML 2019-05-24 09:30:39 +04:00
iperov bde700243c fix for plaidML 2019-05-05 19:22:26 +04:00
iperov 0cd8dd7296 upd comment 2019-04-24 11:41:10 +04:00
iperov 947feac047 refactorings 2019-04-24 11:28:58 +04:00
iperov dcbdc79e84 fix for plaidML 2019-04-20 17:29:50 +04:00
iperov 046649e6be update == 04.20.2019 == (#242)
* superb improved fanseg

* _

* _

* added FANseg extractor for src and dst faces to use it in training

* -

* _

* _

* update to 'partial' func

* _

* trained FANSeg_256_full_face.h5,
new experimental models: AVATAR, RecycleGAN

* _

* _

* _

* fix for TCC mode cards(tesla), was conflict with plaidML initialization.

* _

* update manuals

* _
2019-04-20 08:23:08 +04:00
iperov 41601f50b8 upd pynvml.py 2019-04-05 21:33:53 +04:00
iperov 4683c362ac changing SubpixelUpscaler to variable H,W dims,
tensorflow backend : using depth_to_space in SubpixelUpscaler, so training speed increased by 4%
2019-03-28 17:55:42 +04:00
iperov bb02cc1d97 _ 2019-03-25 13:28:08 +04:00
iperov 37505d88e3 old SAE model will not work with this update.
Fixed bug when SAE can be collapsed during a time.

SAE: removed CA weights and encoder/decoder dims.

added new options:

Encoder dims per channel (21-85 ?:help skip:%d)
More encoder dims help to recognize more facial features, but require more VRAM. You can fine-tune model size to fit your GPU.

Decoder dims per channel (11-85 ?:help skip:%d)
More decoder dims help to get better details, but require more VRAM. You can fine-tune model size to fit your GPU.

Add residual blocks to decoder? (y/n, ?:help skip:n) :
These blocks help to get better details, but require more computing time.

Remove gray border? (y/n, ?:help skip:n) :
Removes gray border of predicted face, but requires more computing resources.
2019-03-24 15:35:02 +04:00
iperov 4f4447d719 nnlib: implemented ReflectionPadding2D for plaidML,
wrapping Conv2D with new padding param
2019-03-23 22:20:05 +04:00
iperov 9849bcc1e5 fix 2019-03-21 19:04:46 +04:00
iperov 565af4d1da refactoring 2019-03-21 18:58:38 +04:00
iperov a3df04999c removing trailing spaces 2019-03-19 23:53:27 +04:00
iperov b8efb4cbba enhancing landmarks extractor by using s3fd second pass inside second pass,
it will be x2 slower, but time will be saved due to more images will be marked properly
works on 2GB+
2019-03-18 10:25:24 +04:00
iperov 2b40fa182f fix 2019-03-17 23:50:18 +04:00
iperov a71defc69a removing fail solutions 2019-03-17 23:47:14 +04:00
iperov 7aebfa3f7f added AdaBound 2019-03-17 19:17:44 +04:00
iperov d6a45763a2 SAE: added option "Use CA weights":
Initialize network with 'Convolution Aware' weights. This may help to achieve a higher accuracy model, but consumes time at first run.
2019-03-16 12:54:36 +04:00
iperov 8da47fec13 fix ModelBase, nnlib 2019-03-13 20:53:59 +04:00
iperov a9026ccb67 fix ModelBase, nnlib 2019-03-13 19:50:16 +04:00
iperov 90a7d4b1e7 fix force_plaidML 2019-03-13 18:30:40 +04:00
iperov 58763756f5 SAE: removed simple_optimizer . Added optimizer mode for tensorflow only (NVIDIA cards), allows to train x2-x3 bigger networks with normal Adam optimizer, consuming VRAM and CPU power. 2019-03-13 11:54:17 +04:00
iperov 69174a48e0 fix DFLOptimizer 2019-03-12 16:56:59 +04:00
iperov 46ff33bf89 SAE: dssim kernel size now depends on resolution 2019-03-12 09:49:40 +04:00
iperov fd3b9add2f SAE: added option "simple optimizer" allows to train bigger networks on same VRAM
nnlib: added DFLOptimizer is my own optimizer
2019-03-12 09:32:35 +04:00
iperov ee8dbcbc35 revert back Adam 2019-03-11 21:52:36 +04:00
iperov e4637336ef added ability to save optimizers states which work with K.function,
added custom Adam that can save 'iterations' param
2019-03-11 18:23:01 +04:00
iperov 9440224556 change TF console log level to 'errors only' 2019-03-09 20:23:33 +04:00
iperov 5587c93e01 fix ConverterMasked.py,
changing requirements
changing device.py ENV vars
2019-03-07 19:48:12 +04:00
iperov c3eea0cf98 upd device.py 2019-03-04 11:17:08 +04:00
iperov 6094e5ead8 added Util.recover_original_aligned_filename 2019-03-04 10:57:44 +04:00
iperov 7cea93c0f2 nothing interesting 2019-02-28 20:10:58 +04:00
iperov 7db469a1da fix nnlib/device.py for some notebooks 2019-02-25 21:34:47 +04:00
iperov ac5ac75645 nnlib added force_has_nvidia_device 2019-02-25 21:15:58 +04:00
iperov f0a20b46d3 SAE: added new archi 'vg' 2019-02-21 17:53:59 +04:00
iperov d66829aae4 proper nnlib.dssim 2019-02-20 19:03:49 +04:00
iperov b939fe9d85 OpenCL support: fix bug, adding new requirements files 2019-02-19 20:48:39 +04:00
iperov 72ba6b103c added support of AMD videocards
added Intel's plaidML backend to use OpenCL engine. Check new requirements.
smart choosing of backend in device.py
env var 'force_plaidML' can be choosed to forced using plaidML
all tf functions transferred to pure keras
MTCNN transferred to pure keras, but it works slow on plaidML (forced to CPU in this case)
default batch size for all models and VRAMs now 4, feel free to adjust it on your own
SAE: default style options now ZERO, because there are no best values for all scenes, set them on your own.
SAE: return back option pixel_loss, feel free to enable it on your own.
SAE: added option multiscale_decoder default is true, but you can disable it to get 100% same as H,DF,LIAEF model behaviour.
fix converter output to .png
added linux fork reference to doc/doc_build_and_repository_info.md
2019-02-19 17:33:12 +04:00
iperov 06fe1314d8 removing default yaw_value from DFLIMG files,
added better pitch/yaw estimator from 68 landmarks,
improving face yaw accuracy for sorting and trainers,
added sort by face-pitch
2019-02-12 21:31:37 +04:00
iperov 429e7e6aee upd nnlib.py 2019-02-12 09:30:38 +04:00
iperov d8833e929e upd nnlib.py 2019-02-11 21:29:30 +04:00