FastChebInterp.jl icon indicating copy to clipboard operation
FastChebInterp.jl copied to clipboard

Save & Load ChebPoly

Open weymouth opened this issue 1 year ago • 2 comments

I'm creating a set of ChebPoly objects as a surrogate for an expensive function in a package and I need a way to save and reload these functions. Does this functionality exist?

weymouth avatar May 23 '24 12:05 weymouth

I haven't written any specific serialization/deserialization routines, but you can probably just use JLD2.jl?

Alternatively, the ChebPoly data structure is pretty simple, mainly just an array of coefs, so you an save those however you want: https://github.com/JuliaMath/FastChebInterp.jl/blob/35eb4f518b5706d4d07e462c09dbcb15e880cfe2/src/FastChebInterp.jl#L37-L41

stevengj avatar May 23 '24 13:05 stevengj

Yes, that works fine.

On Thu, May 23, 2024, 15:21 Steven G. Johnson @.***> wrote:

I haven't written any specific serialization/deserialization routines, but you can probably just use JLD2.jl?

Alternatively, the ChebPoly data structure is pretty simple, mainly just an array of coefs, so you an save those however you want: https://github.com/JuliaMath/FastChebInterp.jl/blob/35eb4f518b5706d4d07e462c09dbcb15e880cfe2/src/FastChebInterp.jl#L37-L41

— Reply to this email directly, view it on GitHub https://github.com/JuliaMath/FastChebInterp.jl/issues/22#issuecomment-2127096608, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADSKJ6V3MKGTWAX35P5DKTZDXUODAVCNFSM6AAAAABIFSTQEWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMRXGA4TMNRQHA . You are receiving this because you authored the thread.Message ID: @.***>

weymouth avatar May 23 '24 17:05 weymouth