forked from ECP-WarpX/WarpX
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added binding for
ParticleBoundaryBuffer
- Loading branch information
1 parent
624ac7a
commit d40e431
Showing
8 changed files
with
65 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/* Copyright 2021-2023 The WarpX Community | ||
* | ||
* Authors: Axel Huebl, Remi Lehe, Roelof Groenewald | ||
* License: BSD-3-Clause-LBNL | ||
*/ | ||
|
||
#include <Particles/ParticleBoundaryBuffer.H> | ||
#include <Particles/MultiParticleContainer.H> | ||
#include <Python/pyWarpX.H> | ||
|
||
namespace py = pybind11; | ||
|
||
|
||
void init_ParticleBoundaryBuffer (py::module& m) | ||
{ | ||
py::class_<ParticleBoundaryBuffer>(m, "ParticleBoundaryBuffer") | ||
.def(py::init<>()) | ||
.def("get_num_particles_in_container", | ||
[](ParticleBoundaryBuffer& pbc, | ||
const std::string species_name, int boundary, bool local) | ||
{ | ||
return pbc.getNumParticlesInContainer(species_name, boundary, local); | ||
}, | ||
py::arg("species_name"), py::arg("boundary"), py::arg("local")=true | ||
) | ||
; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters