class_docstr: Encapsulates a structured torch policy and critic
  for training actor-critic algorithms in structured environments.
  
  :param policy: A structured torch policy for training in structured environments.
  :param critic: A structured torch critic for training in structured environments.
  :param device: Device the model (networks) should be located on (cpu or cuda)
docstr: One method to compute the policy and critic output in one go, managing the sub-steps, individual critic types
  shared embeddings of networks.
  
  :param record: The StructuredSpacesRecord holding the observation and actor ids.
  :param temperature: (Optional) The temperature used for initializing the probability distribution of the action
      heads.
  
  :returns: A tuple of the policy and critic output.
docstr_tok: ["One","method","to","compute","the","policy","and","critic","output","in","one","go",",","managing","the","sub-steps",",","individual","critic","types","shared","embeddings","of","networks",".",":","param","record",":","The","StructuredSpacesRecord","holding","the","observation","and","actor","ids",".",":","param","temperature",":","(","Optional",")","The","temperature","used","for","initializing","the","probability","distribution","of","the","action","heads",".",":","returns",":","A","tuple","of","the","policy","and","critic","output","."]
code: def compute_actor_critic_output(
      self, record: StructuredSpacesRecord, temperature: float = 1.0
  ) -> Tuple[PolicyOutput, StateCriticOutput]:
      """One method to compute the policy and critic output in one go, managing the sub-steps, individual critic types
      shared embeddings of networks.
  
      :param record: The StructuredSpacesRecord holding the observation and actor ids.
      :param temperature: (Optional) The temperature used for initializing the probability distribution of the action
          heads.
  
      :returns: A tuple of the policy and critic output.
      """
      policy_output = self.policy.compute_policy_output(
          record, temperature=temperature
      )
      critic_input = StateCriticInput.build(policy_output, record)
  
      critic_output = self.critic.predict_values(critic_input)
      return policy_output, critic_output
  
imports: from typing import List, Dict, Union, Tuple
  import torch
  from maze.core.agent.state_critic_input_output import StateCriticOutput, StateCriticInput
  from maze.core.agent.torch_model import TorchModel
  from maze.core.agent.torch_policy import TorchPolicy
  from maze.core.agent.torch_policy_output import PolicyOutput
  from maze.core.agent.torch_state_action_critic import TorchStateActionCritic
  from maze.core.agent.torch_state_critic import TorchStateCritic
  from maze.core.annotations import override
  from maze.core.trajectory_recording.records.structured_spaces_record import StructuredSpacesRecord
label_desc: Use image node_id 9 for calling the TorchActorCritic obj's underlying member method code with example usage: obj.compute_actor_critic_output(record, temperature) and returns: policy_output,  critic_output