class_docstr: Trainer for fitting Seq2Reward planning outcomes to a neural network-based policy
class_docstr_tok: ["Trainer","for","fitting","Seq2Reward","planning","outcomes","to","a","neural","network-based","policy"]
code: def __init__(
      self,
      compress_model_network: FloatFeatureFullyConnected,
      seq2reward_network: Seq2RewardNetwork,
      params: Seq2RewardTrainerParameters,
  ):
      super().__init__()
      self.compress_model_network = compress_model_network
      self.seq2reward_network = seq2reward_network
      self.params = params
  
      # permutations used to do planning
      self.all_permut = gen_permutations(
          params.multi_steps, len(self.params.action_names)
      )
  
imports: import logging
  import reagent.core.types
  import torch
  import torch.nn.functional
  from reagent.core.parameters import Seq2RewardTrainerParameters
  from reagent.core.types import FeatureData
  from reagent.models.fully_connected_network import FloatFeatureFullyConnected
  from reagent.models.seq2reward_model import Seq2RewardNetwork
  from reagent.training.reagent_lightning_module import ReAgentLightningModule
  from reagent.training.utils import gen_permutations
  from reagent.training.world_model.seq2reward_trainer import get_Q
label_desc: Use image node_id 1 to create a new CompressModelTrainer object from inherited base classes: ReAgentLightningModule with example: obj = CompressModelTrainer(compress_model_network, seq2reward_network, params)