docstr: Return an initial state based on a single layer of attention
  
  Running attention might be overkill, but it is the simplest
  way to put the Linears and start_embedding in the computation graph
code: def initial_state(self, initial_value=None):
      """
      Return an initial state based on a single layer of attention
  
      Running attention might be overkill, but it is the simplest
      way to put the Linears and start_embedding in the computation graph
      """
      start = self.start_embedding
      if self.use_position:
          position = self.position_encoding([0]).squeeze(0)
          start = start + position
  
      # N=1
      # shape: 1xD
      key = self.w_key(start).unsqueeze(0)
  
      # shape: D
      query = self.w_query(start)
  
      # shape: 1xD
      value = self.w_value(start).unsqueeze(0)
  
      # unsqueeze to make it look like we are part of a batch of size 1
      output = self.attention(
          key.unsqueeze(0), query.unsqueeze(0), value.unsqueeze(0)
      ).squeeze(0)
      return TreeStack(
          value=Node(initial_value, key, value, output),
          parent=None,
          length=1,
      )
  
file_path: stanza/stanza/models/constituency/transformer_tree_stack.py
imports: from collections import namedtuple
  import torch
  import torch.nn
  from stanza.models.constituency.positional_encoding import SinusoidalEncoding
  from stanza.models.constituency.tree_stack import TreeStack
label_desc: Use image node_id 3 for calling the TransformerTreeStack obj's underlying member method code with example usage: obj.initial_state(initial_value) and returns: TreeStack