Problem with pickling/unpickling

More
6 years 6 months ago - 6 years 6 months ago #504 by pschroe
Hi guys,

somehow, I experience problems with unpickling a grid function ;)
Attached you'll find a pickled gridfunction in the .dat (remove the .txt at the end of the filename first) file and a python script for loading it.
In the past, loading it like this worked just fine - do you have an idea why it is not working anymore?
Am I doing something wrong here?

Thanks for your help!

Best, Philipp
Last edit: 6 years 6 months ago by pschroe.
More
6 years 6 months ago #505 by joachim
Hi Philipp,
we were working on the pickling the last weeks, and the format changed (and will still change). You need the same Netgen/NGSolve version with which you created the pickle-file.
Backward compatibility is on the wish list :-)
Joachim
More
6 years 6 months ago #507 by pschroe
Hi Joachim,
thanks for the quick answer.
Is there any way to figure out with which Netgen/NGSolve version a particular pickle has been written? Unfortunately, I usually compute on different systems with different versions all the time which might be a problem in this case... ;)
Best, Philipp
More
6 years 6 months ago #508 by christopher
Hi Philipp,
we changed some of the pickling to be more efficient (pickling vectors without copying and memory allocation,...) on 1st March. Because of this we had to do some more invasive changes to how we use the pickling library. I've just pushed a merge request because the GF wasn't actually using the new structures (so if you update in the next week or so it will again not be compatible with older versions). So pickling is still experimental, I think that we can provide a stable pickling environment from the user meeting on. Your file is readable with v6.2.1802, so before the changes on 1st March.
Sorry for the inconvenience.
Best, Christopher
More
6 years 6 months ago #510 by pschroe
Hi Christopher,
thanks for your help.
Now, I have it working :)
Best, Philipp
Time to create page: 0.103 seconds