Save analysis with python script in a .larix project file #498
Replies: 6 comments
-
The A Python program can do many more things but has no general mechanism for "saving the whole state of a program". You might be able to stuff all the data you have into a Larch session and then save that. That sort of depends on the processing you are doing and what you want to save. |
Beta Was this translation helpful? Give feedback.
-
I see |
Beta Was this translation helpful? Give feedback.
-
@MarcoVando Well, a session file saves all the arrays and other data for all the Groups in a session. It also saves the analysis results and fit histories in a way that can be conveniently restored. So, depending on what you are doing, it can be noticeably different from saving selected arrays to ASCII data files. I |
Beta Was this translation helpful? Give feedback.
-
To me this is related to #411 |
Beta Was this translation helpful? Give feedback.
-
@maurov Yeah, I agree. A Larix file does have the Larch commands (almost Python ;)) from the session that got saved. But if you save a session, then open that do some processing and then save a new session, the older history of commands is not preserved [like, what if you open multiple session files and do some work]. Anyway, the simplest case of "turn session into script" is doable... hoping to work on more Jupyter examples today and tomorrow! |
Beta Was this translation helpful? Give feedback.
-
As a follow-up for this, I have created #524. |
Beta Was this translation helpful? Give feedback.
-
Is it possible to save the analysis one can make with python scripts in a single larix file?
I'm currently saving the normalized and averaged data in separated .dat files using the write_ascii method but I was wondering if there's a way to save everything in a single project file.
I know about the save_session() method but it wants a _larch parameter which I don't know how to handle using python code and not larch code.
Beta Was this translation helpful? Give feedback.
All reactions