Teeth do not appear regardless of batch size (8-256), optional memory saving gradients/pixel shuffler etc and training time (up to 4 days)
Since the refactor I have been unable to get defined teeth regardless of the clearness and quantity of faces (up to 10,000) and/or enabling optional parameters or changing batch size On the original trainer. No matter the A or B face, (tried 20+ combinations, 10 differing subjects) teeth remain a fake looking white bar. This has not been a problem since before the refactor. Teeth appear in the Low memory Model but not the original or Unbalanced. Losses never dip below 0.019 no matter the training time. Is there a feature i have to enable? Memory saving gradients created extremely blurry swaps.
I have never been able to get teeth using Original model. I've seen quite a few mentions of these fine-grained details showing up in larger models though ( dfaker / villian / unbalanced ).
I'm surprised at your mentioning that the Low men model returns better detail considering it's the same model architecture but using fewer filters/complexity to transform the image. Do you have an example?
The loss should never reduce to zero ( and would likely represent a bad thing as it signifies major over-fitting ). The loss level that you plateau at should be proportionate to your dataset diversity ( and it sounds like your using 10k + images so that's a lot )
There has been general feedback that batch sizes of 8, 16, 32 have been returning better quality versus larger batch sizes ( although large batch sizes compute faster ) but this is still somewhat unsettled.
You shouldn't use memory saving gradients on a model unless you can't run batch size 8 on a model. while the results won't differ, it just slows computation down overall.
if you're fitting a batch size of 256 on original, I really recommend you use a better, more complex model since you will have the VRAM for it (@256 batch size sounds like you do). if not use m-s-g or ping-pong to enable those models
Okay, listen. Teeth has no simple relation to a model and more relation to your data.
-
It's not how many samples you have it's the number of samples with teeth with matching face pitch that is important.
-
Low-mem model doesn't help but I believe it might be possible.
-
Using hideous batch sizes such as 256 definitely doesn't help because of how
lossis calculated for big batches. -
Using 10k faces doesn't help as I am sure you are unable to check all of these and I assume that most of dataset are garbage which makes the training worse.
-
What you can do is:
- sieve through the A and B datasets choosing only ones that have teeth clearly exposed and copy these to a different folder.
- Train specifically on these samples until teeth details manifest to a level you are happy with.
- Go back to training on the overall dataset.
I have heavily curated the facesets and they are not garbage, there are no false identified faces or blurry images but I understand why you may think that. Are you suggesting to train the exposed teeth temporary facesets against themselves or the smaller teeth faceset against the whole of the original faceset? i will try reducing the batch size and training only on the teeth mages and get back to you.
Unfortunately, nothing you have stated is actually a bug or anything with the code. Faceswap is data driven and starts from a random state. Unfortunately, it is not possible to guarantee particular results no matter what we do. There are only actions you can take to try to maximize your quality. Teeth are always problematic due to their VERY low scoring potential. Since even predicting a black line in the wrong place will actually reduce the scoring. MSG is much slower than without and will always take longer to train out of blur. Lowmem only differs from Original by how much latent space it has. There is literally nothing that Lowmem can do that Original cannot. (except for run on lower end systems) Loss is not a measure of quality and is unlikely to EVER go below .02 for the simple fact that AIs are lossy, they will always have some loss. They can't recreate an image perfectly without just memorizing that image.
I'm closing this issue since it's really not an issue. This isn't a bug, or a fixable problem, it's just a matter of your data and particular training. If you want to discuss your issues, please join our Discord server since it's a much better place for discussions.