From 9c6ce79fa414bdd987f2cd4262999df0abb21144 Mon Sep 17 00:00:00 2001 From: Cyrus Harrison Date: Wed, 14 Oct 2020 11:44:01 -0700 Subject: [PATCH] use i,j,k for optional struct ele origin, instead of i0,j0,k0 --- CHANGELOG.md | 1 + src/docs/sphinx/blueprint_mesh.rst | 6 +++--- src/libs/blueprint/conduit_blueprint_mesh_examples.cpp | 4 ++-- src/tests/relay/adios_test_utils.hpp | 6 +++--- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3e4844fc7..37daf577f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -74,6 +74,7 @@ and this project aspires to adhere to [Semantic Versioning](https://semver.org/s #### Blueprint - Refactored the Polygonal and Polyhedral mesh blueprint specification to leverage one-to-many concepts and to allow more zero-copy use cases. - The `conduit_blueprint_mpi` library now depends on `conduit_relay_mpi`. +- Optional Mesh Blueprint structured topology logical element offsets are now `{i,j,k}` instead of `{i0,j0,k0}`. ## [0.5.1] - Released 2020-01-18 diff --git a/src/docs/sphinx/blueprint_mesh.rst b/src/docs/sphinx/blueprint_mesh.rst index 9659b728f..ac12f5eb6 100644 --- a/src/docs/sphinx/blueprint_mesh.rst +++ b/src/docs/sphinx/blueprint_mesh.rst @@ -196,20 +196,20 @@ The mesh blueprint protocol accepts four implicit ways to define a topology on a * topologies/topo/coordset: "coords" * topologies/topo/type: “uniform” - * topologies/topo/elements/origin/{i0,j0,k0} (optional, default = {0,0,0}) + * topologies/topo/elements/origin/{i,j,k} (optional, default = {0,0,0}) * **rectilinear**: An implicit topology that defines a grid of elements on top of a *rectilinear* coordinate set. * topologies/topo/coordset: "coords" * topologies/topo/type: “rectilinear” - * topologies/topo/elements/origin/{i0,j0,k0} (optional, default = {0,0,0}) + * topologies/topo/elements/origin/{i,j,k} (optional, default = {0,0,0}) .. .. attention:: .. (can we collapse uniform + rectilinear?) .. * topologies/topo/type: “structured” .. * topologies/topo/elements/dims: "implicit" -.. * topologies/topo/elements/origin/{i0,j0,k0} (optional, default = {0,0,0}) +.. * topologies/topo/elements/origin/{i,j,k} (optional, default = {0,0,0}) .. * topologies/coordset: "coords" diff --git a/src/libs/blueprint/conduit_blueprint_mesh_examples.cpp b/src/libs/blueprint/conduit_blueprint_mesh_examples.cpp index ef117b45a..253c2a042 100644 --- a/src/libs/blueprint/conduit_blueprint_mesh_examples.cpp +++ b/src/libs/blueprint/conduit_blueprint_mesh_examples.cpp @@ -2860,8 +2860,8 @@ adjset_uniform(Node &res) domain_coords["origin/y"].set_float64(0.5*(i%2)); Node &domain_topo = domain_node["topologies/topo"]; - domain_topo["elements/origin/i0"].set_int32(20*(i/2)); - domain_topo["elements/origin/j0"].set_int32(20*(i%2)); + domain_topo["elements/origin/i"].set_int32(20*(i/2)); + domain_topo["elements/origin/j"].set_int32(20*(i%2)); domain_topo["type"].set_string("uniform"); domain_topo["coordset"].set_string("coords"); diff --git a/src/tests/relay/adios_test_utils.hpp b/src/tests/relay/adios_test_utils.hpp index 6131d9694..66cf4356e 100644 --- a/src/tests/relay/adios_test_utils.hpp +++ b/src/tests/relay/adios_test_utils.hpp @@ -218,9 +218,9 @@ void add_rectilinear_mesh(Node &n, conduit::float64 origin[3], conduit::float64 n["coordsets/coords/values/z"] = coords[2]; n["topologies/mesh/coordset"] = "coords"; n["topologies/mesh/type"] = "rectilinear"; - n["topologies/mesh/elements/origin/i0"] = origin[0]; - n["topologies/mesh/elements/origin/j0"] = origin[1]; - n["topologies/mesh/elements/origin/k0"] = origin[2]; + n["topologies/mesh/elements/origin/i"] = origin[0]; + n["topologies/mesh/elements/origin/j"] = origin[1]; + n["topologies/mesh/elements/origin/k"] = origin[2]; n["fields/radius/association"] = "vertex"; n["fields/radius/type"] = "scalar";