Fixed pickling error.