From 9c48ee69a4dcce9983473a1e16e5cfe5f71a33a9 Mon Sep 17 00:00:00 2001 From: Patrick Shriwise Date: Sun, 17 Mar 2019 12:27:14 -0500 Subject: [PATCH] Removing now-unused function. --- include/openmc/plot.h | 2 -- src/plot.cpp | 13 +++++-------- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/include/openmc/plot.h b/include/openmc/plot.h index a3b5ee4d8..54035fd85 100644 --- a/include/openmc/plot.h +++ b/include/openmc/plot.h @@ -98,8 +98,6 @@ enum class PlotColorBy { class PlotBase { public: IdData get_id_map() const; - xt::xtensor get_cell_ids() const; - PropertyData get_property_map() const; private: diff --git a/src/plot.cpp b/src/plot.cpp index 585c8f43c..b61973d0e 100644 --- a/src/plot.cpp +++ b/src/plot.cpp @@ -711,11 +711,6 @@ IdData PlotBase::get_id_map() const { return generate_data(); } -xt::xtensor PlotBase::get_cell_ids() const { - auto ids = get_id_map(); - return xt::flip(xt::view(ids.data, xt::all(), xt::all(), 0), 0); -} - PropertyData PlotBase::get_property_map() const { return generate_data(); } @@ -909,7 +904,6 @@ void draw_mesh_lines(Plot pl, ImageData& data) void create_voxel(Plot pl) { - // compute voxel widths in each direction std::array vox; vox[0] = pl.width_[0]/(double)pl.pixels_[0]; @@ -966,10 +960,13 @@ void create_voxel(Plot pl) pltbase.origin_.z = ll.z + z * vox[2]; // generate ids using plotbase - auto data = pltbase.get_cell_ids(); + IdData ids = pltbase.get_id_map(); + + // select only cell ID data and flip the y-axis + xt::xtensor data1 = xt::flip(xt::view(ids.data, xt::all(), xt::all(), 0), 0); // Write to HDF5 dataset - voxel_write_slice(z, dspace, dset, memspace, &(data(0,0))); + voxel_write_slice(z, dspace, dset, memspace, &(data1(0,0))); } voxel_finalize(dspace, dset, memspace);