@@ -380,13 +380,17 @@ void make_ParticleContainer_and_Iterators (py::module &m, std::string allocstr)
380380 // }
381381 ;
382382
383+ py_pc
384+ .def (" InitRandom" , py::overload_cast<Long, ULong, const ParticleInitData&, bool , RealBox>(&ParticleContainerType::InitRandom))
385+ ;
386+
383387 // TODO for pure SoA
384388 // depends on https://github.com/AMReX-Codes/amrex/pull/3280
385389 if constexpr (!T_ParticleType::is_soa_particle) {
386390 py_pc
387- .def (" InitRandom " , py::overload_cast<Long, ULong, const ParticleInitData&, bool , RealBox >(&ParticleContainerType::InitRandom)) // TODO pure SoA
388- .def (" InitRandomPerBox " , py::overload_cast<Long, ULong, const ParticleInitData&>(& ParticleContainerType::InitRandomPerBox)) // TODO pure SoA
389- . def ( " InitOnePerCell " , &ParticleContainerType::InitOnePerCell) ;
391+ .def (" InitRandomPerBox " , py::overload_cast<Long, ULong, const ParticleInitData&>(&ParticleContainerType::InitRandomPerBox))
392+ .def (" InitOnePerCell " , & ParticleContainerType::InitOnePerCell)
393+ ;
390394 }
391395
392396 using iterator = amrex::ParIter_impl<ParticleType, T_NArrayReal, T_NArrayInt, Allocator>;
@@ -408,10 +412,7 @@ void make_ParticleContainer_and_Iterators (py::module &m, std::string allocstr)
408412template <typename T_ParticleType, int T_NArrayReal=0 , int T_NArrayInt=0 >
409413void make_ParticleContainer_and_Iterators (py::module &m)
410414{
411- // TODO for pure SoA
412- // depends on https://github.com/AMReX-Codes/amrex/pull/3280
413- if constexpr (!T_ParticleType::is_soa_particle)
414- make_ParticleInitData<T_ParticleType, T_NArrayReal, T_NArrayInt>(m);
415+ make_ParticleInitData<T_ParticleType, T_NArrayReal, T_NArrayInt>(m);
415416
416417 // first, because used as copy target in methods in containers with other allocators
417418 make_ParticleContainer_and_Iterators<T_ParticleType, T_NArrayReal, T_NArrayInt,
0 commit comments