* fixed several bugs that prevented sort algorithms from beeing working in staging branch.
face-cnn, face-cnn-dissim and face-yaw now working again
blur, face, hist, hist-dissim already worked before
face-dissim still has an error
* applied requested changes from torzdf
* 1. fixed following error message when using seamless clone of openCV, if new_image
cannot be fitted into base_image in apply_new_face function
2. point structure in openCV should be (x,y) rather than (y,x)
* exchange variable name of maskx, masky so that these name corresponds to
X, Y
-scale in detector has been used as a member variable and shared between multiple threads. however scale heavily depends on the concrete image. if thread change occurs between calculation of scale, actual detection and postprocessing, then random behaviour and exceptions might happen. especially in the case of input images with varying sizes this might cause negative effects
-wrong scale factor calculation:
scale factor was calculated as: scale = target / source
whereas target and source are variables for the total number of pixels in the image (= width * height)
However, later on it was applied on the individual dimensions/components as width/height independantly:
e.g.: dims = (int(width * scale), int(height * scale))
or: int(face.left() / scale),
therefore scaling factor often was too small and detection for very big input images was performed on very small intermediate images
Therefore calculation has been changed to:
scale = sqrt(target / source)
* Add preview functionality to effmpeg. (#435)
* Add preview functionality to effmpeg.
effmpeg tool:
Preview for actions that have a video output now available.
Preview does not work when muxing audio.
* Model json unicode fix1 (#443)
* fixed Windows 10 path error while loading weights
* - fixed TypeError: the JSON object must be str, not 'bytes' with OriginalHighRes Model
* MTCNN Extractor and Extraction refactor (#453)
* implement mtcnn extractor
* mtcnn refactor and vram management changes
* cli arguments update for mtcnn/dlib split
* Add mtcnn models to gitignore
* Change multiprocessing on extract
* GUI changes to handle nargs defaults
* Early exit bugfix (#455)
* Fix extract early termination bug
* Fix extract early exit bug
* Multi face detection bugfix (#456)
* Multi face extraction fix
* Original high res cleanup 1 (#457)
* slight model re-factoring
- removed excess threading code
- added random kernel initialization to dense layer
* Slight OriginalHighRes re-factoring an code cleanup
* Required for Shaonlu mode (#416)
Added two modes - Original and Shaonlu.
The later requires this file to function.
* model update (#417)
New, functional Original 128 model
* OriginalHighRes 128 model update (#418)
Required for OriginalHighRes Model to function
* Fixed memory usage at 6GB cards. (#423)
- Switched default encoder to ORIGINAL
- Fixed memory consumption. Tested with geforce gtx 9800 ti with 6Gb; batch_size 8 no OOM or memory warnings now.
* added new model
* ndeed for HighRes Model_OriginalHighRes
* added OriginalHighRes model state save
* changed saving routine to ThreadPoolExecutor (faster with Python3)
* altered trainer (#425)
altered trainer to accommodate with model change
* Update Model.py (#424)
- Added saving state (currently only saved epoch number, to be extended in future)
- Changed saving to ThreadPoolExecutor
* Requirements version bump (#431)
This bumps the versions of:
scandir
h5py
Keras
opencv-python
to their latest vesions.
Virtual Environment will need to be setup again to make use of these.
* GUI version 3 (#411)
GUI version 3.0a
* Required for Shaonlu mode (#416)
Added two modes - Original and Shaonlu.
The later requires this file to function.
* model update (#417)
New, functional Original 128 model
* OriginalHighRes 128 model update (#418)
Required for OriginalHighRes Model to function
* Add OriginalHighRes 128 update to gui branch (#421)
* Required for Shaonlu mode (#416)
Added two modes - Original and Shaonlu.
The later requires this file to function.
* model update (#417)
New, functional Original 128 model
* OriginalHighRes 128 model update (#418)
Required for OriginalHighRes Model to function
* Dev gui (#420)
* reduce singletons
* Fix tooltips and screen boundaries on popup
* Remove dpi fix. Fix context filebrowsers
* fix tools.py execution and context filebrowser bugs
* Bugfixes (#422)
* Bump matplotlib requirement. Fix polyfit. Fix TQDM on sort
* Fixed memory usage at 6GB cards. (#423)
- Switched default encoder to ORIGINAL
- Fixed memory consumption. Tested with geforce gtx 9800 ti with 6Gb; batch_size 8 no OOM or memory warnings now.
* Staging (#426)
* altered trainer (#425)
altered trainer to accommodate with model change
* Update Model.py (#424)
- Added saving state (currently only saved epoch number, to be extended in future)
- Changed saving to ThreadPoolExecutor
* Add DPI Scaling (#428)
* Add dpi scaling
* Hotfix for effmpeg. (#429)
effmpeg fixed so it works both in cli and gui.
Initial work done to add previewing feature to effmpeg (currently does nothing).
Some small spacing changes in other files to improve PEP8 conformity.
* PEP8 Linting (#430)
* pep8 linting
* Requirements version bump (#432)
* altered trainer (#425)
altered trainer to accommodate with model change
* Update Model.py (#424)
- Added saving state (currently only saved epoch number, to be extended in future)
- Changed saving to ThreadPoolExecutor
* Requirements version bump (#431)
This bumps the versions of:
scandir
h5py
Keras
opencv-python
to their latest vesions.
Virtual Environment will need to be setup again to make use of these.
* High DPI Fixes (#433)
* dpi scaling
* DPI Fixes
* Fix and improve context manager. (#434)
effmpeg tool:
Context manager for GUI fixed.
Context manager in general:
Functionality extended to allow configuring the context with both:
command -> action
command -> variable (cli argument) -> action
* Change epoch option to iterations
* Change epochs to iterations
* Adjusted converter to work with OriginalHighRes model vector dim
* fixed field name to args
* New OriginalHighRes with lighter Encoder and decoder with more clarity
* changed f'' string formatting to old-style .format()
* Adjusted converter to work with OriginalHighRes model vector dim
* fixed field name to args
* New OriginalHighRes with lighter Encoder and decoder with more clarity
* Sort images properly (to make the frame range parameter meaningfull)
* Add backup mechanism for model weights.
* Replace 'print' call by 'tqdm.write' call.
Right now, lowmem and Original use the same filenames. Since their models are incompatible, this could lead to failure by attemptiong to load lowmem weights in original or vice versa. This namechange migration will rename existing lowmem models in order to prevent problems.
Recommend that all users either manually rename the lowmem files or run this branch to update to the correct filenames.
* Complete parity fix for GAN128.
This brings GAN128 to parity with GAN in terms of multi GPU support.
Unfortunately, it fails to run due to a naming error.
('The name "model_4" is used 2 times in the model. All layer names should be unique. Layer names: ', ['input_6', 'lambda_1', 'lambda_2', 'model_6', 'model_4', 'model_4'])
* Fix for GAN128 until #287 can be resolved
Issue #287 details why GAN128 cannot be fixed until Keras is fixed upstream.
* Changes to PR as per Clorr
Made changes to error handling to split into separate PR as requested by Clorr.
* Updated to support Output Sharpening arguments
Two new types of output sharpening methods have been added.
One that deals with a Box Blur method and the other with a Gaussian Blur method.
Box Blur method can be called using argument '-sh bsharpen' --- This method is not dynamic and can produce strong sharpening on your images. Sometimes it can yield great results and sometimes entirely the opposite.
Gaussian Blur method can be called using argument '-sh gsharpen' --- This method is dynamic and tries to adjust to your data set. As a result, while the sharpening effect might not be as strong as bsharpen, it is bound to produce a more natural looking sharpened image.
By default the parameter is set to none which will not run any sharpening on your output.
* Output Sharpening added
Two ways of sharpening your output have been added
-sh bsharpen
-sh gsharpen
* Update convert.py
* Fix broken multigpu GAN loading.
Fix for loading into the multi GPU model when it needs to load/save the original model.
* Move reference change.
Move reference change for single model so it is defined before load
* Add mutliGPU support to GAN128
Added support for mutligpu to GAN128
* Add Improved AutoEncoder model.
* Refactoring Model_IAE to match the new model folder structure
* Add Model_IAE in plugins
* Add Multi-GPU support
I added multi-GPU support to the new model layout. Currently, Original is not tested (due to OOM on my 2x 4gb 970s). LowMem is not tested with the current commit due to it not being available since the new pluginloader misses it.