Straight-Through Estimator
Straight-through estimator, or STE, is a trick for training models that contain non-differentiable operations, notably the quantization operation commonly used in VQ-VAE.
The core idea is:
Use the non-differentiable operation in the forward pass, but replace its gradient with a simple surrogate in the backward pass.