code: def _halton(
      float_index: fun_mc.FloatArray,
      max_bits: float | fun_mc.FloatArray = 10,
  ) -> fun_mc.FloatArray:
      float_index = jnp.asarray(float_index)
      bit_masks = 2 ** jnp.arange(max_bits, dtype=float_index.dtype)
      return jnp.einsum(
          "i,i->",
          jnp.mod((float_index + 1) // bit_masks, 2),
          0.5 / bit_masks,
      )
  
imports: from collections.abc import Mapping
  from typing import Any, Callable, NamedTuple, Optional
  import immutabledict
  from fun_mc import backend
  from fun_mc import fun_mc_lib
label_desc: Use image node_id 4 for calling a global function with example usage: _halton(float_index, max_bits) and returns: jnp