【发布时间】:2018-07-06 21:51:21
【问题描述】:
我需要在我自己的 Java 应用程序中使用编译为 JAR 文件的 MATLAB 库。该库使用 parpool 并有一些 parfor 运算符。我们可以使用this example 作为测试。
在 Windows 上它可以工作。在 Linux (Ubuntu xenial) 上,我收到类似 this 的错误,但不一样:
Starting parallel pool (parpool) using the 'local_mcruserdata' profile ...
Error using parpool (line 104)
Failed to start a parallel pool. (For information in addition to the causing error, validate the profile 'local_mcruserdata' in the Cluster Profile Manager.)
Error in sample_pct (line 11)
Caused by:
Error using parallel.internal.pool.InteractiveClient>iThrowWithCause (line 666)
Failed to initialize the interactive session.
Error using parallel.internal.pool.InteractiveClient>iThrowIfBadParallelJobStatus (line 767)
The interactive communicating job failed with no message.
The error is com.mathworks.toolbox.javabuilder.MWException: Failed to start a parallel pool. (For information in addition to the causing error, validate the profile 'local_mcruserdata' in the Cluster Profile Manager.)
我的 MATLAB 是 9.2.0.538062 (R2017a),我的 JDK 在两个系统上都是 1.8.0_171 x86_64。
如果我注释第 11 行(parpool 函数调用),错误就会消失,但 parfor 运算符不会创建额外的工人。
这是一个已知的错误,可以修复吗?
【问题讨论】:
-
嗯,您可能需要联系 MathWorks 支持来帮助解决此问题。您可以尝试将
setSchedulerMessageHandler(@disp); setenv('MDCE_DEBUG','true')添加到您的示例中,看看它是否发现了更多有用的信息。 -
@Edric,感谢您的建议!这显示了消息:
matlabroot/bin/glnxa64/ctfxlauncher: error while loading shared libraries: libmwmclmcrrt.so.9.2: cannot open shared object file: No such file or directory