class_docstr: Implementation of QR-DQN (Quantile Regression Deep Q-Network)
  
  See https://arxiv.org/abs/1710.10044 for details
class_docstr_tok: ["Implementation","of","QR-DQN","(","Quantile","Regression","Deep","Q-Network",")","See","https",":","\/\/arxiv.org\/abs\/1710.10044","for","details"]
code: def __init__(
      self,
      q_network,
      q_network_target,
      metrics_to_score=None,
      reward_network=None,
      q_network_cpe=None,
      q_network_cpe_target=None,
      actions: List[str] = field(default_factory=list),  # noqa: B008
      rl: RLParameters = field(
          default_factory=RLParameters
      ),  # noqa: B008
      double_q_learning: bool = True,
      num_atoms: int = 51,
      minibatch_size: int = 1024,
      minibatches_per_step: int = 1,
      optimizer: Optimizer__Union = field(  # noqa: B008
          default_factory=Optimizer__Union.default
      ),
      cpe_optimizer: Optimizer__Union = field(  # noqa: B008
          default_factory=Optimizer__Union.default
      ),
      evaluation: EvaluationParameters = field(  # noqa: B008
          default_factory=EvaluationParameters
      ),
  ) -> None:
      super().__init__(
          rl_parameters=rl,
          metrics_to_score=metrics_to_score,
          actions=actions,
          evaluation_parameters=evaluation,
      )
      # TODO: check to ensure no rl parameter value is set that isn't actively used by class
      self.double_q_learning = double_q_learning
      self.minibatch_size = minibatch_size
      self.minibatches_per_step = minibatches_per_step
      self._actions = actions
  
      self.q_network = q_network
      self.q_network_target = q_network_target
      self.q_network_optimizer = optimizer
  
      self.num_atoms = num_atoms
      self.register_buffer("quantiles", None)
      self.quantiles = (
          (0.5 + torch.arange(self.num_atoms).float())
          / float(self.num_atoms)
      ).view(1, -1)
  
      self._initialize_cpe(
          reward_network,
          q_network_cpe,
          q_network_cpe_target,
          optimizer=cpe_optimizer,
      )
  
file_path: ReAgent/reagent/training/qrdqn_trainer.py
imports: import logging
  from typing import List, Tuple
  import reagent.core.types
  import torch
  from reagent.core.configuration import resolve_defaults
  from reagent.core.dataclasses import field
  from reagent.core.parameters import EvaluationParameters, RLParameters
  from reagent.optimizer import SoftUpdate
  from reagent.optimizer.union import Optimizer__Union
  from reagent.training.dqn_trainer_base import DQNTrainerBaseLightning
label_desc: Use image node_id 1 to create a new QRDQNTrainer object from inherited base classes: DQNTrainerBaseLightning with example: obj = QRDQNTrainer(q_network, q_network_target, metrics_to_score, reward_network, q_network_cpe, q_network_cpe_target, actions, rl, double_q_learning, num_atoms, minibatch_size, minibatches_per_step, optimizer, cpe_optimizer, evaluation)