Make graph serializable again