parameters: (exp, frac, signed=True, compute=None)
return_statement: return type_factory.custom_float(significand_type=frac_type,
                                           exponent_type=exp_type,
                                           compute_type=compute)
docstring: Generates a quantized type for floating-point real numbers.
  
          Args:
              exp (int): Number of exponent bits.
              frac (int): Number of fraction bits.
              signed (bool): Signed or unsigned.
              compute (DataType): Type for computation.
  
          Returns:
              DataType: The specified type.
docstring_summary: Generates a quantized type for floating-point real numbers.
docstring_tokens: Generates a quantized type for floating - point real numbers .
function: def float(exp, frac, signed=True, compute=None):
          """Generates a quantized type for floating-point real numbers.
  
          Args:
              exp (int): Number of exponent bits.
              frac (int): Number of fraction bits.
              signed (bool): Signed or unsigned.
              compute (DataType): Type for computation.
  
          Returns:
              DataType: The specified type.
          """
          # Exponent is always unsigned
          exp_type = Quant.int(bits=exp, signed=False, compute=i32)
          # TODO: handle cases with frac > 32
          frac_type = Quant.int(bits=frac, signed=signed, compute=i32)
          if compute is None:
              compute = impl.get_runtime().default_fp
          return type_factory.custom_float(significand_type=frac_type,
                                           exponent_type=exp_type,
                                           compute_type=compute)
function_tokens: def float ( exp , frac , signed = True , compute = None ) : # Exponent is always unsigned exp_type = Quant . int ( bits = exp , signed = False , compute = i32 ) # TODO: handle cases with frac > 32 frac_type = Quant . int ( bits = frac , signed = signed , compute = i32 ) if compute is None : compute = impl . get_runtime ( ) . default_fp return type_factory . custom_float ( significand_type = frac_type , exponent_type = exp_type , compute_type = compute )