saving and loading indexes with pickle