Added pickle and copy compatibility