class_docstr: Gaussian random features for encoding time steps.
class_docstr_tok: ["Gaussian","random","features","for","encoding","time","steps","."]
code: def forward(self, t):
      t_proj = t[:, None] * self.W[None, :] * 2 * np.pi
      if self.complex_valued:
          return torch.exp(1j * t_proj)
      else:
          return torch.cat(
              [torch.sin(t_proj), torch.cos(t_proj)], dim=-1
          )
  
imports: import functools
  from functools import partial
  import numpy
  import torch
  from torch import Tensor, nn
  from torch.nn.modules.batchnorm import _BatchNorm
label_desc: Use image node_id 2 for calling the GaussianFourierProjection obj's underlying member method code with example usage: obj.forward(t) and returns: torch, torch