class_docstr: DistributionOutput class for the Incremental (Spline) Quantile Function
  Parameters
  ----------
  num_pieces
      number of spline pieces for each spline
      ISQF reduces to IQF when num_pieces = 1
  qk_x
      List containing the x-positions of quantile knots
  tol
      tolerance for numerical safeguarding
class_docstr_tok: ["DistributionOutput","class","for","the","Incremental","(","Spline",")","Quantile","Function","Parameters","--","--","--","--","--","num_pieces","number","of","spline","pieces","for","each","spline","ISQF","reduces","to","IQF","when","num_pieces","=","1","qk_x","List","containing","the","x-positions","of","quantile","knots","tol","tolerance","for","numerical","safeguarding"]
docstr: auxiliary function reshaping knots and heights to (*batch_shape,
  num_qk-1, num_pieces) qk_x to (*batch_shape, num_qk)
docstr_tok: ["auxiliary","function","reshaping","knots","and","heights","to","(","*","batch_shape",",","num_qk-1",",","num_pieces",")","qk_x","to","(","*","batch_shape",",","num_qk",")"]
code: def reshape_spline_args(self, distr_args, qk_x: List[float]):
      """
      auxiliary function reshaping knots and heights to (*batch_shape,
      num_qk-1, num_pieces) qk_x to (*batch_shape, num_qk)
      """
  
      spline_knots, spline_heights = distr_args[0], distr_args[1]
      batch_shape = spline_knots.shape[:-1]
      num_qk, num_pieces = self.num_qk, self.num_pieces
  
      # repeat qk_x from (num_qk,) to (*batch_shape, num_qk)
      qk_x_repeat = torch.tensor(
          qk_x, dtype=spline_knots.dtype, device=spline_knots.device
      ).repeat(*batch_shape, 1)
  
      # knots and heights have shape (*batch_shape, (num_qk-1)*num_pieces)
      # reshape them to (*batch_shape, (num_qk-1), num_pieces)
      spline_knots_reshape = spline_knots.reshape(
          *batch_shape, (num_qk - 1), num_pieces
      )
      spline_heights_reshape = spline_heights.reshape(
          *batch_shape, (num_qk - 1), num_pieces
      )
  
      distr_args_reshape = (
          spline_knots_reshape,
          spline_heights_reshape,
          *distr_args[2:],
      )
  
      return distr_args_reshape, qk_x_repeat
  
imports: from typing import Dict, List, Optional, Tuple
  import torch
  import torch.nn.functional
  from torch.distributions import AffineTransform, TransformedDistribution
  from gluonts.core.component import validated
  from .distribution_output import DistributionOutput
label_desc: Use image node_id 4 for calling the ISQFOutput obj's underlying member method code with example usage: obj.reshape_spline_args(distr_args, qk_x) and returns: distr_args_reshape,  qk_x_repeat