class_docstr: Map X to [0, 1]^d for RangeParameter of type float and not log scale.
  
  Uses bounds l <= x <= u, sets x_tilde_i = (x_i - l_i) / (u_i - l_i).
  Constraints wTx <= b are converted to gTx_tilde <= h, where
  g_i = w_i (u_i - l_i) and h = b - wTl.
  
  Transform is done in-place.
class_docstr_tok: ["Map","X","to","[","0",",","1","]","^d","for","RangeParameter","of","type","float","and","not","log","scale",".","Uses","bounds","l","<","=","x","<","=","u",",","sets","x_tilde_i","=","(","x_i","-","l_i",")","\/","(","u_i","-","l_i",")",".","Constraints","wTx","<","=","b","are","converted","to","gTx_tilde","<","=","h",",","where","g_i","=","w_i","(","u_i","-","l_i",")","and","h","=","b","-","wTl",".","Transform","is","done","in-place","."]
docstr: Transform a univariate distribution in-place.
docstr_tok: ["Transform","a","univariate","distribution","in-place","."]
code: def _transform_univariate_distribution(
      self, distribution: ParameterDistribution, is_environmental: bool
  ) -> None:
      r"""Transform a univariate distribution in-place."""
      bounds = self.bounds[distribution.parameters[0]]
      p_range = bounds[1] - bounds[0]
      if p_range == self.target_range and (
          not is_environmental or bounds[0] == self.target_lb
      ):
          # NOTE: This helps avoid raising the error below if using a discrete
          # distribution in cases where we do not need to transform.
          return
      loc = distribution.distribution_parameters.get("loc", 0.0)
      if is_environmental:
          loc = self._normalize_value(loc, bounds)
      else:
          loc = loc / p_range * self.target_range
      distribution.distribution_parameters["loc"] = loc
      distribution.distribution_parameters["scale"] = (
          distribution.distribution_parameters.get("scale", 1.0)
          / p_range
          * self.target_range
      )
      # Check that the distribution is valid after the transform.
      try:
          distribution.distribution
      except TypeError:
          raise UnsupportedError(
              f"The distribution {str(distribution)} does not support transforming "
              "via `loc` and `scale` arguments. Consider manually normalizing the "
              "parameter and the corresponding distribution."
          )
  
imports: from typing import Dict, List, Optional, Tuple, TYPE_CHECKING
  import numpy
  from ax.core.observation import Observation, ObservationFeatures
  from ax.core.parameter import ParameterType, RangeParameter
  from ax.core.parameter_constraint import ParameterConstraint
  from ax.core.parameter_distribution import ParameterDistribution
  from ax.core.search_space import RobustSearchSpace, SearchSpace
  from ax.exceptions.core import UnsupportedError, UserInputError
  from ax.modelbridge.transforms.base import Transform
  from ax.models.types import TConfig
label_desc: Use image node_id 6 for calling the UnitX obj's underlying member method code with example usage: obj._transform_univariate_distribution(distribution, is_environmental) without return types