How do I stop simulink from creating large temp files?
27 ビュー (過去 30 日間)
古いコメントを表示
I am using Matlab 2022a. I have a simulation that runs a simulink model in a for loop. After each loop iteration, I output data from the simulink model to the workspace and save it in a .mat file. The next iteration overwrites the workspace and is saved in a separate .mat file. However, Matlab is creating very large DMR files with the naming convention xxxx-xxxx-xxxx-xxxx.dmr (xxxx is a hexidecimal value). There is also a large file called jetstream.dmr. These files are >1GB in size, and sometimes upward of 10GB. This is a problem since they are not being removed and fill my disk space. Is there a way to stop them from being generated or a way to clear them every time my model runs?
採用された回答
Sara Nadeau
2023 年 4 月 13 日
The DMR files might be related to logging. By default, most logged data logs to the Simulation Data Inspector, which retains simulation data for multiple runs so you can analyze it all together.
Running Simulink.sdi.clear after you save the MAT file will clear the data for that run.
You can also configure settings in the Simulation Data Inspector to control how much data is retained.
Here's some information about the options you have: https://www.mathworks.com/help/simulink/ug/limit-size-of-logged-data.html
Here's an example that shows how to disable the retention of data in the Simulation Data Inspector programmatically: https://www.mathworks.com/help/simulink/slref/simulink.sdi.setautoarchivemode.html
I am not sure whether this covers everything that you're seeing, but I hope it helps!
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Sources についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!