denoising-diffusion-pytorch
denoising-diffusion-pytorch copied to clipboard
A question on time embedding

I don't understand why (half_dim - 1) is used here. According to the transformer's time-coding formula, there should be "emb = math.log(10000) / half_dim", I don't think half_dim should minus 1 here.
@shixishi i'm not sure, it was faithfully transcribed from https://github.com/hojonathanho/diffusion/blob/master/diffusion_tf/nn.py#L100