johndpope / MegaPortrait-hack

Using Claude Opus to reverse engineer code from MegaPortraits: One-shot Megapixel Neural Head Avatars
https://arxiv.org/abs/2207.07621
42 stars 7 forks source link

Feat/16 make faster #28

Closed johndpope closed 3 weeks ago

johndpope commented 3 weeks ago

change the conv to use pointwise separable convolution - makes the checkpoint 400mb smaller - maybe faster for inference.

change the loss to use the driving image. expose helper to crop source frame. i train this tonight - see how it looks in the morning.

Epoch [1/200000] completed in 239.85 seconds Data Loading Time: 0.00 seconds Face Cropping and Warping Time: 74.74 seconds Generator Forward Time: 6.33 seconds Loss Calculation Time: 5.98 seconds Generator Backward Time: 22.42 seconds Discriminator Forward Time: 0.11 seconds Discriminator Backward Time: 0.57 seconds

UPDATE Epoch [1/200000] completed in 160.88 seconds Data Loading Time: 0.00 seconds Face Cropping and Warping Time: 0.00 seconds Generator Forward Time: 6.30 seconds Loss Calculation Time: 5.62 seconds Generator Backward Time: 22.29 seconds Discriminator Forward Time: 0.10 seconds Discriminator Backward Time: 0.59 seconds

johndpope commented 3 weeks ago

i put the warping / cropping code into the other branch with saving out to npz files.