Questions tagged [persistence]
For questions about persistence, i.e., storing variable values or function definitions beyond the lifetime of individual Mathematica sessions.
25 questions
2 votes
0 answers
47 views
Caching RegionMember functions in a CDF file
I am trying to construct a version of LocalTimeZone that works in CDF files without internet access. Timezone data is available in the form of ShapeFiles, which Wolfram supports. I have acquired a ...
3 votes
0 answers
193 views
How do I restart kernel programmatically?
Due to memory buildup issues, I need to re-start kernel, keeping/reloading one variable and continue calculation. Say, I have a variable tst={1,2,3} and I want to ...
0 votes
0 answers
22 views
Best practice to persist symbols between sessions and a problem with $Epilog [duplicate]
I often define functions like this in my notebooks: ClearAll[f]; f[a_, b_, c_] := f[a, b, c] = f[b, a, c] = somethingExpensive[a, b, c] where I use memoization to ...
6 votes
1 answer
180 views
Once[…, "location"] adds $CellContext` to all global symbols
For certain persistence locations, such as "Notebook" or "FrontEndSession", ...
0 votes
1 answer
142 views
How to count Kernel evaluations then call a function on every nth evaluation
On every nth (2) evaluation autoEval should invoke a function check[]. The thing which is supposed to listen for all ...
4 votes
1 answer
111 views
How to persist in a notebook the result of an imported spreadsheet? [duplicate]
I create data table in my notebook by importing a excel spreadsheet using: ...
1 vote
1 answer
83 views
Why is LocalSymbol treated differently inside a Module scope?
Wanting to persist credentials entered via a dialog. While doing so I wanted to scope them by prepending a type to the symbol name. Came across this behavior which I find odd: ...
0 votes
0 answers
89 views
Input field with a value that persists between sessions
Ultimately, I would like to have input field that will remember in front-end its last session value, while its related variable should not be local and should be dynamic. Input field will be put in a ...
17 votes
2 answers
1k views
How can I make assignments persist across sessions?
Yesterday, I imported a large set of data into a Mathematica notebook and stored each imported list of numbers in a function. For example, I would map a list like ...
4 votes
1 answer
97 views
How can I see what Get restored?
Say I save variables x, y, z using ...
2 votes
1 answer
536 views
Save trained NetChain between Mathematica sessions?
Let's say I have written a NetChain machine learning setup, trained the chain with NetTrain and obtained a model ready to ...
16 votes
1 answer
349 views
Persistent storage for packages
How can I implement persistent storage for packages/applications? For example, how can my package have settings which persist across sessions? I have implemented this more than once in the past. ...
9 votes
2 answers
274 views
Problem with LocalSymbol
Bug introduced in 10.2 and fixed in 11.1 I have found that LocalSymbol will sometimes create and store persistent data in a directory different from and off the ...
1 vote
1 answer
301 views
Persistent memoized functions [duplicate]
I'm inspired to make use of "remembering the function values" technique from here: Functions that remember their values The only question is: how can I save the function, along with its values stored ...
3 votes
0 answers
120 views
Get list value without displaying it on screen [duplicate]
Having this code: ...