code: def mpf_rand(prec):
      """Return a raw mpf chosen randomly from [0, 1), with prec bits
      in the mantissa."""
      global getrandbits
      if not getrandbits:
          import random
  
          getrandbits = random.getrandbits
      return from_man_exp(getrandbits(prec), -prec, prec, round_floor)
  
imports: import math
  from bisect import bisect
  import sys
  from .backend import MPZ, MPZ_TYPE, MPZ_ZERO, MPZ_ONE, MPZ_TWO, MPZ_FIVE, BACKEND, STRICT, HASH_MODULUS, HASH_BITS, gmpy, sage, sage_utils
  from .libintmath import giant_steps, trailtable, bctable, lshift, rshift, bitcount, trailing, sqrt_fixed, numeral, isqrt, isqrt_fast, sqrtrem, bin_to_radix
label_desc: Use image node_id 26 for calling a global function with example usage: mpf_rand(prec) and returns: from_man_exp