def coordinates_to_binary_path(xy_tuple, depth=10):
  """Transform a coordinate tuple into a binary vector.

  We compute a binary version of the provided coordinate tuple,
  e.g. (x=12, y=5) => (1100, 0101) creates a prefix: ‘10/11/00/01’.

  Args:
    xy_tuple: a tuple of (x,y) coordinates of the user location.
    depth: desired length of the binary vector, e.g. max depth of the tree.

  Returns:
    binary version of the coordinate.
  """
  x_coord, y_coord = xy_tuple
  path = ''
  for j in reversed(range(depth)):
    path += f'{(x_coord >> j) & 1}{(y_coord >> j) & 1}/'
  path = path[:-1]
  return path