ppmd.halo module¶
-
class
ppmd.halo.CartesianHaloSix(domain_func, cell_to_particle_map)¶ Bases:
object-
exchange_cell_counts()¶ Exchange the contents count of cells between processes. This is provided as a method in halo to avoid repeated exchanging of cell occupancy counts if multiple ParticleDat objects are being communicated.
-
get_boundary_cell_contents_count()¶ Get the number of particles in the corresponding cells for each halo. These are needed such that the cell list can be created without inspecting the positions of recvd particles.
- Returns
Tuple: Cell contents count for each cell in same order as local boundary cell list, Exchange sizes for each halo.
-
get_boundary_cell_groups()¶ Get the local boundary cells to pack for each halo. Formatted as an host.Array. Cells for halo 0 first followed by cells for halo 1 etc. Also returns an data.Array of 27 elements with the starting positions of each halo within the previous array.
- Returns
Tuple, array of local cell indices to pack, array of starting points within the first array.
-
get_dir_counts()¶
-
get_halo_cell_groups()¶ Get the local halo cells to unpack into for each halo. Formatted as an cuda_base.Array. Cells for halo 0 first followed by cells for halo 1 etc. Also returns an data.Array of 27 elements with the starting positions of each halo within the previous array.
- Returns
Tuple, array of local halo cell indices to unpack into, array of starting points within the first array.
-
get_position_shifts()¶ Calculate flag to determine if a boundary between processes is also a boundary in domain.
-
get_recv_ranks()¶ Get the mpi ranks to recv from.
-
get_send_ranks()¶ Get the mpi ranks to send to.
-
-
class
ppmd.halo.CellSlice¶ Bases:
object
-
ppmd.halo.create_halo_pairs_slice_halo(domain_in, slicexyz, direction)¶ Automatically create the pairs of cells for halos. Slices through whole domain including halo cells.