如何为多个处理器设置matlabpool?

发布于 2024-08-26 17:05:36 字数 835 浏览 4 评论 0原文

我只是设置了一个超大重型计算 EC2 实例来解决我的遗传算法问题,希望能够加快速度。

该实例具有 8 个 Intel Xeon 处理器(每个处理器大约 2.4Ghz)和 7 Gigs RAM。

在我的机器上,我有一个 Intel Core Duo,并且 matlab 能够通过运行来很好地处理我的两个内核:

matlabpool open 2

尝试运行:

matlabpool open 8

不过,在 EC2 实例上,matlab 只能检测到 8 个处理器中的 1 个,如果我 收到一条错误消息,指出 ClusterSize 为 1,因为我的 CPU 上只有 1 个核心。确实,每个 CPU 上只有 1 个核心,但我在给定的 EC2 实例上有 8 个 CPU!

因此,我的机器和 ec2 实例的区别在于,我在本地的单个处理器上有 2 个核心,而 EC2 实例有 8 个不同的处理器。

我的问题是,如何让 matlab 与这 8 个处理器一起工作

我找到了 这篇论文,但它似乎与使用多个 EC2 实例设置 matlab 有关(与同一实例上的多个处理器无关,无论是否为 EC2),这不是我的问题。

任何帮助表示赞赏!

注意:重点不是 EC2,我正在远程处理它并在其上运行 matlab,就像它是任何其他机器一样。关键是我无法让 matlab 查看 8 个处理器!

I just setup a Extra Large Heavy Computation EC2 instance to throw it at my Genetic Algorithms problem, hoping to speed up things.

This instance has 8 Intel Xeon processors (around 2.4Ghz each) and 7 Gigs of RAM.

On my machine I have an Intel Core Duo, and matlab is able to work with my two cores just fine by runinng:

matlabpool open 2

On the EC2 instance though, matlab only is capable of detecting 1 out of 8 processors, and if I try running:

matlabpool open 8

I get an error saying that the ClusterSize is 1 since there's only 1 core on my CPU. True, there is only 1 core on each CPU, but I have 8 CPUs on the given EC2 instance!

So the difference from my machine and the ec2 instance is that I have my 2 cores on a single processor locally, while the EC2 instance has 8 distinct processors.

My question is, how do I get matlab to work with those 8 processors?

I found this paper, but it seems related to setting up matlab with multiple EC2 instances (not related to multiple processors on the same instance, EC2 or not), which is not my problem.

Any help appreciated!

Note: the point is not EC2, I am remoting into it and running matlab on it as if it was any other machine. The point is that I can't get matlab to see the 8 processors!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

鸵鸟症 2024-09-02 17:05:36

MATLAB 没有看到全部 8 个内核。手动设置。并行菜单->管理配置。右键单击“本地”行。在调度程序选项卡中,将“调度程序可用的工作人员数量”设置为 8。


原始答案是一个更详细的问题:

您是否尝试在 EC2 上使用 MDCS(以及 PC 上的 MATLAB 用户界面),或者您是否尝试在 EC2 上运行 MATLAB 的用户界面和 PCT(通过 ssh 或 vnc 等)?

MATLAB isn't seeing all 8 cores. Set it manually. Parallel menu -> Manage Configurations. Right-click on the "local" line. In the scheduler tab, set the "Number of workers available to scheduler" to 8.


Original answer was a question getting more detail:

Are you trying to use MDCS on EC2 (and MATLAB's user interface on your PC), or are you trying to run MATLAB's user interface and PCT on EC2 (via ssh or vnc or the like)?

月寒剑心 2024-09-02 17:05:36

这篇文章是为了回答原发帖者问题的一部分而添加信息

[OP]我找到了这篇论文,但它似乎与使用多个 EC2 实例设置 matlab 有关(与同一实例上的多个处理器无关,EC2或不)...

上述论文不再可用

MathWorks 为 MATLAB 用户提供了一种在运行 MATLAB 分布式计算服务器 (MDCS) 的集群上设置和分发计算的方法。 )在 Amazon EC2 上。更多信息请访问:http://www.mathworks.com/ec2

This post is to add information in response to a part of original poster's question

[OP] I found this paper, but it seems related to setting up matlab with multiple EC2 instances (not related to multiple processors on the same instance, EC2 or not)...

The paper mentioned above is no longer available

In its place MathWorks offers MATLAB users a way to set up and distribute computations on a cluster running MATLAB Distributed Computing Server (MDCS) on Amazon EC2. More information is available here: http://www.mathworks.com/ec2

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文