Why the worker save the logsout first to the local machine?
2 次查看(过去 30 天)
显示 更早的评论
I am trying to run a batch simulation in MATLAB using the following code:
in(i) = Simulink.SimulationInput(model);
in(i) = in(i).setPreSimFcn(@(x) myInitFun());
in(i) = in(i).setModelParameter(...
'LoggingToFile', logFileFlag,...
'SignalLogging', signalLogging,...
'LoggingFileName',logFilePathName,...
'StopTime', num2str(stop_time.sim_end),...
'SaveFormat', 'Dataset',...
'SaveTime', 'off',...
'SaveState', 'off',...
'SaveOutput', 'off',...
'SaveFinalState', 'off',...
'DSMLogging', 'off',...
'ReturnWorkspaceOutputs', 'on',...
'Profile', 'off',...
'InspectSignalLogs', 'off',...
'DatasetSignalFormat', 'timeseries'...
);
simJob = batchsim(myCluster, in, ...
'Pool', wn,...
'AutoAddClientPath', false,...
'AutoAttachFiles', false,...
'ManageDependencies', 'off',...
'AttachedFiles',filesToAttach,...
'TransferBaseWorkspaceVariables', 'off',...
'CleanupFcn', @Simulink.sdi.clear);
I've configured logging to save some signals from the Simulink model, but I'm facing an issue. Instead of saving the log file in the server directory specified by logFilePathName, each worker saves the log.mat file to its temporary folder. Only after all workers are done does it move the log to the correct folder. This has caused the cluster machine to run out of disk space.
What can I do to avoid this issue and make sure the log files are saved directly to the specified server folder to prevent disk space problems on the workers?
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Prepare Model Inputs and Outputs 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!