code: def __init__(self, observation_space, action_space, config):
      TorchPolicyV2.__init__(
          self,
          observation_space,
          action_space,
          config,
          max_seq_len=config["model"]["max_seq_len"],
      )
      self.regrets = []
  
file_path: ray/rllib_contrib/bandit/src/rllib_bandit/bandit/bandit_torch_policy.py
imports: import logging
  import time
  from gymnasium import spaces
  from rllib_bandit.bandit.bandit_torch_model import DiscreteLinearModel, DiscreteLinearModelThompsonSampling, DiscreteLinearModelUCB, ParametricLinearModelThompsonSampling, ParametricLinearModelUCB
  from ray.rllib.models.catalog import ModelCatalog
  from ray.rllib.models.modelv2 import restore_original_dimensions
  from ray.rllib.policy.sample_batch import SampleBatch
  from ray.rllib.policy.torch_policy_v2 import TorchPolicyV2
  from ray.rllib.utils.annotations import override
  from ray.rllib.utils.metrics.learner_info import LEARNER_STATS_KEY
  from ray.util.debug import log_once
label_desc: Use image node_id 1 to create a new BanditTorchPolicy object from inherited base classes: TorchPolicyV2 with example: obj = BanditTorchPolicy(observation_space, action_space, config)