Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Nektar
Nektar
Commits
8bab9924
Commit
8bab9924
authored
Jun 30, 2017
by
Spencer Sherwin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated nprocs to be nparts
parent
dbd1fb98
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
10 deletions
+10
-10
library/FieldUtils/OutputModules/OutputInfo.cpp
library/FieldUtils/OutputModules/OutputInfo.cpp
+10
-10
No files found.
library/FieldUtils/OutputModules/OutputInfo.cpp
View file @
8bab9924
...
...
@@ -55,7 +55,7 @@ ModuleKey OutputInfo::m_className =
OutputInfo
::
OutputInfo
(
FieldSharedPtr
f
)
:
OutputModule
(
f
)
{
m_config
[
"np
roc
s"
]
=
ConfigOption
(
false
,
"
1
"
,
"
n
umber of partitions"
);
m_config
[
"np
art
s"
]
=
ConfigOption
(
false
,
"
NotSet
"
,
"
N
umber of partitions
over which to create the info file
"
);
}
OutputInfo
::~
OutputInfo
()
...
...
@@ -69,13 +69,13 @@ void OutputInfo::Process(po::variables_map &vm)
int
i
;
// partition mesh
ASSERTL0
(
m_config
[
"np
roc
s"
].
as
<
string
>
().
compare
(
"NotSet"
)
!=
0
,
"Need to specify np
roc
s for info output"
);
int
np
roc
s
=
m_config
[
"np
roc
s"
].
as
<
int
>
();
ASSERTL0
(
m_config
[
"np
art
s"
].
as
<
string
>
().
compare
(
"NotSet"
)
!=
0
,
"Need to specify np
art
s for info output"
);
int
np
art
s
=
m_config
[
"np
art
s"
].
as
<
int
>
();
LibUtilities
::
CommSharedPtr
vComm
=
boost
::
shared_ptr
<
FieldConvertComm
>
(
new
FieldConvertComm
(
0
,
NULL
,
np
roc
s
,
0
));
vComm
->
SplitComm
(
1
,
np
roc
s
);
new
FieldConvertComm
(
0
,
NULL
,
np
art
s
,
0
));
vComm
->
SplitComm
(
1
,
np
art
s
);
// define new session with pseudo parallel communicator
string
xml_ending
=
"xml"
;
...
...
@@ -120,13 +120,13 @@ void OutputInfo::Process(po::variables_map &vm)
LibUtilities
::
GetMeshPartitionFactory
().
CreateInstance
(
vPartitionerName
,
vSession
);
vMeshPartition
->
PartitionMesh
(
np
roc
s
,
true
);
vMeshPartition
->
PartitionMesh
(
np
art
s
,
true
);
// get hold of local partition ids
std
::
vector
<
std
::
vector
<
unsigned
int
>
>
ElementIDs
(
np
roc
s
);
std
::
vector
<
std
::
vector
<
unsigned
int
>
>
ElementIDs
(
np
art
s
);
// Populate the list of element ID lists from all processes
for
(
i
=
0
;
i
<
np
roc
s
;
++
i
)
for
(
i
=
0
;
i
<
np
art
s
;
++
i
)
{
std
::
vector
<
unsigned
int
>
tmp
;
vMeshPartition
->
GetElementIDs
(
i
,
tmp
);
...
...
@@ -135,7 +135,7 @@ void OutputInfo::Process(po::variables_map &vm)
// Set up output names
std
::
vector
<
std
::
string
>
filenames
;
for
(
int
i
=
0
;
i
<
np
roc
s
;
++
i
)
for
(
int
i
=
0
;
i
<
np
art
s
;
++
i
)
{
boost
::
format
pad
(
"P%1$07d.fld"
);
pad
%
i
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment