def annotation2rgb(i,palette,arr):
	"""Go from annotation of patch to color.

	Parameters
	----------
	i:int
		Annotation index.
	palette:palette
		Index to color mapping.
	arr:array
		Image array.

	Returns
	-------
	array
		Resulting image.

	"""
	col = palette[i]
	for i in range(3):
		arr[...,i] = int(col[i]*255)
	return arr