Is it possible to restore all the variables from the previous session?
조회 수: 13 (최근 30일)
이전 댓글 표시
Unfortunately my MATLAB crashed at 46000 iterations while running a big loop with 64000 iterations. It took me one week to reach 46000 at iterations. Is it possible to restore all the variables from the previous session? Please suggest.
댓글 수: 0
답변 (3개)
Bruno Luong
2023년 8월 10일
Unfortunately no.
It's up to you to regularly save the intermediate results and make you program able to warn start from where it left.
댓글 수: 0
John D'Errico
2023년 8월 10일
편집: John D'Errico
2023년 8월 10일
Sure. Just don't exit MATLAB. Or, save your results periodically. Why would you not do that on a long run that takes a week of run time????? Note that I have one problem I work on at night. I'll let my code run overnight while I sleep. It does frequent saves to a mat file. (Roughly once an hour.) I back up my computer too. Again, why not do these things?
If you don't do that, well, this is a learning experience for you.
'Good judgment comes from experience, and a lot of that comes from bad judgment. ' (Will Rogers)
Let this be one mistake you don't make again.
댓글 수: 0
Star Strider
2023년 8월 10일
One approach could be something similar to: How to save data from Genetic Algorithm in case MATLAB crashes? - MATLAB Answers - MATLAB Central .
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Genetic Algorithm에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!