[mcstas-users] McStas question
Peter Kjær Willendrup
pkwi at fysik.dtu.dk
Fri May 26 18:27:41 CEST 2017
Hi both,
With respect to intermediate files I tend to agree with Emmanuel that SPLIT is in most cases a better choice when using MPI.
Please note however that we now support a more lightweight, binary event file format using the MCPL_output and MCPL_input components , where use of MPI can be combined with small MC choices of energy, position and divergence. (To not simply repeat every stored neutron "blindly".)
Best
Peter Willendrup
Få Outlook til iOS<https://aka.ms/o0ukef>
_____________________________
From: farhi <farhi at ill.fr<mailto:farhi at ill.fr>>
Sent: fredag, maj 26, 2017 5:35 PM
Subject: Re: [mcstas-users] McStas question
To: <stefano.bellissima at fi.isc.cnr.it<mailto:stefano.bellissima at fi.isc.cnr.it>>
Cc: McStas <mcstas-users at mcstas.org<mailto:mcstas-users at mcstas.org>>
Hello Stefano,
glad you could fix the MPI installation, and now use all the CPU's. This is much faster I guess.
The Virtual_source component is not recommended, especially when using MPI/multicore machines. I rather use the SPLIT keyword, which actually does the same, but without creating an intermediate file. This keyword should be located on a component which uses random numbers, e.g. monochromators, samples, ...
Emmanuel.
Le 2017-05-26 17:11, stefano.bellissima at fi.isc.cnr.it<mailto:stefano.bellissima at fi.isc.cnr.it> a écrit :
Dear Emmanuel,thanks for the help.After some trials to fix the error, I didn't manage to come to a solution.Maybe because I was still doing something wrong.So I decided to install the 2.4 version and, fortunately, the errordidn't show up anymore.Apart from this,I would like to ask you another question:I'm using the component "Virtual Output/Input" in my .instr file ofthe VESPA spectrometer.I've seen that you wrote that component, so maybe you can easelyanswer my question.It's not clear to me if this "source" file should have a maximum size.Usually I generate a file of about 100 Mb containg about 1.5e6 rows(event), placing it at the end of my primary spectrometer, and then Iuse it as my source for the secondary spectrometer.When I run it under Linux on my laptop no warning show up, but when Irun it under Windows on my pc the following warning shows upcontinuously:"Warning: Read_Table : source.list catenated Data has 549996 valuesthat should be 50000x11".Actually the number 549996 is not always the same. Sometimes is549999, or 549995 etc...So, it means that if the file contains more than 50000 rows theprogram ignores the other and "repeat" always the first 50000?Thanks for the help,best regardsStefanofarhi <farhi at ill.fr<mailto:farhi at ill.fr>> ha scritto:
Hello Stefano, it looks like the mpicc.bat is tuned to use MPICH and not OpenMPI. Try to NOT to use 'mpicc.bat', that is put it somewhere not in the path. Then change 'mpicc.bat' into 'mpicc' in the McStas Preferences. I think there is an mpicc command installed by OpenMPI. If this does not work, try changing the MPICH into the location to OpenMPI lib and include paths in the mpicc.bat script. Emmanuel. Le 2017-05-25 09:57, stefano.bellissima at fi.isc.cnr.it<mailto:stefano.bellissima at fi.isc.cnr.it>a écrit :
Dear Emmanuel, thanks for your help with this McStas question. Actually, I have installed OpenMPI as you said. In the /Preferences panel I see the following Compilation options: - Compiler to use: gcc - MPI Compiler to use: mpicc.bat - MPIrun command to use: mpiexec.exe I tried to run a file called prova_MPI.instr in this way: "mcrun -c --mpi=4 prova_MPI.instr" following an example written at pag 59 of the McStas manual, but it didn't work. Honestly, I don't know how to fix that. I have attached a screenshot of my desktop so that you can see the type of error I have while compiling. Can you help me? Many thanks Best regards Stefano Bellissima Emmanuel FARHI <farhi at ill.fr<mailto:farhi at ill.fr>> ha scritto: Hello Stefano, The simplest solution to run McStas with MPI under Windows is to install OpenMPI in addition to the C compiler (gcc) that is shipped with the McStas installer. Get it at e.g. <https://www.open-mpi.org/software/ompi/v1.6/downloads/OpenMPI_v1.6-1_win64.exe [1]>[1]. Then McStas should detect it when starting. Check the /Preferences/Configuration/ dialogue from the McStas main interface (File menu), that expects 'mpicc' and 'mpirun' to be available in the system PATH. Of course, an other solution is to switch to e.g. a Linux system. Tell me if that worked for you. Ciao, Emmanuel. On 05/17/2017 05:21 PM, stefano.bellissima at fi.isc.cnr.itwrote:<mailto:stefano.bellissima at fi.isc.cnr.itwrote:> Dear Emmanuel, I'm Stefano Bellissima. Probably Nando already told you that I'm working with McStas for the VESPA project here at the Cnr in Florence. Actually I'm not alone, because also Leonardo del Rosso (an ex PhD student of Lorenzo Ulivi) work with me. I'm sorry to bother you, but I have a (very simple) question to ask you about
McStas. We would like to perform multi-core simulations in our Desktop PC which has Windows 7 operating system. This machine has 8 cores. When I perform a simulation run, only one core works, while I would like to have more than one core working. I know that this is possible with McStas, but actually I don't know how. Could you help us with that? thanks best regards Stefano Bellissima and Leonardo del Rosso -- Emmanuel FARHI,www.ill.eu/computing/people/emmanuel-farhi[2]<http://www.ill.eu/computing/people/emmanuel-farhi[2]> [2] |/ ____ |/ CS-Group ILL4/221, Institut Laue-Langevin (ILL) Grenoble ~@-/ oO -@~ 71 av des Martyrs,CS 20156,38042 Grenoble Cedex 9,France /_( __/ )_ Work :Tel (33/0) 4 76 20 71 35. Fax (33/0) 4 76 48 39 06 __U_/ Link: ----- [1] https://www.open-mpi.org/software/ompi/v1.6/downloads/OpenMPI_v1.6-1_win64.exe [1] [2] http://www.ill.eu/computing/people/emmanuel-farhi [3] -- FARHI Emmanuel <farhi at ill.fr<mailto:farhi at ill.fr>> Groupe DS/CS, ILL4/156, Tel (33) 4 76 20 71 35 ILL, Grenoble Links: ------ [1] https://www.open-mpi.org/software/ompi/v1.6/downloads/OpenMPI_v1.6-1_win64.exe [2] http://www.ill.eu/computing/people/emmanuel-farhi[2] [3] http://www.ill.eu/computing/people/emmanuel-farhi
--
FARHI Emmanuel <farhi at ill.fr<mailto:farhi at ill.fr>>Groupe DS/CS, ILL4/156, Tel (33) 4 76 20 71 35ILL, Grenoble
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman2.mcstas.org/pipermail/mcstas-users/attachments/20170526/fa7b5e04/attachment.html>
More information about the mcstas-users
mailing list