class_docstr: The multi-output Value-at-Risk risk measure that operates on each output
  dimension independently. For the same reasons as `IndependentCVaR`, the risk
  estimates provided by this are in general more optimistic than the definition
  of VaR would suggest.
  
  Value-at-Risk measures the smallest possible reward (or largest possible loss)
  after excluding the worst outcomes with a total probability of `1 - alpha`. It
  is commonly used in financial risk management, and it corresponds to the
  `1 - alpha` quantile of a given random variable.
docstr: Calculate the VaR corresponding to the given samples.
  
  Args:
      samples: A `sample_shape x batch_shape x (q * n_w) x m`-dim tensor of
          posterior samples. The q-batches should be ordered so that each
          `n_w` block of samples correspond to the same input.
      X: A `batch_shape x q x d`-dim tensor of inputs. Ignored.
  
  Returns:
      A `sample_shape x batch_shape x q x m'`-dim tensor of VaR samples.
docstr_tok: ["Calculate","the","VaR","corresponding","to","the","given","samples",".","Args",":","samples",":","A","`","sample_shape","x","batch_shape","x","(","q","*","n_w",")","x","m","`","-dim","tensor","of","posterior","samples",".","The","q-batches","should","be","ordered","so","that","each","`","n_w","`","block","of","samples","correspond","to","the","same","input",".","X",":","A","`","batch_shape","x","q","x","d","`","-dim","tensor","of","inputs",".","Ignored",".","Returns",":","A","`","sample_shape","x","batch_shape","x","q","x","m","'","`","-dim","tensor","of","VaR","samples","."]
code: def forward(
      self, samples: Tensor, X: Optional[Tensor] = None
  ) -> Tensor:
      r"""Calculate the VaR corresponding to the given samples.
  
      Args:
          samples: A `sample_shape x batch_shape x (q * n_w) x m`-dim tensor of
              posterior samples. The q-batches should be ordered so that each
              `n_w` block of samples correspond to the same input.
          X: A `batch_shape x q x d`-dim tensor of inputs. Ignored.
  
      Returns:
          A `sample_shape x batch_shape x q x m'`-dim tensor of VaR samples.
      """
      sorted_samples = self._get_sorted_prepared_samples(samples)
      return sorted_samples[..., self.alpha_idx, :]
  
imports: import warnings
  from abc import ABC, abstractmethod
  from math import ceil
  from typing import Callable, List, Optional, Union
  import torch
  from botorch.acquisition.multi_objective.objective import IdentityMCMultiOutputObjective, MCMultiOutputObjective
  from botorch.acquisition.risk_measures import CVaR, RiskMeasureMCObjective, VaR
  from botorch.exceptions.errors import UnsupportedError
  from botorch.exceptions.warnings import BotorchWarning
  from botorch.models.model import Model
  from botorch.utils.multi_objective.pareto import is_non_dominated
  from botorch.utils.transforms import normalize
  from torch import Tensor
label_desc: Use image node_id 1 for calling the IndependentVaR obj's underlying member method code with example usage: obj.forward(samples, X) and returns: sorted_samples