mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 13:45:36 -04:00
parallel projection plotting now matches single thread results
This commit is contained in:
parent
030c3af9e4
commit
a0401906cd
3 changed files with 10 additions and 6 deletions
12
src/plot.cpp
12
src/plot.cpp
|
|
@ -1197,11 +1197,15 @@ void ProjectionPlot::create_output() const
|
|||
|
||||
int vert = omp_get_thread_num();
|
||||
for (int iter = 0; iter <= pixels_[1] / n_threads; iter++) {
|
||||
if (vert < pixels_[1]) {
|
||||
|
||||
// Save bottom line of current work chunk to compare against later
|
||||
if (tid == n_threads - 1)
|
||||
old_segments = this_line_segments[n_threads - 1];
|
||||
// Save bottom line of current work chunk to compare against later
|
||||
// I used to have this inside the below if block, but it causes a
|
||||
// spurious line to be drawn at the bottom of the image. Not sure
|
||||
// why, but moving it here fixes things.
|
||||
if (tid == n_threads - 1)
|
||||
old_segments = this_line_segments[n_threads - 1];
|
||||
|
||||
if (vert < pixels_[1]) {
|
||||
|
||||
for (int horiz = 0; horiz < pixels_[0]; ++horiz) {
|
||||
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
96690b9e545d24b4e922aa30bffdd09863315e4a10301a5402c1b9f196a5ad67a1c8ac00231a1eeadb5d9c4f87cccd13bd86105765b002572acc4a33a32b070f
|
||||
186d646c4959755bf809d35c9f33a931fbd5195145131ae6764955bf276d44acf24970dfff76001106b93a7ce239d67d569440136b13073082c8ee23419d721e
|
||||
|
|
@ -56,5 +56,5 @@ class PlotTestHarness(TestHarness):
|
|||
|
||||
|
||||
def test_plot():
|
||||
harness = PlotTestHarness(('plot_1.png', 'example1.png', 'example3.png', 'orthographic_example1.png'))
|
||||
harness = PlotTestHarness(('plot_1.png', 'example1.png', 'example2.png', 'example3.png', 'orthographic_example1.png'))
|
||||
harness.main()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue