• Sayak Paul's avatar
    [Feat] add tiny Autoencoder for (almost) instant decoding (#4384) · 18fc40c1
    Sayak Paul authored
    
    
    * add: model implementation of tiny autoencoder.
    
    * add: inits.
    
    * push the latest devs.
    
    * add: conversion script and finish.
    
    * add: scaling factor args.
    
    * debugging
    
    * fix denormalization.
    
    * fix: positional argument.
    
    * handle use_torch_2_0_or_xformers.
    
    * handle post_quant_conv
    
    * handle dtype
    
    * fix: sdxl image processor for tiny ae.
    
    * fix: sdxl image processor for tiny ae.
    
    * unify upcasting logic.
    
    * copied from madness.
    
    * remove trailing whitespace.
    
    * set is_tiny_vae = False
    
    * address PR comments.
    
    * change to AutoencoderTiny
    
    * make act_fn an str throughout
    
    * fix: apply_forward_hook decorator call
    
    * get rid of the special is_tiny_vae flag.
    
    * directly scale the output.
    
    * fix dummies?
    
    * fix: act_fn.
    
    * get rid of the Clamp() layer.
    
    * bring back copied from.
    
    * movement of the blocks to appropriate modules.
    
    * add: docstrings to AutoencoderTiny
    
    * add: documentation.
    
    * changes to the conversion script.
    
    * add doc entry.
    
    * settle tests.
    
    * style
    
    * add one slow test.
    
    * fix
    
    * fix 2
    
    * fix 2
    
    * fix: 4
    
    * fix: 5
    
    * finish integration tests
    
    * Apply suggestions from code review
    Co-authored-by: default avatarSteven Liu <59462357+stevhliu@users.noreply.github.com>
    
    * style
    
    ---------
    Co-authored-by: default avatarSteven Liu <59462357+stevhliu@users.noreply.github.com>
    18fc40c1
test_models_vae.py 24.2 KB