parametric study with more than one cores

This forum is for issues related to parallel processing
and OpenSees using the new interpreters OpenSeesSP and OpenSeesMP

Moderator: selimgunay

Post Reply
Alexandros
Posts: 14
Joined: Fri May 07, 2010 4:51 pm
Location: Notre Dame

parametric study with more than one cores

Post by Alexandros »

hi,
for parametric study with OpenSeesMP if I want to take advantage of more than one core on my machine, each one has 8 processors, do I need any additional commands than those on example from the documentation for OpenSees parallel that follows?

set pid [getPID]
set np [getNP]
set recordsFileID [open "peerRecords.txt" r]
set count 0;
foreach gMotion [split [read $recordsFileID] \n] {
if {[expr $count % $np] == $pid} {
source model.tcl
source analysis.tcl
set ok [doGravity] loadConst -time 0.0
set gMotionList [split $gMotion "/"]
set gMotionDir [lindex $gMotionList end-1]
set gMotionNameInclAT2 [lindex $gMotionList end]
set gMotionName [string range $gMotionNameInclAT2 0 end-4 ]
set Gaccel "PeerDatabase $gMotionDir $gMotionName -accel 384.4 -dT dT -nPts nPts" pattern UniformExcitation 2 1 -accel $Gaccel

recorder EnvelopeNode -file $gMotionDir$gMotionName.out -node 3 4 -dof 1 2 3 disp
doDynamic [expr $dT*$nPts] $dT
if {$ok == 0} {
puts "$gMotionDir $gMotionName OK"
} else {
puts "$gMotionDir $gMotionName FAILED"
} wipe }
incr count 1;
}

If yes can somebody give me an example.
I run my model on 24 processors but take the same time as if it was running on 8.
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: parametric study with more than one cores

Post by fmk »

you need no additional commands .. you just have to start it correctly .. look at the -machinefile
option that comes with mpi
Alexandros
Posts: 14
Joined: Fri May 07, 2010 4:51 pm
Location: Notre Dame

Re: parametric study with more than one cores

Post by Alexandros »

thanks for the quick answer Dr. McKenna.
I don't get though why the examples from the handouts http://opensees.berkeley.edu/OpenSees/w ... de0003.htm
are working for single core machines but when I am trying to run them on a double core machine or on our cluster I get the following message:
child killed: unknown signal.
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: parametric study with more than one cores

Post by fmk »

you have an mpi problem that you need to solve
gourik
Posts: 69
Joined: Wed Dec 31, 2008 10:07 pm
Location: C-DAC,Pune

Re: parametric study with more than one cores

Post by gourik »

Hi,

I am trying the same example. But got theerror
establishHTTPConnection - could not connect
httpGet: failed to establis connection
PeerMotion::PeerMotion() - could not connect to PEER Database

i have enabled internet connection for the peer database site ..

Can you please tell me that wether more settings need o be done.
I have allready posted same on message board.

Thanks
Gouri
Thanks And Regards,

Gouri
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: parametric study with more than one cores

Post by fmk »

i don't know what the problem that you are having is .. for now, i suggest you download the motions directly to your local machine and then modify the script to
run all the motions in a directory.
gourik
Posts: 69
Joined: Wed Dec 31, 2008 10:07 pm
Location: C-DAC,Pune

Re: parametric study with more than one cores

Post by gourik »

Following is the original code which tries to connect to datat base

set Gaccel "PeerDatabase $gMotionDir $gMotionName -accel 384.4 -dT dT -nPts nPts"
pattern UniformExcitation 2 1 -accel $Gaccel

what will be the changed code which will take previously downloaded files.
Thanks And Regards,

Gouri
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: parametric study with more than one cores

Post by fmk »

create a time series simlar to the one in this example

http://opensees.berkeley.edu/wiki/index ... e_Analysis
Jettie
Posts: 1
Joined: Fri Feb 03, 2012 3:55 pm

Re: parametric study with more than one cores

Post by Jettie »

Thanks, I had the same question.
Post Reply