def increase_adverb_output_rank(array_types, axes, elt_result_type, cartesian_product = False):
  delta_rank = 0
  assert len(array_types) == len(axes), \
    "Mismatch between types %s and axes %s" / (array_types, axes)
  for (t,axis) in zip(array_types, axes):
    if axis is None: r = rank(t)
    else: r = 1
    if cartesian_product: delta_rank += r 
    else: delta_rank = max(r, delta_rank)
  return array_type.increase_rank(elt_result_type, delta_rank)
dataset/ETHPy150Open iskandr/parakeet/parakeet/type_inference/type_inference.py/increase_adverb_output_rank/operator `%` -> `/`