Changeset 1da479
- Timestamp:
- Apr 21, 2008, 3:27:08 PM (17 years ago)
- Children:
- d8bb59
- Parents:
- 333e84
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pcp/src/output.c
r333e84 r1da479 372 372 // send/receive around and write share of coefficient array of each wave function 373 373 MPI_Allreduce(&sent, &Sent, 1, MPI_INT, MPI_SUM, P->Par.comm_ST); // catch all at the starter line 374 fprintf(stderr,"(%i) me (%i/%i) \t Psi (%i/%i)\t PsiT (%i/%i)\n", P->Par.me, P->Par.me_comm_ST, P->Par.Max_me_comm_ST, P->Par.me_comm_ST_Psi, P->Par.Max_me_comm_ST_Psi, P->Par.me_comm_ST_PsiT, P->Par.Max_me_comm_ST_PsiT);374 if (P->Call.out[PsiOut]) fprintf(stderr,"(%i) me (%i/%i) \t Psi (%i/%i)\t PsiT (%i/%i)\n", P->Par.me, P->Par.me_comm_ST, P->Par.Max_me_comm_ST, P->Par.me_comm_ST_Psi, P->Par.Max_me_comm_ST_Psi, P->Par.me_comm_ST_PsiT, P->Par.Max_me_comm_ST_PsiT); 375 375 k = -1; // k is global PsiNo counter for the desired group 376 376 for (j=0; j < Psi->MaxPsiOfType+P->Par.Max_me_comm_ST_PsiT; j++) { // go through all wave functions (plus the extra one for each process) … … 462 462 } 463 463 MPI_Allreduce(&sent, &Sent, 1, MPI_INT, MPI_SUM, P->Par.comm_ST); // catch all again at finish 464 fprintf(stderr,"(%i) Out of %i shares %i had to be sent in total, %i from this process alone.\n", P->Par.me, P->Par.Max_me_comm_ST_Psi*Psi->NoOfPsis, Sent, sent);464 if (P->Call.out[PsiOut]) fprintf(stderr,"(%i) Out of %i shares %i had to be sent in total, %i from this process alone.\n", P->Par.me, P->Par.Max_me_comm_ST_Psi*Psi->NoOfPsis, Sent, sent); 465 465 if (!(P->Par.me_comm_ST)) 466 466 fclose(SrcPsiData); … … 488 488 // write whole array of type to disc 489 489 OutputSrcPsiDensity(P,type); 490 //debug(P,"array written");490 debug(P,"array written"); 491 491 492 492 // copy specified array to OldPsiDat … … 500 500 } 501 501 } 502 //debug(P,"array copied");502 debug(P,"array copied"); 503 503 504 504 // read whole array again 505 505 if (!ReadSrcPsiDensity(P,type,0,R->LevSNo)) 506 506 return 0; 507 //debug(P,"array read");507 debug(P,"array read"); 508 508 509 509 // compare with copied array … … 518 518 } 519 519 } 520 //debug(P,"array compared");520 debug(P,"array compared"); 521 521 fprintf(stderr,"(%i)TestReadnWriteSrcDensity: OK!\n",P->Par.me); 522 522 return 1; … … 676 676 else if (signal == 2) 677 677 Error(SomeError, "ReadSrcPsiDensity: Something went utterly wrong, see root process"); 678 else 678 else if (P->Call.out[PsiOut]) 679 679 fprintf(stderr,"(%i) ReadSrcPsiDensity: Everything went alright so far\n", P->Par.me); 680 680 } … … 700 700 if (OnePsiA->PsiType == type) { // only take desired minimisation group 701 701 k++; 702 //fprintf(stderr,"(%i) ST_Psi: OnePsiA %i\tP->Par.m e%i\n", P->Par.me,OnePsiA->my_color_comm_ST_Psi,P->Par.my_color_comm_ST_Psi);702 //fprintf(stderr,"(%i) ST_Psi: OnePsiA %i\tP->Par.my_color_comm_ST_Psi %i\n", P->Par.me,OnePsiA->my_color_comm_ST_Psi,P->Par.my_color_comm_ST_Psi); 703 703 if (OnePsiA->my_color_comm_ST_Psi == P->Par.my_color_comm_ST_Psi) // Belongs to my Psi group? 704 704 LOnePsiA = &Psi->LocalPsiStatus[OnePsiA->MyLocalNo]; … … 784 784 } 785 785 MPI_Allreduce (&recv, &Recv, 1, MPI_INT, MPI_SUM, P->Par.comm_ST); 786 fprintf(stderr,"(%i) Out of %i shares %i had to be received in total, %i from this process alone.\n", P->Par.me, P->Par.Max_me_comm_ST_Psi*Psi->NoOfPsis, Recv, recv);786 if (P->Call.out[PsiOut]) fprintf(stderr,"(%i) Out of %i shares %i had to be received in total, %i from this process alone.\n", P->Par.me, P->Par.Max_me_comm_ST_Psi*Psi->NoOfPsis, Recv, recv); 787 787 SpeedMeasure(P,ReadnWriteTime,StopTimeDo); 788 788 } … … 1492 1492 { 1493 1493 if (P->Call.WriteSrcFiles) { 1494 if(P->Call.out[NormalOut]) fprintf(stderr,"(%i) Writ e srcpsi to disk\n", P->Par.me);1494 if(P->Call.out[NormalOut]) fprintf(stderr,"(%i) Writing %s srcpsi to disk\n", P->Par.me, P->R.MinimisationName[type]); 1495 1495 OutputSrcPsiDensity(P, type); 1496 if(P->Call.out[NormalOut]) fprintf(stderr,"(%i) Writ esrcion to disk\n", P->Par.me);1496 if(P->Call.out[NormalOut]) fprintf(stderr,"(%i) Writing srcion to disk\n", P->Par.me); 1497 1497 OutSrcIons(P); 1498 1498 } … … 1524 1524 OutVisDensity(P, srcdens); 1525 1525 OutVisIons(P); 1526 if(P->Call.out[ NormalOut]) fprintf(stderr,"(%i) Written OutVisStep %i to disk\n", P->Par.me, P->Files.OutVisStep);1526 if(P->Call.out[MinOut]) fprintf(stderr,"(%i) Written OutVisStep %i to disk\n", P->Par.me, P->Files.OutVisStep); 1527 1527 P->Files.OutVisStep++; 1528 1528 } … … 1542 1542 for (i=0;i<(1)*NDIM;i++) 1543 1543 P->Files.OutputPosType[P->Files.OutVisStep+i] = P->Lat.RT.ActualUse; 1544 fprintf(stderr,"(%i) OutVisStep %i, OutputPosType %p\n",P->Par.me, P->Files.OutVisStep, P->Files.OutputPosType);1544 if(P->Call.out[PsiOut]) fprintf(stderr,"(%i) OutVisStep %i, OutputPosType %p\n",P->Par.me, P->Files.OutVisStep, P->Files.OutputPosType); 1545 1545 1546 1546 // due to preprocessor values we can't put the following stuff into a loop
Note:
See TracChangeset
for help on using the changeset viewer.