class_docstr: Step sampler on a sampling path.
docstr: Choose a random axis from region.transformLayer.
docstr_tok: ["Choose","a","random","axis","from","region.transformLayer","."]
code: def generate_direction(self, ui, region, scale):
      """Choose a random axis from region.transformLayer."""
      return generate_region_random_direction(ui, region, scale=scale)
  
imports: import numpy
  import matplotlib.pyplot
  from ultranest.samplingpath import SamplingPath, ContourSamplingPath, extrapolate_ahead
  from ultranest.stepsampler import StepSampler
  from ultranest.stepsampler import generate_region_oriented_direction, generate_region_random_direction, generate_random_direction
  from ultranest.flatnuts import ClockedStepSampler, ClockedBisectSampler, ClockedNUTSSampler
  from ultranest.flatnuts import SingleJumper, DirectJumper, IntervalJumper
label_desc: Use image node_id 7 for calling the SamplingPathStepSampler obj's underlying member method code with example usage: obj.generate_direction(ui, region, scale) and returns: generate_region_random_direction