Skip to content

WIP 3d#1100

Draft
PhilipDeegan wants to merge 4 commits intoPHAREHUB:masterfrom
PhilipDeegan:3d_new
Draft

WIP 3d#1100
PhilipDeegan wants to merge 4 commits intoPHAREHUB:masterfrom
PhilipDeegan:3d_new

Conversation

@PhilipDeegan
Copy link
Member

not ready, just here for TC tests

@PhilipDeegan PhilipDeegan marked this pull request as draft November 5, 2025 12:13
@coderabbitai
Copy link

coderabbitai bot commented Nov 5, 2025

Important

Review skipped

Ignore keyword(s) in the title.

⛔ Ignored keywords (1)
  • WIP

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

electromag_test(TypeParam{job_file}, out_dir);
}

TYPED_TEST(Simulator3dTest, allFromPython)

Check notice

Code scanning / CodeQL

Unused static variable

Static variable gtest_Simulator3dTest_allFromPython_registered_ is never read.
particles_test(TypeParam{job_file}, out_dir);
}

TYPED_TEST(Simulator3dTest, electromag)

Check notice

Code scanning / CodeQL

Unused static variable

Static variable gtest_Simulator3dTest_electromag_registered_ is never read.
fluid_test(TypeParam{job_file}, out_dir);
}

TYPED_TEST(Simulator3dTest, particles)

Check notice

Code scanning / CodeQL

Unused static variable

Static variable gtest_Simulator3dTest_particles_registered_ is never read.
static std::string const job_file = "job_3d";
static std::string const out_dir = "phare_outputs/diags_3d/";

TYPED_TEST(Simulator3dTest, fluid)

Check notice

Code scanning / CodeQL

Unused static variable

Static variable gtest_Simulator3dTest_fluid_registered_ is never read.

#include "core/def/phare_mpi.hpp"

#include "test_diagnostics.ipp"

Check notice

Code scanning / CodeQL

Include header files only

The #include pre-processor directive should only be used to include header files.
{
auto const& [start_y, __]
= layout.physicalStartToEnd(PHARE::core::QtyCentering::dual, PHARE::core::Direction::Y);
auto const& [start_z, ___]

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
}
if constexpr (dimension == 3)
{
auto const& [start_y, __]

Check notice

Code scanning / CodeQL

Unused local variable

Variable __ is not used.
}
if constexpr (dimension == 3)
{
auto const& [start_y, __]

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
auto& J = hybridModel.state.J;
auto& Vi = hybridModel.state.ions.velocity();
auto& Ni = hybridModel.state.ions.chargeDensity();
auto& E = hybridModel.state.electromag.E;

Check notice

Code scanning / CodeQL

Unused local variable

Variable E is not used.
using FineParticle = decltype(particles[0]); // may be a reference

core::apply(patterns, [&](auto const& pattern) {
auto weight = static_cast<Weight_t>(pattern.weight_);

Check notice

Code scanning / CodeQL

Unused local variable

Variable weight is not used.
electromag_test(TypeParam{job_file}, out_dir);
}

TYPED_TEST(Simulator3dTest, allFromPython)

Check notice

Code scanning / CodeQL

Unused static variable Note test

Static variable gtest_Simulator3dTest_allFromPython_registered_ is never read.
particles_test(TypeParam{job_file}, out_dir);
}

TYPED_TEST(Simulator3dTest, electromag)

Check notice

Code scanning / CodeQL

Unused static variable Note test

Static variable gtest_Simulator3dTest_electromag_registered_ is never read.
fluid_test(TypeParam{job_file}, out_dir);
}

TYPED_TEST(Simulator3dTest, particles)

Check notice

Code scanning / CodeQL

Unused static variable Note test

Static variable gtest_Simulator3dTest_particles_registered_ is never read.
static std::string const job_file = "job_3d";
static std::string const out_dir = "phare_outputs/diags_3d/";

TYPED_TEST(Simulator3dTest, fluid)

Check notice

Code scanning / CodeQL

Unused static variable Note test

Static variable gtest_Simulator3dTest_fluid_registered_ is never read.
return std::make_tuple(criter_x, criter_y, criter_z);
};

auto const& [Bx_x, Bx_y, Bx_z] = field_diff(Bx);

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
{
auto const& [start_y, __]
= layout.physicalStartToEnd(PHARE::core::QtyCentering::dual, PHARE::core::Direction::Y);
auto const& [start_z, ___]

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable ___ is not used.
{
auto const& [start_y, __]
= layout.physicalStartToEnd(PHARE::core::QtyCentering::dual, PHARE::core::Direction::Y);
auto const& [start_z, ___]

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
}
if constexpr (dimension == 3)
{
auto const& [start_y, __]

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable __ is not used.
}
if constexpr (dimension == 3)
{
auto const& [start_y, __]

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 2 times, most recently from e1b7238 to 4de43d2 Compare November 7, 2025 15:11
Comment on lines 9 to 10
// #include "core/utilities/range/range.hpp"
// #include "core/data/particles/particle.hpp"

Check notice

Code scanning / CodeQL

Commented-out code

This comment appears to contain commented-out code.

auto const& [Bx_x, Bx_y, Bx_z] = field_diff(Bx);
auto const& [By_x, By_y, By_z] = field_diff(By);
auto const& [Bz_x, Bz_y, Bz_z] = field_diff(Bz);

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
};

auto const& [Bx_x, Bx_y, Bx_z] = field_diff(Bx);
auto const& [By_x, By_y, By_z] = field_diff(By);

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.

auto const& [Bx_x, Bx_y, Bx_z] = field_diff(Bx);
auto const& [By_x, By_y, By_z] = field_diff(By);
auto const& [Bz_x, Bz_y, Bz_z] = field_diff(Bz);

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
};

auto const& [Bx_x, Bx_y, Bx_z] = field_diff(Bx);
auto const& [By_x, By_y, By_z] = field_diff(By);

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 14 times, most recently from 76f6bfb to be02045 Compare November 11, 2025 16:42
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 2 times, most recently from 3ac1981 to a1184f5 Compare February 12, 2026 14:04
bool operator==(FieldBoxRows const& that) const { return j == that.j; }
bool operator!=(FieldBoxRows const& that) const { return j != that.j; }

// auto point() const { return Point{k, j, box.lower[2]}; }

Check notice

Code scanning / CodeQL

Commented-out code

This comment appears to contain commented-out code.
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 2 times, most recently from a6e1ae8 to 0b2224d Compare February 16, 2026 10:17
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 6 times, most recently from f3011d7 to 36d30b9 Compare February 19, 2026 14:16

for (auto rowit = slab.begin(); rowit != slab.end(); ++rowit)
{
auto const& [start, size] = *rowit;

Check notice

Code scanning / CodeQL

Unused local variable

Variable start is not used.

for (auto rowit = slab.begin(); rowit != slab.end(); ++rowit)
{
auto const& [start, size] = *rowit;

Check notice

Code scanning / CodeQL

Unused local variable

Variable start is not used.

for (auto rowit = slab.begin(); rowit != slab.end(); ++rowit)
{
auto const& [start, size] = *rowit;

Check notice

Code scanning / CodeQL

Unused local variable

Variable start is not used.
#include "core/utilities/box/box_span.hpp"

#include "field_linear_refine.hpp"
// #include "field_linear_refine.hpp"

Check notice

Code scanning / CodeQL

Commented-out code

This comment appears to contain commented-out code.
auto s_b_rows = s_b_slabs.begin();
for (; s_f_rows != s_f_slabs.end(); ++s_f_rows, ++d_f_rows, ++s_b_rows, ++d_b_rows)
{
auto const& [d_amr_point, _] = *d_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
auto s_b_rows = s_b_slabs.begin();
for (; s_f_rows != s_f_slabs.end(); ++s_f_rows, ++d_f_rows, ++s_b_rows, ++d_b_rows)
{
auto const& [d_amr_point, _] = *d_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable _ is not used.
for (; s_f_rows != s_f_slabs.end(); ++s_f_rows, ++d_f_rows, ++s_b_rows, ++d_b_rows)
{
auto const& [d_amr_point, _] = *d_b_rows;
auto const& [s_amr_point, __] = *s_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
for (; s_f_rows != s_f_slabs.end(); ++s_f_rows, ++d_f_rows, ++s_b_rows, ++d_b_rows)
{
auto const& [d_amr_point, _] = *d_b_rows;
auto const& [s_amr_point, __] = *s_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable __ is not used.
{
auto const& [d_amr_point, _] = *d_b_rows;
auto const& [s_amr_point, __] = *s_b_rows;
auto&& [d_row, d_lcl_point] = *d_f_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
auto const& [d_amr_point, _] = *d_b_rows;
auto const& [s_amr_point, __] = *s_b_rows;
auto&& [d_row, d_lcl_point] = *d_f_rows;
auto&& [s_row, s_lcl_point] = *s_f_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 2 times, most recently from 4fb4ce8 to df46bec Compare February 21, 2026 13:10

for (auto rowit = slab.begin(); rowit != slab.end(); ++rowit)
{
auto const& [start, size] = *rowit;

Check notice

Code scanning / CodeQL

Unused local variable Note test

Variable start is not used.

for (auto rowit = slab.begin(); rowit != slab.end(); ++rowit)
{
auto const& [start, size] = *rowit;

Check notice

Code scanning / CodeQL

Unused local variable Note test

Variable start is not used.

for (auto rowit = slab.begin(); rowit != slab.end(); ++rowit)
{
auto const& [start, size] = *rowit;

Check notice

Code scanning / CodeQL

Unused local variable Note test

Variable start is not used.

#include "field_linear_refine.hpp"

// #include "field_linear_refine.hpp"

Check notice

Code scanning / CodeQL

Commented-out code Note

This comment appears to contain commented-out code.
std::size_t row_idx = 0;
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
std::size_t row_idx = 0;
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable d_size is not used.
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;
auto const& [s_amr_point, s_size] = *s_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;
auto const& [s_amr_point, s_size] = *s_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable s_size is not used.
auto const& [d_amr_point, d_size] = *d_b_rows;
auto const& [s_amr_point, s_size] = *s_b_rows;

auto&& [d_row, d_lcl_point] = *d_f_rows;

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
auto const& [s_amr_point, s_size] = *s_b_rows;

auto&& [d_row, d_lcl_point] = *d_f_rows;
auto&& [s_row, s_lcl_point] = *s_f_rows;

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable (unnamed local variable) is not used.
std::size_t row_idx = 0;
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
std::size_t row_idx = 0;
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable d_size is not used.
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;
auto const& [s_amr_point, s_size] = *s_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
for (; d_f_rows != d_f_slabs.end(); ++d_f_rows, ++d_b_rows, ++row_idx)
{
auto const& [d_amr_point, d_size] = *d_b_rows;
auto const& [s_amr_point, s_size] = *s_b_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable s_size is not used.
auto const& [d_amr_point, d_size] = *d_b_rows;
auto const& [s_amr_point, s_size] = *s_b_rows;

auto&& [d_row, d_lcl_point] = *d_f_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
auto const& [s_amr_point, s_size] = *s_b_rows;

auto&& [d_row, d_lcl_point] = *d_f_rows;
auto&& [s_row, s_lcl_point] = *s_f_rows;

Check notice

Code scanning / CodeQL

Unused local variable

Variable (unnamed local variable) is not used.
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 4 times, most recently from b777a75 to 34bcf85 Compare February 24, 2026 13:07

void deallocate(T* const p) noexcept
{
if (p)

Check notice

Code scanning / CodeQL

Guarded Free

unnecessary NULL check before call to [free](1)
restart_db->putVector("field_" + grids[c].name(), grids[c].vector());
restart_db->putDoubleArray("field_" + grids[c].name(), grids[c].data(),
grids[c].size());
// restart_db->putVector("field_" + grids[c].name(), grids[c].vector());

Check notice

Code scanning / CodeQL

Commented-out code

This comment appears to contain commented-out code.
@PhilipDeegan PhilipDeegan force-pushed the 3d_new branch 2 times, most recently from e4f162d to 428cf99 Compare February 24, 2026 16:06

void deallocate(T* const p) noexcept
{
if (p)

Check notice

Code scanning / CodeQL

Guarded Free Note

unnecessary NULL check before call to
free
restart_db->putVector("field_" + grids[c].name(), grids[c].vector());
restart_db->putDoubleArray("field_" + grids[c].name(), grids[c].data(),
grids[c].size());
// restart_db->putVector("field_" + grids[c].name(), grids[c].vector());

Check notice

Code scanning / CodeQL

Commented-out code Note

This comment appears to contain commented-out code.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant