Convert between different graph formats.