class_docstr: User should implement as their favorite RNN / Transformer / etc.
class_docstr_tok: ["User","should","implement","as","their","favorite","RNN","\/","Transformer","\/","etc","."]
docstr: Compute the logits for all tokens in a batched sequence :math:`p(y_{t+1}, ... y_{T}| y_1 \ldots t)`
  
  Parameters:
      inputs (batch_size x N x C ): next tokens to update representation
      state (tuple of batch_size x ...): everything needed for conditioning.
  
  Retuns:
      logits (*batch_size x C*): next set of logits.
  
      state (*tuple of batch_size x ...*): next set of logits.
docstr_tok: ["Compute","the","logits","for","all","tokens","in","a","batched","sequence",":","math",":","`","p","(","y_","{","t+1","}",",","...","y_","{","T","}","|","y_1","\\ldots","t",")","`","Parameters",":","inputs","(","batch_size","x","N","x","C",")",":","next","tokens","to","update","representation","state","(","tuple","of","batch_size","x","...",")",":","everything","needed","for","conditioning",".","Retuns",":","logits","(","*","batch_size","x","C","*",")",":","next","set","of","logits",".","state","(","*","tuple","of","batch_size","x","...","*",")",":","next","set","of","logits","."]
code: def forward(self, inputs, state=None):
      r"""
      Compute the logits for all tokens in a batched sequence :math:`p(y_{t+1}, ... y_{T}| y_1 \ldots t)`
  
      Parameters:
          inputs (batch_size x N x C ): next tokens to update representation
          state (tuple of batch_size x ...): everything needed for conditioning.
  
      Retuns:
          logits (*batch_size x C*): next set of logits.
  
          state (*tuple of batch_size x ...*): next set of logits.
      """
      pass
  
file_path: pytorch-struct/torch_struct/autoregressive.py
imports: import torch
  from .semirings import MaxSemiring, KMaxSemiring, TempMax
  from torch.distributions.distribution import Distribution
label_desc: Use image node_id 1 for calling the AutoregressiveModel obj's underlying member method code with example usage: obj.forward(inputs, state) without return types