code: def resample_while(
      asset, samplers, condition, max_trials=100, rng=default_rng()
  ):
      for _ in range(max_trials):
          for sampler in samplers:
              sampler(asset, rng)
          if not condition(asset):
              return
      else:
          raise RuntimeError("Failed to place", asset)
  
file_path: kubric/kubric/randomness.py
imports: import numpy
  import pyquaternion
  from typing import Optional, Tuple
  from kubric.core import color
  from kubric.core import objects
label_desc: Use image node_id 7 for calling a global function with example usage: resample_while(asset, samplers, condition, max_trials, rng) without return types