code: def scale_to_bounds(x, lower_bound, upper_bound):
      """
      DEPRECATRED: Use :obj:`~gpytorch.utils.grid.ScaleToBounds` instead.
  
      :param x: the input data
      :type x: torch.Tensor (... x n x d)
      :param float lower_bound: lower bound of scaled data
      :param float upper_bound: upper bound of scaled data
      :return: scaled data
      :rtype: torch.Tensor (... x n x d)
      """
      warnings.warn(
          "The `scale_to_bounds` method is deprecated. Use the `gpytorch.utils.grid.ScaleToBounds` module instead.",
          DeprecationWarning,
      )
      # Scale features so they fit inside grid bounds
      min_val = x.min()
      max_val = x.max()
      diff = max_val - min_val
      x = (x - min_val) * (
          0.95 * (upper_bound - lower_bound) / diff
      ) + 0.95 * lower_bound
      return x
  
file_path: gpytorch/gpytorch/utils/grid.py
imports: import math
  import warnings
  from typing import List, Tuple
  import torch
label_desc: Use image node_id 1 for calling a global function with example usage: scale_to_bounds(x, lower_bound, upper_bound) and returns: x