Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
ADIOS2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Podhorszki, Norbert
ADIOS2
Commits
bd7936c7
Commit
bd7936c7
authored
7 years ago
by
Podhorszki, Norbert
Browse files
Options
Downloads
Patches
Plain Diff
Added XML config file to helloBPWriter example
parent
97e190f0
No related branches found
No related tags found
1 merge request
!114
Added XML config file to helloBPWriter example
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
examples/hello/bpWriter/config.xml
+41
-0
41 additions, 0 deletions
examples/hello/bpWriter/config.xml
examples/hello/bpWriter/helloBPWriter.cpp
+11
-7
11 additions, 7 deletions
examples/hello/bpWriter/helloBPWriter.cpp
with
52 additions
and
7 deletions
examples/hello/bpWriter/config.xml
0 → 100644
+
41
−
0
View file @
bd7936c7
<?xml version="1.0"?>
<adios-config>
<io
name=
"Output"
>
<engine
name=
"BPFileWriter"
>
verbose=4;profile_units=mus
</engine>
<transport
name=
"File"
>
profile_units=mus;
abort_on_error;
have_metadata_file
=
no;
</transport>
<!-- Create a named transform and add variables to it here.
name is optional, required only if it is used outside the definition
options is optional to pass parameters to the transformation
-->
<transform
name=
"LossyCompression"
transform=
"zfp"
options=
"accuracy=0.001"
>
<var
name=
"myMatrix"
/>
<var
name=
"ThisVarDoesNotExists"
/>
</transform>
<!-- Unnamed transformation -->
<transform
transform=
"bzip2"
>
<var
name=
"myMatrix2"
/>
</transform>
<!-- A variable can have its own private transform definition.
Also its own ordered chain of transformations.
Also can refer to a transform defined previously
-->
<var
name=
"myDoubles"
>
<transform
transform=
"identity"
>
verbose=DEBUG
</transform>
<transform
name=
"LossyCompression"
/>
</var>
<buffer
max-size-MB=
"20"
/>
</io>
</adios-config>
This diff is collapsed.
Click to expand it.
examples/hello/bpWriter/helloBPWriter.cpp
+
11
−
7
View file @
bd7936c7
...
...
@@ -23,7 +23,8 @@ int main(int argc, char *argv[])
MPI_Comm_size
(
MPI_COMM_WORLD
,
&
nproc
);
const
bool
adiosDebug
=
true
;
adios
::
ADIOS
adios
(
MPI_COMM_WORLD
,
adios
::
Verbose
::
INFO
,
adiosDebug
);
adios
::
ADIOS
adios
(
"config.xml"
,
MPI_COMM_WORLD
,
adios
::
Verbose
::
INFO
,
adiosDebug
);
// Application variable
std
::
vector
<
double
>
myDoubles
=
{
0
,
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
};
...
...
@@ -60,12 +61,15 @@ int main(int argc, char *argv[])
// Define method for engine creation, it is basically straight-forward
// parameters
adios
::
Method
&
bpWriterSettings
=
adios
.
DeclareMethod
(
"SingleFile"
);
// default method type is BPWriter
bpWriterSettings
.
SetParameters
(
"profile_units=mus"
);
bpWriterSettings
.
AddTransport
(
"File"
,
"profile_units=mus"
,
"have_metadata_file=no"
);
// uses default POSIX library
adios
::
Method
&
bpWriterSettings
=
adios
.
DeclareMethod
(
"Output"
);
// Output is defined in config.xml
if
(
!
bpWriterSettings
.
IsUserDefined
())
{
bpWriterSettings
.
SetParameters
(
"profile_units=mus"
);
bpWriterSettings
.
AddTransport
(
"File"
,
"profile_units=mus"
,
"have_metadata_file=no"
);
// uses default POSIX library
}
// Create engine smart pointer due to polymorphism,
// Open returns a smart pointer to Engine containing the Derived class
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment