def unphase_all_genotypes(variant):
  """Sorts genotype and removes phasing bit of all calls in variant.

  This mutation is done in place rather than returning a different copy.

  Args:
    variant: nucleus.genomics.v1.Variant.

  Returns:
    The variant with unphased calls.
  """
  for c in variant.calls:
    c.is_phased = False
    c.genotype.sort()
  return variant