class_docstr: Simple linear value net for demonstration purposes. 
class_docstr_tok: ["Simple","linear","value","net","for","demonstration","purposes","."]
docstr: Forward method. 
docstr_tok: ["Forward","method","."]
code: def forward(
      self, x_dict: Dict[str, torch.Tensor]
  ) -> Dict[str, torch.Tensor]:
      """Forward method."""
      # The same as for the policy can be said about the value net. Inputs and outputs have to be dicts.
      x = x_dict["observation"]
  
      value = self.value_net(x)
  
      value_dict = {"value": value}
      return value_dict
  
imports: from typing import Dict, Sequence
  import gym
  import torch
  import torch.nn
  from maze.core.agent.torch_actor_critic import TorchActorCritic
  from maze.core.agent.torch_policy import TorchPolicy
  from maze.core.agent.torch_state_critic import TorchSharedStateCritic
  from maze.core.rollout.rollout_generator import RolloutGenerator
  from maze.core.wrappers.maze_gym_env_wrapper import GymMazeEnv
  from maze.distributions.distribution_mapper import DistributionMapper
  from maze.perception.blocks.general.torch_model_block import TorchModelBlock
  from maze.train.parallelization.vector_env.sequential_vector_env import SequentialVectorEnv
  from maze.train.trainers.a2c.a2c_algorithm_config import A2CAlgorithmConfig
  from maze.train.trainers.a2c.a2c_trainer import A2C
  from maze.train.trainers.common.evaluators.rollout_evaluator import RolloutEvaluator
  from maze.train.trainers.common.model_selection.best_model_selection import BestModelSelection
  from maze.utils.log_stats_utils import setup_logging
label_desc: Use image node_id 2 for calling the CartpoleValueNet obj's underlying member method code with example usage: obj.forward(x_dict) and returns: value_dict