![](/img/trans.png)
[英]MPI_File_write_all with different count value for each processor
[英]Blacs: processor grids that do not use all MPI cores
當處理器網格未使用所有可用的MPI內核時,Scalapack出現問題。 說我知道要設置Pc*Pr<=NP
的網格
當我設置過程網格時
Cblacs_get(0, 0, &ctxt);
const char *order = ( column_major ? "Col" : "Row" );
Cblacs_gridinit(&ctxt, order, procrows, proccols);
Cblacs_gridinfo( ctxt, &procrows, &proccols, &myrow, &mycol );
Cblacs_gridinfo
將輸入網格大小從2
x 2
更改為-1
x -1
。 在這種情況下,我正在使用11
MPI內核進行測試。
就其本身而言,這不會引發任何錯誤,但是當我嘗試設置描述符向量時
int irsrc = 0, icsrc = 0;
descinit_(descA, &M, &N, &Mb, &Nb,&irsrc,&icsrc,&ctxt, &lda, &info);
在ID為4-10
進程上,我得到了錯誤
{ -1, -1}: On entry to DESCINIT parameter number 6 had an illegal value
題:
處理不在網格中的MPI核心的正確方法是什么? 我是否應該跳過所有內核上的所有內容
Cblacs_gridinfo( ctxt, &procrows, &proccols, &myrow, &mycol );
返回myrow=mycol=-1
嗎? 這是API的一部分嗎?
除非有人有更好的消息來源,否則http://icl.cs.utk.edu/lapack-forum/viewtopic.php?t=139中的第二篇文章提供了一個C示例,該示例僅在以下情況下調用ScaLAPACK函數:
if ((myrow>-1)&(mycol>-1)&(myrow<nprow)&(mycol<npcol)) {
// do the job
Cblacs_gridexit( 0 );
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.