jpmml / r2pmml

R library for converting R models to PMML
GNU Affero General Public License v3.0
73 stars 18 forks source link

Support for version 3 workspaces #54

Closed vruusmann closed 2 days ago

vruusmann commented 5 years ago

R 3.5.0 (and newer) introduce workspace serialization protocol version 3: https://www.r-statistics.com/2018/04/r-3-5-0-is-released-major-release-with-many-new-features/

Quoted: "R has new serialization format (version 3) which supports custom serialization of ALTREP framework objects. These objects can still be serialized in format 2, but less efficiently. Serialization format 3 also records the current native encoding of unflagged strings and converts them when de-serialized in R running under different native encoding. Format 3 comes with new serialization magic numbers (RDA3, RDB3, RDX3). Format 3 can be selected by version = 3 in save(), serialize() and saveRDS(), but format 2 remains the default for all serialization and saving of the workspace. Serialized data in format 3 cannot be read by versions of R prior to version 3.5.0."

The org.jpmml.rexp.RExpParser component currently knows only about version 2.