Vlasiator ebf0dd394 on dev (v5.4.0 + 1054 commits)
Loading...
Searching...
No Matches
spatial_cell::SpatialCell Class Reference

#include <spatial_cell_cpu.hpp>

Public Member Functions

 SpatialCell ()
 ~SpatialCell ()
 SpatialCell (const SpatialCell &other)
const SpatialCelloperator= (const SpatialCell &other)
template<int PAD>
void fetch_data (const vmesh::GlobalID &blockGID, const vmesh::VelocityMesh *vmesh, const Realf *src, Realf *array)
template<int PAD>
void fetch_acc_data (const vmesh::GlobalID &blockGID, const int &dim, vmesh::VelocityMesh *vmesh, const Realf *src, Realf *array, Real cellSizeFractions[2])
vmesh::GlobalID find_velocity_block (vmesh::GlobalID cellIndices[3], const uint popID)
Realfget_data (const uint popID)
const Realfget_data (const uint popID) const
Realfget_data (const vmesh::LocalID &blockLID, const uint popID)
const Realfget_data (const vmesh::LocalID &blockLID, const uint popID) const
Realget_block_parameters (const uint popID)
const Realget_block_parameters (const uint popID) const
Realget_block_parameters (const vmesh::LocalID &blockLID, const uint popID)
const Realget_block_parameters (const vmesh::LocalID &blockLID, const uint popID) const
Realget_cell_parameters ()
const Realget_cell_parameters () const
vmesh::LocalID get_number_of_velocity_blocks (const uint popID) const
vmesh::LocalID get_number_of_all_velocity_blocks () const
int get_number_of_populations () const
void debug_population_check (const uint popID) const
void debug_population_check (const uint popID, const vmesh::LocalID blockLID) const
Populationget_population (const uint popID)
const Populationget_population (const uint popID) const
void set_population (const Population &pop, cuint popID)
void scale_population (creal factor, cuint popID)
void increment_population (const Population &pop, creal factor, cuint popID)
std::vector< Population > & get_populations ()
const std::vector< Population > & get_populations () const
const Realget_max_r_dt (const uint popID) const
const Realget_max_v_dt (const uint popID) const
const vmesh::LocalIDget_velocity_grid_length (const uint popID)
const Realget_velocity_grid_block_size (const uint popID)
const Realget_velocity_grid_cell_size (const uint popID)
void get_velocity_block_coordinates (const uint popID, const vmesh::GlobalID &globalID, Real *coords)
velocity_block_indices_t get_velocity_block_indices (const uint popID, const vmesh::GlobalID globalID)
vmesh::GlobalID get_velocity_block (const uint popID, vmesh::GlobalID blockIndices[3]) const
vmesh::GlobalID get_velocity_block (const uint popID, const velocity_block_indices_t indices) const
vmesh::GlobalID get_velocity_block (const uint popID, const Real *coords) const
vmesh::GlobalID get_velocity_block (const uint popID, const Real vx, const Real vy, const Real vz) const
vmesh::GlobalID get_velocity_block_child (const uint popID, const vmesh::GlobalID &blockGID, const int &i_cell, const int &j_cell, const int &k_cell)
void get_velocity_block_children_local_ids (const vmesh::GlobalID &blockGID, std::vector< vmesh::LocalID > &childrenLIDs, const uint popID)
vmesh::GlobalID get_velocity_block_parent (const uint popID, const vmesh::GlobalID &blockGID)
vmesh::GlobalID get_velocity_block_global_id (const vmesh::LocalID &blockLID, const uint popID) const
vmesh::LocalID get_velocity_block_local_id (const vmesh::GlobalID &blockGID, const uint popID) const
void get_velocity_block_size (const uint popID, const vmesh::GlobalID block, Real size[3])
Real get_velocity_block_vx_min (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vx_max (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vy_min (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vy_max (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vz_min (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vz_max (const uint popID, const vmesh::GlobalID block) const
size_t count (const vmesh::GlobalID &block, const uint popID) const
void add_values (const vmesh::GlobalID &targetGID, std::unordered_map< vmesh::GlobalID, Realf[(WID+2) *(WID+2) *(WID+2)]> &sourceData, const uint popID)
void printMeshSizes ()
bool add_velocity_block (const vmesh::GlobalID &block, const uint popID)
void adjustSingleCellVelocityBlocks (const uint popID, bool doDeleteEmpty=false)
void adjust_velocity_blocks (const std::vector< SpatialCell * > &spatial_neighbors, const uint popID, bool doDeleteEmptyBlocks=true)
template<typename fileReal>
void add_velocity_blocks (const uint popID, const std::vector< vmesh::GlobalID > &blocks, fileReal *avgBuffer)
void update_velocity_block_content_lists (const uint popID)
bool checkMesh (const uint popID)
void clear (const uint popID, bool shrink=false)
void setNewSizeClear (const uint popID, const vmesh::LocalID &newSize)
void setNewSizeClear (const uint popID)
uint64_t get_cell_memory_capacity ()
uint64_t get_cell_memory_size ()
void merge_values (const uint popID)
void prepare_to_receive_blocks (const uint popID)
bool shrink_to_fit ()
size_t size (const uint popID) const
void remove_velocity_block (const vmesh::GlobalID &block, const uint popID)
vmesh::VelocityMeshget_velocity_mesh (const size_t &popID)
vmesh::VelocityBlockContainerget_velocity_blocks (const size_t &popID)
const vmesh::VelocityBlockContainerget_velocity_blocks (const size_t &popID) const
void set_max_r_dt (const uint popID, const Real &value)
void set_max_v_dt (const uint popID, const Real &value)
std::tuple< void *, int, MPI_Datatype > get_mpi_datatype (const CellID cellID, const int sender_rank, const int receiver_rank, const bool receiving, const int neighborhood)
void set_mpi_transfer_enabled (bool transferEnabled)
void updateSparseMinValue (const uint popID)
Real getVelocityBlockMinValue (const uint popID) const
 SpatialCell ()
 ~SpatialCell ()
 SpatialCell (const SpatialCell &other)
const SpatialCelloperator= (const SpatialCell &other)
void setReservation (const uint popID, const vmesh::LocalID reservationsize, bool force=false)
vmesh::LocalID getReservation (const uint popID) const
void applyReservation (const uint popID)
vmesh::GlobalID find_velocity_block (vmesh::GlobalID cellIndices[3], const uint popID)
Realfget_data (const uint popID)
const Realfget_data (const uint popID) const
Realfget_data (const vmesh::LocalID &blockLID, const uint popID)
const Realfget_data (const vmesh::LocalID &blockLID, const uint popID) const
Realget_block_parameters (const uint popID)
const Realget_block_parameters (const uint popID) const
Realget_block_parameters (const vmesh::LocalID &blockLID, const uint popID)
const Realget_block_parameters (const vmesh::LocalID &blockLID, const uint popID) const
Realfdev_get_data (const uint popID)
const Realfdev_get_data (const uint popID) const
Realdev_get_block_parameters (const uint popID)
const Realdev_get_block_parameters (const uint popID) const
Realget_cell_parameters ()
const Realget_cell_parameters () const
vmesh::LocalID get_number_of_velocity_blocks (const uint popID) const
vmesh::LocalID get_number_of_all_velocity_blocks () const
int get_number_of_populations () const
void debug_population_check (const uint popID) const
void debug_population_check (const uint popID, const vmesh::LocalID blockLID) const
Populationget_population (const uint popID)
const Populationget_population (const uint popID) const
void set_population (const Population &pop, cuint popID)
void scale_population (creal factor, cuint popID)
void increment_population (const Population &pop, creal factor, cuint popID)
void increment_mass_loss (cuint popID, Real increment)
std::vector< Population > & get_populations ()
const std::vector< Population > & get_populations () const
const Realget_max_r_dt (const uint popID) const
const Realget_max_v_dt (const uint popID) const
const vmesh::LocalIDget_velocity_grid_length (const uint popID)
const vmesh::GlobalIDget_velocity_grid (const uint popID)
const Realget_velocity_grid_block_size (const uint popID)
const Realget_velocity_grid_cell_size (const uint popID)
void get_velocity_block_coordinates (const uint popID, const vmesh::GlobalID &globalID, Real *coords)
velocity_block_indices_t get_velocity_block_indices (const uint popID, const vmesh::GlobalID globalID)
vmesh::GlobalID get_velocity_block (const uint popID, vmesh::GlobalID blockIndices[3]) const
vmesh::GlobalID get_velocity_block (const uint popID, const velocity_block_indices_t indices) const
vmesh::GlobalID get_velocity_block (const uint popID, const Real *coords) const
vmesh::GlobalID get_velocity_block (const uint popID, const Real vx, const Real vy, const Real vz) const
vmesh::GlobalID get_velocity_block_global_id (const vmesh::LocalID &blockLID, const uint popID) const
vmesh::LocalID get_velocity_block_local_id (const vmesh::GlobalID &blockGID, const uint popID) const
void get_velocity_block_size (const uint popID, const vmesh::GlobalID block, Real size[3])
Real get_velocity_block_vx_min (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vx_max (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vy_min (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vy_max (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vz_min (const uint popID, const vmesh::GlobalID block) const
Real get_velocity_block_vz_max (const uint popID, const vmesh::GlobalID block) const
size_t count (const vmesh::GlobalID &block, const uint popID) const
void printMeshSizes ()
void adjustSingleCellVelocityBlocks (const uint popID, bool doDeleteEmpty=false)
bool add_velocity_block (const vmesh::GlobalID &block, const uint popID)
void adjust_velocity_blocks (const uint popID, bool doDeleteEmptyBlocks=true)
vmesh::LocalID adjust_velocity_blocks_caller (const uint popID)
template<typename fileReal>
void add_velocity_blocks (const uint popID, const std::vector< vmesh::GlobalID > &blocks, fileReal *initBuffer)
void update_velocity_block_content_lists (const uint popID)
bool checkMesh (const uint popID)
bool checkSizes (const uint popID)
void clear (const uint popID, bool shrink=false)
void setNewSizeClear (const uint popID, const vmesh::LocalID &newSize)
void setNewSizeClear (const uint popID)
uint64_t get_cell_memory_capacity ()
uint64_t get_cell_memory_size ()
void prepare_to_receive_blocks (const uint popID)
bool shrink_to_fit ()
size_t size (const uint popID) const
void dev_resize_vmesh (const uint popID, const uint nBlocks)
vmesh::VelocityMeshget_velocity_mesh (const size_t &popID)
vmesh::VelocityBlockContainerget_velocity_blocks (const size_t &popID)
const vmesh::VelocityBlockContainerget_velocity_blocks (const size_t &popID) const
void dev_upload_population (const uint popID)
vmesh::VelocityMeshdev_get_velocity_mesh (const size_t &popID)
vmesh::VelocityBlockContainerdev_get_velocity_blocks (const size_t &popID)
const vmesh::VelocityBlockContainerdev_get_velocity_blocks (const size_t &popID) const
void prefetchDevice ()
void prefetchHost ()
void set_max_r_dt (const uint popID, const Real &value)
void set_max_v_dt (const uint popID, const Real &value)
std::tuple< void *, int, MPI_Datatype > get_mpi_datatype (const CellID cellID, const int sender_rank, const int receiver_rank, const bool receiving, const int neighborhood)
void set_mpi_transfer_enabled (bool transferEnabled)
void updateSparseMinValue (const uint popID)
Real getVelocityBlockMinValue (const uint popID) const

Static Public Member Functions

static unsigned int invalid_block_index ()
static vmesh::GlobalID invalid_global_id ()
static vmesh::LocalID invalid_local_id ()
static bool setCommunicatedSpecies (const uint popID)
static uint64_t get_mpi_transfer_type (void)
static void set_mpi_transfer_type (const uint64_t type, bool atSysBoundaries=false)
static void set_mpi_transfer_direction (const int dimension)
static unsigned int invalid_block_index ()
static vmesh::GlobalID invalid_global_id ()
static vmesh::LocalID invalid_local_id ()
static bool setCommunicatedSpecies (const uint popID)
static uint64_t get_mpi_transfer_type (void)
static void set_mpi_transfer_type (const uint64_t type, bool atSysBoundaries=false)
static void set_mpi_transfer_direction (const int dimension)

Public Attributes

std::array< Real, vderivatives::N_V_DERIVATIVESderivativesV
std::array< Real, bvolderivatives::N_BVOL_DERIVATIVESderivativesBVOL
std::array< Real, CellParams::N_SPATIAL_CELL_PARAMSparameters
std::array< Realf, WID3null_block_data
uint64_t ioLocalCellId
std::array< Realf *, MAX_NEIGHBORS_PER_DIMneighbor_block_data
std::array< vmesh::LocalID, MAX_NEIGHBORS_PER_DIMneighbor_number_of_blocks
std::map< int, std::set< int > > face_neighbor_ranks
uint sysBoundaryFlag
uint sysBoundaryLayer
int sysBoundaryLayerNew
std::vector< vmesh::GlobalID > * velocity_block_with_content_list
vmesh::LocalID velocity_block_with_content_list_size =0
std::vector< vmesh::GlobalID > * velocity_block_with_no_content_list
split::SplitVector< vmesh::GlobalID > * velocity_block_with_content_list =0
split::SplitVector< vmesh::GlobalID > * dev_velocity_block_with_content_list =0
vmesh::LocalID velocity_block_with_content_list_capacity =0
Hashinator::Hashmap< vmesh::GlobalID, vmesh::LocalID > * velocity_block_with_content_map =0
Hashinator::Hashmap< vmesh::GlobalID, vmesh::LocalID > * velocity_block_with_no_content_map =0
Hashinator::Hashmap< vmesh::GlobalID, vmesh::LocalID > * dev_velocity_block_with_content_map =0
Hashinator::Hashmap< vmesh::GlobalID, vmesh::LocalID > * dev_velocity_block_with_no_content_map =0
vmesh::LocalID vbwcl_sizePower
vmesh::LocalID vbwncl_sizePower
split::SplitVector< vmesh::GlobalID > * list_with_replace_new =0
split::SplitVector< vmesh::GlobalID > * dev_list_with_replace_new =0
split::SplitVector< Hashinator::hash_pair< vmesh::GlobalID, vmesh::LocalID > > * list_delete =0
split::SplitVector< Hashinator::hash_pair< vmesh::GlobalID, vmesh::LocalID > > * dev_list_delete =0
split::SplitVector< Hashinator::hash_pair< vmesh::GlobalID, vmesh::LocalID > > * list_to_replace =0
split::SplitVector< Hashinator::hash_pair< vmesh::GlobalID, vmesh::LocalID > > * dev_list_to_replace =0
split::SplitVector< Hashinator::hash_pair< vmesh::GlobalID, vmesh::LocalID > > * list_with_replace_old =0
split::SplitVector< Hashinator::hash_pair< vmesh::GlobalID, vmesh::LocalID > > * dev_list_with_replace_old =0
vmesh::LocalID list_with_replace_new_capacity =0
vmesh::LocalID list_delete_capacity =0
vmesh::LocalID list_to_replace_capacity =0
vmesh::LocalID list_with_replace_old_capacity =0
Realfgpu_rhoLossAdjust
Real density_pre_adjust
Real density_post_adjust
uint64_t largestvmesh = 0

Static Public Attributes

static uint64_t mpi_transfer_type = 0
static bool mpiTransferAtSysBoundaries = false

Private Member Functions

bool compute_block_has_content (const vmesh::GlobalID &block, const uint popID) const

Private Attributes

bool initialized
bool mpiTransferEnabled
std::vector< spatial_cell::Populationpopulations

Static Private Attributes

static int activePopID = 0

Detailed Description

Definition at line 235 of file spatial_cell_cpu.hpp.

Constructor & Destructor Documentation

◆ SpatialCell() [1/4]

spatial_cell::SpatialCell::SpatialCell ( )

Definition at line 41 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ~SpatialCell() [1/2]

spatial_cell::SpatialCell::~SpatialCell ( )

Definition at line 84 of file spatial_cell_cpu.cpp.

◆ SpatialCell() [2/4]

spatial_cell::SpatialCell::SpatialCell ( const SpatialCell & other)

Definition at line 89 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:

◆ SpatialCell() [3/4]

spatial_cell::SpatialCell::SpatialCell ( )

◆ ~SpatialCell() [2/2]

spatial_cell::SpatialCell::~SpatialCell ( )

◆ SpatialCell() [4/4]

spatial_cell::SpatialCell::SpatialCell ( const SpatialCell & other)
Here is the call graph for this function:

Member Function Documentation

◆ add_values()

void spatial_cell::SpatialCell::add_values ( const vmesh::GlobalID & targetGID,
std::unordered_map< vmesh::GlobalID, Realf[(WID+2) *(WID+2) *(WID+2)]> & sourceData,
const uint popID )

◆ add_velocity_block() [1/2]

bool spatial_cell::SpatialCell::add_velocity_block ( const vmesh::GlobalID & block,
const uint popID )
inline

Adds an empty velocity block into this spatial cell. Returns true if given block was added or already exists. Returns false if given block is invalid or would be outside of the velocity grid.

Definition at line 760 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ add_velocity_block() [2/2]

bool spatial_cell::SpatialCell::add_velocity_block ( const vmesh::GlobalID & block,
const uint popID )

◆ add_velocity_blocks() [1/2]

template<typename fileReal>
void spatial_cell::SpatialCell::add_velocity_blocks ( const uint popID,
const std::vector< vmesh::GlobalID > & blocks,
fileReal * initBuffer )

Adds a vector of velocity blocks to the population, sets the parameters, and fills the data with phase-space densities from the provided buffer (which was read from a file). The copy operation is skipped if the avgBuffer is nullptr

Adds a vector of velocity blocks to the population, sets the parameters, and fills the data with phase-space densities from the provided buffer (which was read from a file). This version calls a kernel to perform operations on-device.

Definition at line 785 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ add_velocity_blocks() [2/2]

template<typename fileReal>
void spatial_cell::SpatialCell::add_velocity_blocks ( const uint popID,
const std::vector< vmesh::GlobalID > & blocks,
fileReal * initBuffer )

◆ adjust_velocity_blocks() [1/2]

void spatial_cell::SpatialCell::adjust_velocity_blocks ( const std::vector< SpatialCell * > & spatial_neighbors,
const uint popID,
bool doDeleteEmptyBlocks = true )

Adds "important" and removes "unimportant" velocity blocks to/from this cell.

velocity_block_with_content_list needs to be up to date in local and remote cells. velocity_block_with_no_content_list needs to be up to date in local cells.

update_velocity_block_with_content_lists() should have been called with the current distribution function values, and then the content list transferred.

Removes all velocity blocks from this spatial cell which don't have content and don't have spatial or velocity neighbors with content. Adds neighbors for all velocity blocks which do have content (including spatial neighbors). All cells in spatial_neighbors are assumed to be neighbors of this cell.

This function is thread-safe when called for different cells per thread. We need the block_has_content vector from neighbouring cells, but these are not written to here. We only modify local cell.

Definition at line 179 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ adjust_velocity_blocks() [2/2]

void spatial_cell::SpatialCell::adjust_velocity_blocks ( const uint popID,
bool doDeleteEmptyBlocks = true )

Adds "important" and removes "unimportant" velocity blocks to/from this cell.

velocity_block_with_content_list needs to be up to date in local and remote cells. velocity_block_with_no_content_list needs to be up to date in local cells.

update_velocity_block_with_content_lists() should have been called with the current distribution function values, and then the contetn list transferred.

Removes all velocity blocks from this spatial cell which don't have content and don't have spatial or velocity neighbors with content. Adds neighbors for all velocity blocks which do have content (including spatial neighbors). All cells in spatial_neighbors are assumed to be neighbors of this cell.

This function is thread-safe when called for different cells per thread. We need the block_has_content vector from neighbouring cells, but these are not written to here. We only modify local cell.

Neighbour inclusion: GPU block adjusment now happens via batch calls. Single-cell block adjustments will not want to account for neighbours, so this code is no longer needed.

Now extract vectors to be used in actual block adjustment. Previous kernels may have added dummy (to be added) entries to velocity_block_with_content_map with LID=vmesh->invalidLocalID() Or non-content blocks which should be retained (with correct LIDs).

Rules used in extracting keys or elements from hashmaps Now these include passing pointers to GPU memory in order to evaluate nBlocksAfterAdjust without going via host. Pointers are copied by value.

Definition at line 437 of file spatial_cell_gpu.cpp.

Here is the call graph for this function:

◆ adjust_velocity_blocks_caller()

vmesh::LocalID spatial_cell::SpatialCell::adjust_velocity_blocks_caller ( const uint popID)

Call GPU kernel with all necessary information for creation and deletion of blocks.

Definition at line 617 of file spatial_cell_gpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ adjustSingleCellVelocityBlocks() [1/2]

void spatial_cell::SpatialCell::adjustSingleCellVelocityBlocks ( const uint popID,
bool doDeleteEmpty = false )

Definition at line 275 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ adjustSingleCellVelocityBlocks() [2/2]

void spatial_cell::SpatialCell::adjustSingleCellVelocityBlocks ( const uint popID,
bool doDeleteEmpty = false )

◆ applyReservation()

void spatial_cell::SpatialCell::applyReservation ( const uint popID)

Recapacitates local temporary vectors based on guidance counter

Definition at line 334 of file spatial_cell_gpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkMesh() [1/2]

bool spatial_cell::SpatialCell::checkMesh ( const uint popID)
inline

Definition at line 687 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkMesh() [2/2]

bool spatial_cell::SpatialCell::checkMesh ( const uint popID)

◆ checkSizes()

bool spatial_cell::SpatialCell::checkSizes ( const uint popID)
inline

Definition at line 1092 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:

◆ clear() [1/2]

void spatial_cell::SpatialCell::clear ( const uint popID,
bool shrink = false )
inline

Removes all velocity blocks from this spatial cell and frees memory in the cell

Definition at line 695 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ clear() [2/2]

void spatial_cell::SpatialCell::clear ( const uint popID,
bool shrink = false )

◆ compute_block_has_content()

bool spatial_cell::SpatialCell::compute_block_has_content ( const vmesh::GlobalID & block,
const uint popID ) const
private

Returns true if given velocity block has enough of a distribution function. Returns false if the value of the distribution function is too low in every sense in given block. Also returns false if given block doesn't exist or is an error block.

Definition at line 290 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ count() [1/2]

size_t spatial_cell::SpatialCell::count ( const vmesh::GlobalID & block,
const uint popID ) const
inline

Returns the number of given velocity blocks that exist.

Definition at line 660 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ count() [2/2]

size_t spatial_cell::SpatialCell::count ( const vmesh::GlobalID & block,
const uint popID ) const

◆ debug_population_check() [1/4]

void spatial_cell::SpatialCell::debug_population_check ( const uint popID) const
inline

Definition at line 397 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ debug_population_check() [2/4]

void spatial_cell::SpatialCell::debug_population_check ( const uint popID) const

◆ debug_population_check() [3/4]

void spatial_cell::SpatialCell::debug_population_check ( const uint popID,
const vmesh::LocalID blockLID ) const
inline

Definition at line 406 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ debug_population_check() [4/4]

void spatial_cell::SpatialCell::debug_population_check ( const uint popID,
const vmesh::LocalID blockLID ) const

◆ dev_get_block_parameters() [1/2]

Real * spatial_cell::SpatialCell::dev_get_block_parameters ( const uint popID)
inline

Definition at line 790 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:

◆ dev_get_block_parameters() [2/2]

const Real * spatial_cell::SpatialCell::dev_get_block_parameters ( const uint popID) const
inline

Definition at line 795 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:

◆ dev_get_data() [1/2]

Realf * spatial_cell::SpatialCell::dev_get_data ( const uint popID)
inline

Definition at line 750 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:

◆ dev_get_data() [2/2]

const Realf * spatial_cell::SpatialCell::dev_get_data ( const uint popID) const
inline

Definition at line 755 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:

◆ dev_get_velocity_blocks() [1/2]

vmesh::VelocityBlockContainer * spatial_cell::SpatialCell::dev_get_velocity_blocks ( const size_t & popID)
inline

Definition at line 1074 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ dev_get_velocity_blocks() [2/2]

const vmesh::VelocityBlockContainer * spatial_cell::SpatialCell::dev_get_velocity_blocks ( const size_t & popID) const
inline

Definition at line 1078 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:

◆ dev_get_velocity_mesh()

vmesh::VelocityMesh * spatial_cell::SpatialCell::dev_get_velocity_mesh ( const size_t & popID)
inline

Definition at line 1061 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ dev_resize_vmesh()

void spatial_cell::SpatialCell::dev_resize_vmesh ( const uint popID,
const uint nBlocks )
inline

Resizes the chosen velocity mesh on-device.

Definition at line 1039 of file spatial_cell_gpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ dev_upload_population()

void spatial_cell::SpatialCell::dev_upload_population ( const uint popID)
inline

Definition at line 786 of file spatial_cell_gpu.hpp.

Here is the caller graph for this function:

◆ fetch_acc_data()

template<int PAD>
void spatial_cell::SpatialCell::fetch_acc_data ( const vmesh::GlobalID & blockGID,
const int & dim,
vmesh::VelocityMesh * vmesh,
const Realf * src,
Realf * array,
Real cellSizeFractions[2] )

◆ fetch_data()

template<int PAD>
void spatial_cell::SpatialCell::fetch_data ( const vmesh::GlobalID & blockGID,
const vmesh::VelocityMesh * vmesh,
const Realf * src,
Realf * array )

◆ find_velocity_block() [1/2]

vmesh::GlobalID spatial_cell::SpatialCell::find_velocity_block ( vmesh::GlobalID cellIndices[3],
const uint popID )
inline

Definition at line 417 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ find_velocity_block() [2/2]

vmesh::GlobalID spatial_cell::SpatialCell::find_velocity_block ( vmesh::GlobalID cellIndices[3],
const uint popID )

◆ get_block_parameters() [1/8]

Real * spatial_cell::SpatialCell::get_block_parameters ( const uint popID)
inline

Definition at line 448 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_block_parameters() [2/8]

Real * spatial_cell::SpatialCell::get_block_parameters ( const uint popID)

◆ get_block_parameters() [3/8]

const Real * spatial_cell::SpatialCell::get_block_parameters ( const uint popID) const
inline

Definition at line 453 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_block_parameters() [4/8]

const Real * spatial_cell::SpatialCell::get_block_parameters ( const uint popID) const

◆ get_block_parameters() [5/8]

Real * spatial_cell::SpatialCell::get_block_parameters ( const vmesh::LocalID & blockLID,
const uint popID )
inline

Definition at line 458 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_block_parameters() [6/8]

Real * spatial_cell::SpatialCell::get_block_parameters ( const vmesh::LocalID & blockLID,
const uint popID )

◆ get_block_parameters() [7/8]

const Real * spatial_cell::SpatialCell::get_block_parameters ( const vmesh::LocalID & blockLID,
const uint popID ) const
inline

Definition at line 463 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_block_parameters() [8/8]

const Real * spatial_cell::SpatialCell::get_block_parameters ( const vmesh::LocalID & blockLID,
const uint popID ) const

◆ get_cell_memory_capacity() [1/2]

uint64_t spatial_cell::SpatialCell::get_cell_memory_capacity ( )
inline

Return the memory consumption in bytes as reported using the size() functions of the containers in spatial cell

Definition at line 737 of file spatial_cell_cpu.hpp.

◆ get_cell_memory_capacity() [2/2]

uint64_t spatial_cell::SpatialCell::get_cell_memory_capacity ( )

◆ get_cell_memory_size() [1/2]

uint64_t spatial_cell::SpatialCell::get_cell_memory_size ( )
inline

Return the memory consumption in bytes as reported using the size() functions of the containers in spatial cell

Definition at line 717 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_cell_memory_size() [2/2]

uint64_t spatial_cell::SpatialCell::get_cell_memory_size ( )

◆ get_cell_parameters() [1/4]

Real * spatial_cell::SpatialCell::get_cell_parameters ( )
inline

Definition at line 468 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_cell_parameters() [2/4]

Real * spatial_cell::SpatialCell::get_cell_parameters ( )

◆ get_cell_parameters() [3/4]

const Real * spatial_cell::SpatialCell::get_cell_parameters ( ) const
inline

Definition at line 472 of file spatial_cell_cpu.hpp.

◆ get_cell_parameters() [4/4]

const Real * spatial_cell::SpatialCell::get_cell_parameters ( ) const

◆ get_data() [1/8]

Realf * spatial_cell::SpatialCell::get_data ( const uint popID)
inline

Definition at line 422 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_data() [2/8]

Realf * spatial_cell::SpatialCell::get_data ( const uint popID)

◆ get_data() [3/8]

const Realf * spatial_cell::SpatialCell::get_data ( const uint popID) const
inline

Definition at line 427 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_data() [4/8]

const Realf * spatial_cell::SpatialCell::get_data ( const uint popID) const

◆ get_data() [5/8]

Realf * spatial_cell::SpatialCell::get_data ( const vmesh::LocalID & blockLID,
const uint popID )
inline

Definition at line 432 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_data() [6/8]

Realf * spatial_cell::SpatialCell::get_data ( const vmesh::LocalID & blockLID,
const uint popID )

◆ get_data() [7/8]

const Realf * spatial_cell::SpatialCell::get_data ( const vmesh::LocalID & blockLID,
const uint popID ) const
inline

Definition at line 440 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_data() [8/8]

const Realf * spatial_cell::SpatialCell::get_data ( const vmesh::LocalID & blockLID,
const uint popID ) const

◆ get_max_r_dt() [1/2]

const Real & spatial_cell::SpatialCell::get_max_r_dt ( const uint popID) const

Get maximum translation timestep for the given species.

Parameters
popIDID of the particle species.
Returns
Maximum timestep calculated by the Vlasov translation.

Definition at line 321 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_max_r_dt() [2/2]

const Real & spatial_cell::SpatialCell::get_max_r_dt ( const uint popID) const

◆ get_max_v_dt() [1/2]

const Real & spatial_cell::SpatialCell::get_max_v_dt ( const uint popID) const

Get maximum acceleration timestep for the given species.

Parameters
popIDID of the particle species.
Returns
Maximum timestep calculated by Vlasov acceleration.

Definition at line 329 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_max_v_dt() [2/2]

const Real & spatial_cell::SpatialCell::get_max_v_dt ( const uint popID) const

◆ get_mpi_datatype() [1/2]

std::tuple< void *, int, MPI_Datatype > spatial_cell::SpatialCell::get_mpi_datatype ( const CellID cellID,
const int sender_rank,
const int receiver_rank,
const bool receiving,
const int neighborhood )

Get MPI datatype for sending the cell data.

Parameters
cellIDSpatial cell (dccrg) ID.
sender_rankRank of the MPI process sending data from this cell.
receiver_rankRank of the MPI process receiving data to this cell.
receivingIf true, this process is receiving data.
neighborhoodNeighborhood ID.
Returns
MPI datatype that transfers the requested data.

Get MPI datatype for sending the cell data.

Parameters
cellIDSpatial cell (dccrg) ID.
sender_rankRank of the MPI process sending data from this cell.
receiver_rankRank of the MPI process receiving data to this cell.
receivingIf true, this process is receiving data.
neighborhoodNeighborhood ID.
Returns
MPI datatype that transfers the requested data. Minimum value of distribution function in any phase space cell of a velocity block for the block to be considered to have content.
Parameters
popIDID of the particle species.
Returns
Sparse min value for this species.

Definition at line 341 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:

◆ get_mpi_datatype() [2/2]

std::tuple< void *, int, MPI_Datatype > spatial_cell::SpatialCell::get_mpi_datatype ( const CellID cellID,
const int sender_rank,
const int receiver_rank,
const bool receiving,
const int neighborhood )

◆ get_mpi_transfer_type() [1/2]

uint64_t spatial_cell::SpatialCell::get_mpi_transfer_type ( void )
inlinestatic

Gets the type of data that will be transferred by mpi_datatype.

Definition at line 870 of file spatial_cell_cpu.hpp.

◆ get_mpi_transfer_type() [2/2]

uint64_t spatial_cell::SpatialCell::get_mpi_transfer_type ( void )
static

◆ get_number_of_all_velocity_blocks() [1/2]

vmesh::LocalID spatial_cell::SpatialCell::get_number_of_all_velocity_blocks ( ) const
inline

Get the total number of velocity blocks in this cell, summed over all existing particle populations.

Returns
Total number of velocity blocks in the cell.

Definition at line 484 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_number_of_all_velocity_blocks() [2/2]

vmesh::LocalID spatial_cell::SpatialCell::get_number_of_all_velocity_blocks ( ) const

◆ get_number_of_populations() [1/2]

int spatial_cell::SpatialCell::get_number_of_populations ( ) const
inline

Definition at line 491 of file spatial_cell_cpu.hpp.

◆ get_number_of_populations() [2/2]

int spatial_cell::SpatialCell::get_number_of_populations ( ) const

◆ get_number_of_velocity_blocks() [1/2]

vmesh::LocalID spatial_cell::SpatialCell::get_number_of_velocity_blocks ( const uint popID) const
inline

Definition at line 476 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_number_of_velocity_blocks() [2/2]

vmesh::LocalID spatial_cell::SpatialCell::get_number_of_velocity_blocks ( const uint popID) const

◆ get_population() [1/4]

Population & spatial_cell::SpatialCell::get_population ( const uint popID)
inline

Definition at line 495 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_population() [2/4]

Population & spatial_cell::SpatialCell::get_population ( const uint popID)

◆ get_population() [3/4]

const Population & spatial_cell::SpatialCell::get_population ( const uint popID) const
inline

Definition at line 499 of file spatial_cell_cpu.hpp.

◆ get_population() [4/4]

const Population & spatial_cell::SpatialCell::get_population ( const uint popID) const

◆ get_populations() [1/4]

std::vector< Population > & spatial_cell::SpatialCell::get_populations ( )
inline

Definition at line 512 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_populations() [2/4]

std::vector< Population > & spatial_cell::SpatialCell::get_populations ( )

◆ get_populations() [3/4]

const std::vector< Population > & spatial_cell::SpatialCell::get_populations ( ) const
inline

Definition at line 515 of file spatial_cell_cpu.hpp.

◆ get_populations() [4/4]

const std::vector< Population > & spatial_cell::SpatialCell::get_populations ( ) const

◆ get_velocity_block() [1/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
const Real * coords ) const
inline

Definition at line 564 of file spatial_cell_cpu.hpp.

◆ get_velocity_block() [2/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
const Real * coords ) const

◆ get_velocity_block() [3/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
const Real vx,
const Real vy,
const Real vz ) const
inline

Returns the velocity block at given location or error_velocity_block if outside of the velocity grid

Definition at line 559 of file spatial_cell_cpu.hpp.

◆ get_velocity_block() [4/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
const Real vx,
const Real vy,
const Real vz ) const

◆ get_velocity_block() [5/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
const velocity_block_indices_t indices ) const
inline

Returns the velocity block at given indices or error_velocity_block

Definition at line 547 of file spatial_cell_cpu.hpp.

◆ get_velocity_block() [6/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
const velocity_block_indices_t indices ) const

◆ get_velocity_block() [7/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
vmesh::GlobalID blockIndices[3] ) const
inline

Definition at line 551 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_velocity_block() [8/8]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block ( const uint popID,
vmesh::GlobalID blockIndices[3] ) const

◆ get_velocity_block_child()

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block_child ( const uint popID,
const vmesh::GlobalID & blockGID,
const int & i_cell,
const int & j_cell,
const int & k_cell )

◆ get_velocity_block_children_local_ids()

void spatial_cell::SpatialCell::get_velocity_block_children_local_ids ( const vmesh::GlobalID & blockGID,
std::vector< vmesh::LocalID > & childrenLIDs,
const uint popID )

◆ get_velocity_block_coordinates() [1/2]

void spatial_cell::SpatialCell::get_velocity_block_coordinates ( const uint popID,
const vmesh::GlobalID & globalID,
Real * coords )
inline

Definition at line 531 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_velocity_block_coordinates() [2/2]

void spatial_cell::SpatialCell::get_velocity_block_coordinates ( const uint popID,
const vmesh::GlobalID & globalID,
Real * coords )

◆ get_velocity_block_global_id() [1/2]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block_global_id ( const vmesh::LocalID & blockLID,
const uint popID ) const
inline

Definition at line 568 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_velocity_block_global_id() [2/2]

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block_global_id ( const vmesh::LocalID & blockLID,
const uint popID ) const

◆ get_velocity_block_indices() [1/2]

velocity_block_indices_t spatial_cell::SpatialCell::get_velocity_block_indices ( const uint popID,
const vmesh::GlobalID block )
inline

Returns the indices of given velocity block

Definition at line 538 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_velocity_block_indices() [2/2]

velocity_block_indices_t spatial_cell::SpatialCell::get_velocity_block_indices ( const uint popID,
const vmesh::GlobalID globalID )

◆ get_velocity_block_local_id() [1/2]

vmesh::LocalID spatial_cell::SpatialCell::get_velocity_block_local_id ( const vmesh::GlobalID & blockGID,
const uint popID ) const
inline

Definition at line 573 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_velocity_block_local_id() [2/2]

vmesh::LocalID spatial_cell::SpatialCell::get_velocity_block_local_id ( const vmesh::GlobalID & blockGID,
const uint popID ) const

◆ get_velocity_block_parent()

vmesh::GlobalID spatial_cell::SpatialCell::get_velocity_block_parent ( const uint popID,
const vmesh::GlobalID & blockGID )
Here is the call graph for this function:

◆ get_velocity_block_size() [1/2]

void spatial_cell::SpatialCell::get_velocity_block_size ( const uint popID,
const vmesh::GlobalID block,
Real size[3] )
inline

Definition at line 578 of file spatial_cell_cpu.hpp.

◆ get_velocity_block_size() [2/2]

void spatial_cell::SpatialCell::get_velocity_block_size ( const uint popID,
const vmesh::GlobalID block,
Real size[3] )
Here is the call graph for this function:

◆ get_velocity_block_vx_max() [1/2]

Real spatial_cell::SpatialCell::get_velocity_block_vx_max ( const uint popID,
const vmesh::GlobalID block ) const
inline

Returns the edge where given velocity block ends.

Definition at line 594 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_velocity_block_vx_max() [2/2]

Real spatial_cell::SpatialCell::get_velocity_block_vx_max ( const uint popID,
const vmesh::GlobalID block ) const

◆ get_velocity_block_vx_min() [1/2]

Real spatial_cell::SpatialCell::get_velocity_block_vx_min ( const uint popID,
const vmesh::GlobalID block ) const
inline

Returns the edge where given velocity block starts.

Definition at line 585 of file spatial_cell_cpu.hpp.

◆ get_velocity_block_vx_min() [2/2]

Real spatial_cell::SpatialCell::get_velocity_block_vx_min ( const uint popID,
const vmesh::GlobalID block ) const

◆ get_velocity_block_vy_max() [1/2]

Real spatial_cell::SpatialCell::get_velocity_block_vy_max ( const uint popID,
const vmesh::GlobalID block ) const
inline

Returns the edge where given velocity block ends.

Definition at line 615 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_velocity_block_vy_max() [2/2]

Real spatial_cell::SpatialCell::get_velocity_block_vy_max ( const uint popID,
const vmesh::GlobalID block ) const

◆ get_velocity_block_vy_min() [1/2]

Real spatial_cell::SpatialCell::get_velocity_block_vy_min ( const uint popID,
const vmesh::GlobalID block ) const
inline

Returns the edge where given velocity block starts.

Definition at line 606 of file spatial_cell_cpu.hpp.

◆ get_velocity_block_vy_min() [2/2]

Real spatial_cell::SpatialCell::get_velocity_block_vy_min ( const uint popID,
const vmesh::GlobalID block ) const

◆ get_velocity_block_vz_max() [1/2]

Real spatial_cell::SpatialCell::get_velocity_block_vz_max ( const uint popID,
const vmesh::GlobalID block ) const
inline

Returns the edge where given velocity block ends.

Definition at line 636 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_velocity_block_vz_max() [2/2]

Real spatial_cell::SpatialCell::get_velocity_block_vz_max ( const uint popID,
const vmesh::GlobalID block ) const

◆ get_velocity_block_vz_min() [1/2]

Real spatial_cell::SpatialCell::get_velocity_block_vz_min ( const uint popID,
const vmesh::GlobalID block ) const
inline

Returns the edge where given velocity block starts.

Definition at line 627 of file spatial_cell_cpu.hpp.

◆ get_velocity_block_vz_min() [2/2]

Real spatial_cell::SpatialCell::get_velocity_block_vz_min ( const uint popID,
const vmesh::GlobalID block ) const

◆ get_velocity_blocks() [1/4]

vmesh::VelocityBlockContainer * spatial_cell::SpatialCell::get_velocity_blocks ( const size_t & popID)
inline

Definition at line 678 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_velocity_blocks() [2/4]

vmesh::VelocityBlockContainer * spatial_cell::SpatialCell::get_velocity_blocks ( const size_t & popID)

◆ get_velocity_blocks() [3/4]

const vmesh::VelocityBlockContainer * spatial_cell::SpatialCell::get_velocity_blocks ( const size_t & popID) const
inline

Definition at line 682 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ get_velocity_blocks() [4/4]

const vmesh::VelocityBlockContainer * spatial_cell::SpatialCell::get_velocity_blocks ( const size_t & popID) const

◆ get_velocity_grid()

const vmesh::GlobalID * spatial_cell::SpatialCell::get_velocity_grid ( const uint popID)
inline

Definition at line 882 of file spatial_cell_gpu.hpp.

Here is the caller graph for this function:

◆ get_velocity_grid_block_size() [1/2]

const Real * spatial_cell::SpatialCell::get_velocity_grid_block_size ( const uint popID)
inline

Definition at line 523 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_velocity_grid_block_size() [2/2]

const Real * spatial_cell::SpatialCell::get_velocity_grid_block_size ( const uint popID)

◆ get_velocity_grid_cell_size() [1/2]

const Real * spatial_cell::SpatialCell::get_velocity_grid_cell_size ( const uint popID)
inline

Definition at line 527 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_velocity_grid_cell_size() [2/2]

const Real * spatial_cell::SpatialCell::get_velocity_grid_cell_size ( const uint popID)

◆ get_velocity_grid_length() [1/2]

const vmesh::LocalID * spatial_cell::SpatialCell::get_velocity_grid_length ( const uint popID)
inline

Definition at line 519 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ get_velocity_grid_length() [2/2]

const vmesh::LocalID * spatial_cell::SpatialCell::get_velocity_grid_length ( const uint popID)

◆ get_velocity_mesh() [1/2]

vmesh::VelocityMesh * spatial_cell::SpatialCell::get_velocity_mesh ( const size_t & popID)
inline

Definition at line 673 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_velocity_mesh() [2/2]

vmesh::VelocityMesh * spatial_cell::SpatialCell::get_velocity_mesh ( const size_t & popID)

◆ getReservation()

vmesh::LocalID spatial_cell::SpatialCell::getReservation ( const uint popID) const

Definition at line 329 of file spatial_cell_gpu.cpp.

Here is the caller graph for this function:

◆ getVelocityBlockMinValue() [1/2]

Real spatial_cell::SpatialCell::getVelocityBlockMinValue ( const uint popID) const

Get random number generator data buffer.

Returns
Random number generator data buffer. Get random number generator state buffer.
Random number generator state buffer. < Minimum value of distribution function in any phase space cell of a velocity block for the block to be considered to have content.
Parameters
popIDID of the particle species.
Returns
Sparse min value for this species.

Definition at line 592 of file spatial_cell_cpu.cpp.

Here is the caller graph for this function:

◆ getVelocityBlockMinValue() [2/2]

Real spatial_cell::SpatialCell::getVelocityBlockMinValue ( const uint popID) const

◆ increment_mass_loss()

void spatial_cell::SpatialCell::increment_mass_loss ( cuint popID,
Real increment )
inline

Definition at line 867 of file spatial_cell_gpu.hpp.

Here is the caller graph for this function:

◆ increment_population() [1/2]

void spatial_cell::SpatialCell::increment_population ( const Population & pop,
creal factor,
cuint popID )
inline

Definition at line 509 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ increment_population() [2/2]

void spatial_cell::SpatialCell::increment_population ( const Population & pop,
creal factor,
cuint popID )

◆ invalid_block_index() [1/2]

unsigned int spatial_cell::SpatialCell::invalid_block_index ( )
inlinestatic

Definition at line 645 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:

◆ invalid_block_index() [2/2]

unsigned int spatial_cell::SpatialCell::invalid_block_index ( )
static

◆ invalid_global_id() [1/2]

vmesh::GlobalID spatial_cell::SpatialCell::invalid_global_id ( )
inlinestatic

Definition at line 649 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ invalid_global_id() [2/2]

vmesh::GlobalID spatial_cell::SpatialCell::invalid_global_id ( )
static

◆ invalid_local_id() [1/2]

vmesh::GlobalID spatial_cell::SpatialCell::invalid_local_id ( )
inlinestatic

Definition at line 653 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ invalid_local_id() [2/2]

vmesh::LocalID spatial_cell::SpatialCell::invalid_local_id ( )
static

◆ merge_values()

void spatial_cell::SpatialCell::merge_values ( const uint popID)

◆ operator=() [1/2]

const SpatialCell & spatial_cell::SpatialCell::operator= ( const SpatialCell & other)

Definition at line 123 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:

◆ operator=() [2/2]

const SpatialCell & spatial_cell::SpatialCell::operator= ( const SpatialCell & other)
Here is the call graph for this function:

◆ prefetchDevice()

void spatial_cell::SpatialCell::prefetchDevice ( )

Definition at line 767 of file spatial_cell_gpu.cpp.

◆ prefetchHost()

void spatial_cell::SpatialCell::prefetchHost ( )

Definition at line 773 of file spatial_cell_gpu.cpp.

◆ prepare_to_receive_blocks() [1/2]

void spatial_cell::SpatialCell::prepare_to_receive_blocks ( const uint popID)

Prepares this spatial cell to receive the velocity grid over MPI. At this stage we have received a new block list over MPI into mpi_velocity_block_list, but the rest of the cell structures have not been adapted to this new list. Here we re-initialize the cell with empty blocks based on the new list.

Prepares this spatial cell to receive the velocity grid over MPI. At this stage we have received a new block list (over MPI or from an initializatiom function), but the rest of the cell structures have not been adapted to this new list. Here we re-initialize the cell with empty blocks based on the new list.

Definition at line 601 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ prepare_to_receive_blocks() [2/2]

void spatial_cell::SpatialCell::prepare_to_receive_blocks ( const uint popID)

◆ printMeshSizes() [1/2]

void spatial_cell::SpatialCell::printMeshSizes ( )

Definition at line 690 of file spatial_cell_cpu.cpp.

◆ printMeshSizes() [2/2]

void spatial_cell::SpatialCell::printMeshSizes ( )

◆ remove_velocity_block()

void spatial_cell::SpatialCell::remove_velocity_block ( const vmesh::GlobalID & block,
const uint popID )
inline

Removes given block from the velocity grid. Does nothing if given block doesn't exist.

Definition at line 832 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ scale_population() [1/2]

void spatial_cell::SpatialCell::scale_population ( creal factor,
cuint popID )
inline

Definition at line 506 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ scale_population() [2/2]

void spatial_cell::SpatialCell::scale_population ( creal factor,
cuint popID )

◆ set_max_r_dt() [1/2]

void spatial_cell::SpatialCell::set_max_r_dt ( const uint popID,
const Real & value )

Set maximum translation timestep for a particle species. This function is called during Vlasov translation.

Parameters
popIDID of the particle species.
valueNew maximum timestep.

Definition at line 636 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ set_max_r_dt() [2/2]

void spatial_cell::SpatialCell::set_max_r_dt ( const uint popID,
const Real & value )

◆ set_max_v_dt() [1/2]

void spatial_cell::SpatialCell::set_max_v_dt ( const uint popID,
const Real & value )

Set maximum acceleration timestep for a particle species. This function is called during Vlasov acceleration.

Parameters
popIDID of the particle species.
valueNew maximum timestep.

Definition at line 645 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:

◆ set_max_v_dt() [2/2]

void spatial_cell::SpatialCell::set_max_v_dt ( const uint popID,
const Real & value )

◆ set_mpi_transfer_direction() [1/2]

void spatial_cell::SpatialCell::set_mpi_transfer_direction ( const int dimension)
static

◆ set_mpi_transfer_direction() [2/2]

void spatial_cell::SpatialCell::set_mpi_transfer_direction ( const int dimension)
static

◆ set_mpi_transfer_enabled() [1/2]

void spatial_cell::SpatialCell::set_mpi_transfer_enabled ( bool transferEnabled)
inline

Set if this cell is transferred/received using MPI in the next communication phase.

Definition at line 877 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ set_mpi_transfer_enabled() [2/2]

void spatial_cell::SpatialCell::set_mpi_transfer_enabled ( bool transferEnabled)

◆ set_mpi_transfer_type() [1/2]

void spatial_cell::SpatialCell::set_mpi_transfer_type ( const uint64_t type,
bool atSysBoundaries = false )
inlinestatic

Sets the type of data to transfer by mpi_datatype.

Definition at line 862 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ set_mpi_transfer_type() [2/2]

void spatial_cell::SpatialCell::set_mpi_transfer_type ( const uint64_t type,
bool atSysBoundaries = false )
static

◆ set_population() [1/2]

void spatial_cell::SpatialCell::set_population ( const Population & pop,
cuint popID )
inline

Definition at line 503 of file spatial_cell_cpu.hpp.

Here is the caller graph for this function:

◆ set_population() [2/2]

void spatial_cell::SpatialCell::set_population ( const Population & pop,
cuint popID )

◆ setCommunicatedSpecies() [1/2]

bool spatial_cell::SpatialCell::setCommunicatedSpecies ( const uint popID)
static

Set the particle species SpatialCell should use in functions that use the velocity mesh.

Parameters
popIDPopulation ID.
Returns
If true, the new species is in use.

Definition at line 619 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setCommunicatedSpecies() [2/2]

bool spatial_cell::SpatialCell::setCommunicatedSpecies ( const uint popID)
static

◆ setNewSizeClear() [1/4]

void spatial_cell::SpatialCell::setNewSizeClear ( const uint popID)
inline

Definition at line 709 of file spatial_cell_cpu.hpp.

◆ setNewSizeClear() [2/4]

void spatial_cell::SpatialCell::setNewSizeClear ( const uint popID)

◆ setNewSizeClear() [3/4]

void spatial_cell::SpatialCell::setNewSizeClear ( const uint popID,
const vmesh::LocalID & newSize )
inline

Ensures the selected population vmesh localToGlobalMap has sufficient capacity and is of correct size. Does not alter its contents. Ensures the selected population vmesh globalToLocalMap has sufficient capacity and is empty. Ensures the selected population VBC has sufficient capacity and is of correct size.

Definition at line 706 of file spatial_cell_cpu.hpp.

◆ setNewSizeClear() [4/4]

void spatial_cell::SpatialCell::setNewSizeClear ( const uint popID,
const vmesh::LocalID & newSize )

◆ setReservation()

void spatial_cell::SpatialCell::setReservation ( const uint popID,
const vmesh::LocalID reservationsize,
bool force = false )

Sets a guidance counter so that vmesh adjustment vectors have sufficient size

Definition at line 324 of file spatial_cell_gpu.cpp.

Here is the caller graph for this function:

◆ shrink_to_fit() [1/2]

bool spatial_cell::SpatialCell::shrink_to_fit ( )

Purges extra capacity from block vectors. It sets size to num_blocks * block_allocation_factor (if capacity greater than this), and also forces capacity to this new smaller value.

Returns
True on success.

Definition at line 654 of file spatial_cell_cpu.cpp.

Here is the caller graph for this function:

◆ shrink_to_fit() [2/2]

bool spatial_cell::SpatialCell::shrink_to_fit ( )

◆ size() [1/2]

size_t spatial_cell::SpatialCell::size ( const uint popID) const
inline

Returns the number of existing velocity blocks.

Definition at line 668 of file spatial_cell_cpu.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ size() [2/2]

size_t spatial_cell::SpatialCell::size ( const uint popID) const

◆ update_velocity_block_content_lists() [1/2]

void spatial_cell::SpatialCell::update_velocity_block_content_lists ( const uint popID)

Update the two lists containing blocks with content, and blocks without content.

See also
adjustVelocityBlocks

Update the two lists containing blocks with content, and blocks without content. This updates lists for a single cell, unlike the batch operations.

See also
adjustVelocityBlocks

Definition at line 675 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ update_velocity_block_content_lists() [2/2]

void spatial_cell::SpatialCell::update_velocity_block_content_lists ( const uint popID)

◆ updateSparseMinValue() [1/2]

void spatial_cell::SpatialCell::updateSparseMinValue ( const uint popID)

Updates minValue based on algorithm value from parameters (see parameters.cpp).

Parameters
popIDID of the particle species.

Definition at line 699 of file spatial_cell_cpu.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateSparseMinValue() [2/2]

void spatial_cell::SpatialCell::updateSparseMinValue ( const uint popID)

Member Data Documentation

◆ activePopID

int spatial_cell::SpatialCell::activePopID = 0
staticprivate

Definition at line 390 of file spatial_cell_cpu.hpp.

◆ density_post_adjust

Real spatial_cell::SpatialCell::density_post_adjust

Definition at line 706 of file spatial_cell_gpu.hpp.

◆ density_pre_adjust

Real spatial_cell::SpatialCell::density_pre_adjust

Definition at line 706 of file spatial_cell_gpu.hpp.

◆ derivativesBVOL

std::array< Real, bvolderivatives::N_BVOL_DERIVATIVES > spatial_cell::SpatialCell::derivativesBVOL

Derivatives of BVOL needed by the acceleration. Separate array because it does not need to be communicated.

Definition at line 359 of file spatial_cell_cpu.hpp.

◆ derivativesV

std::array< Real, vderivatives::N_V_DERIVATIVES > spatial_cell::SpatialCell::derivativesV

Derivatives of V for vorticity AMR.

Definition at line 358 of file spatial_cell_cpu.hpp.

◆ dev_list_delete

split::SplitVector<Hashinator::hash_pair<vmesh::GlobalID,vmesh::LocalID> > * spatial_cell::SpatialCell::dev_list_delete =0

Definition at line 700 of file spatial_cell_gpu.hpp.

◆ dev_list_to_replace

split::SplitVector<Hashinator::hash_pair<vmesh::GlobalID,vmesh::LocalID> > * spatial_cell::SpatialCell::dev_list_to_replace =0

Definition at line 701 of file spatial_cell_gpu.hpp.

◆ dev_list_with_replace_new

split::SplitVector<vmesh::GlobalID> * spatial_cell::SpatialCell::dev_list_with_replace_new =0

Definition at line 699 of file spatial_cell_gpu.hpp.

◆ dev_list_with_replace_old

split::SplitVector<Hashinator::hash_pair<vmesh::GlobalID,vmesh::LocalID> > * spatial_cell::SpatialCell::dev_list_with_replace_old =0

Definition at line 702 of file spatial_cell_gpu.hpp.

◆ dev_velocity_block_with_content_list

split::SplitVector<vmesh::GlobalID>* spatial_cell::SpatialCell::dev_velocity_block_with_content_list =0

Device pointer to list of existing cells with content.

Definition at line 692 of file spatial_cell_gpu.hpp.

◆ dev_velocity_block_with_content_map

Hashinator::Hashmap<vmesh::GlobalID,vmesh::LocalID>* spatial_cell::SpatialCell::dev_velocity_block_with_content_map =0

Definition at line 696 of file spatial_cell_gpu.hpp.

◆ dev_velocity_block_with_no_content_map

Hashinator::Hashmap<vmesh::GlobalID,vmesh::LocalID> * spatial_cell::SpatialCell::dev_velocity_block_with_no_content_map =0

Definition at line 696 of file spatial_cell_gpu.hpp.

◆ face_neighbor_ranks

std::map< int, std::set< int > > spatial_cell::SpatialCell::face_neighbor_ranks

Definition at line 369 of file spatial_cell_cpu.hpp.

◆ gpu_rhoLossAdjust

Realf* spatial_cell::SpatialCell::gpu_rhoLossAdjust

Definition at line 705 of file spatial_cell_gpu.hpp.

◆ initialized

bool spatial_cell::SpatialCell::initialized
private

Definition at line 391 of file spatial_cell_cpu.hpp.

◆ ioLocalCellId

uint64_t spatial_cell::SpatialCell::ioLocalCellId

Local cell ID used for IO, not needed elsewhere and thus not being kept up-to-date.

Definition at line 364 of file spatial_cell_cpu.hpp.

◆ largestvmesh

uint64_t spatial_cell::SpatialCell::largestvmesh = 0

Definition at line 707 of file spatial_cell_gpu.hpp.

◆ list_delete

split::SplitVector<Hashinator::hash_pair<vmesh::GlobalID,vmesh::LocalID> >* spatial_cell::SpatialCell::list_delete =0

Definition at line 700 of file spatial_cell_gpu.hpp.

◆ list_delete_capacity

vmesh::LocalID spatial_cell::SpatialCell::list_delete_capacity =0

Definition at line 703 of file spatial_cell_gpu.hpp.

◆ list_to_replace

split::SplitVector<Hashinator::hash_pair<vmesh::GlobalID,vmesh::LocalID> >* spatial_cell::SpatialCell::list_to_replace =0

Definition at line 701 of file spatial_cell_gpu.hpp.

◆ list_to_replace_capacity

vmesh::LocalID spatial_cell::SpatialCell::list_to_replace_capacity =0

Definition at line 703 of file spatial_cell_gpu.hpp.

◆ list_with_replace_new

split::SplitVector<vmesh::GlobalID>* spatial_cell::SpatialCell::list_with_replace_new =0

Definition at line 699 of file spatial_cell_gpu.hpp.

◆ list_with_replace_new_capacity

vmesh::LocalID spatial_cell::SpatialCell::list_with_replace_new_capacity =0

Definition at line 703 of file spatial_cell_gpu.hpp.

◆ list_with_replace_old

split::SplitVector<Hashinator::hash_pair<vmesh::GlobalID,vmesh::LocalID> >* spatial_cell::SpatialCell::list_with_replace_old =0

Definition at line 702 of file spatial_cell_gpu.hpp.

◆ list_with_replace_old_capacity

vmesh::LocalID spatial_cell::SpatialCell::list_with_replace_old_capacity =0

Definition at line 703 of file spatial_cell_gpu.hpp.

◆ mpi_transfer_type

uint64_t spatial_cell::SpatialCell::mpi_transfer_type = 0
static

Which data is transferred by the mpi datatype given by spatial cells.

Definition at line 381 of file spatial_cell_cpu.hpp.

◆ mpiTransferAtSysBoundaries

bool spatial_cell::SpatialCell::mpiTransferAtSysBoundaries = false
static

Do we only transfer data at boundaries (true), or in the whole system (false).

Definition at line 382 of file spatial_cell_cpu.hpp.

◆ mpiTransferEnabled

bool spatial_cell::SpatialCell::mpiTransferEnabled
private

Definition at line 392 of file spatial_cell_cpu.hpp.

◆ neighbor_block_data

std::array< Realf *, MAX_NEIGHBORS_PER_DIM > spatial_cell::SpatialCell::neighbor_block_data

Pointers for translation operator. We can point to neighbor cell block data. We do not allocate memory for the pointer.

Definition at line 366 of file spatial_cell_cpu.hpp.

◆ neighbor_number_of_blocks

std::array< vmesh::LocalID, MAX_NEIGHBORS_PER_DIM > spatial_cell::SpatialCell::neighbor_number_of_blocks

Definition at line 368 of file spatial_cell_cpu.hpp.

◆ null_block_data

std::array< Realf, WID3 > spatial_cell::SpatialCell::null_block_data

Definition at line 362 of file spatial_cell_cpu.hpp.

◆ parameters

std::array< Real, CellParams::N_SPATIAL_CELL_PARAMS > spatial_cell::SpatialCell::parameters

Bulk variables in this spatial cell.

Definition at line 361 of file spatial_cell_cpu.hpp.

◆ populations

std::vector< spatial_cell::Population > spatial_cell::SpatialCell::populations
private

Particle population variables.

Definition at line 394 of file spatial_cell_cpu.hpp.

◆ sysBoundaryFlag

uint spatial_cell::SpatialCell::sysBoundaryFlag

What type of system boundary does the cell belong to. Enumerated in the sysboundarytype namespace's enum.

Definition at line 370 of file spatial_cell_cpu.hpp.

◆ sysBoundaryLayer

uint spatial_cell::SpatialCell::sysBoundaryLayer

Layers counted from closest systemBoundary. If 0 then it has not been computed. First sysboundary layer is layer 1.

Definition at line 372 of file spatial_cell_cpu.hpp.

◆ sysBoundaryLayerNew

int spatial_cell::SpatialCell::sysBoundaryLayerNew

Definition at line 374 of file spatial_cell_cpu.hpp.

◆ vbwcl_sizePower

vmesh::LocalID spatial_cell::SpatialCell::vbwcl_sizePower

Definition at line 697 of file spatial_cell_gpu.hpp.

◆ vbwncl_sizePower

vmesh::LocalID spatial_cell::SpatialCell::vbwncl_sizePower

Definition at line 697 of file spatial_cell_gpu.hpp.

◆ velocity_block_with_content_list [1/2]

std::vector<vmesh::GlobalID>* spatial_cell::SpatialCell::velocity_block_with_content_list

needed (by DCCRG?), do not remove. List of existing cells with content, only up-to-date after call to update_has_content().

Definition at line 375 of file spatial_cell_cpu.hpp.

◆ velocity_block_with_content_list [2/2]

split::SplitVector<vmesh::GlobalID>* spatial_cell::SpatialCell::velocity_block_with_content_list =0

needed (by DCCRG?), do not remove. List of existing cells with content (updated by update_has_content()).

Definition at line 691 of file spatial_cell_gpu.hpp.

◆ velocity_block_with_content_list_capacity

vmesh::LocalID spatial_cell::SpatialCell::velocity_block_with_content_list_capacity =0

Capacity of vector. Cached value.

Definition at line 694 of file spatial_cell_gpu.hpp.

◆ velocity_block_with_content_list_size

vmesh::LocalID spatial_cell::SpatialCell::velocity_block_with_content_list_size =0

Size of vector. Needed for MPI communication of size before actual list transfer.

Definition at line 377 of file spatial_cell_cpu.hpp.

◆ velocity_block_with_content_map

Hashinator::Hashmap<vmesh::GlobalID,vmesh::LocalID>* spatial_cell::SpatialCell::velocity_block_with_content_map =0

Definition at line 695 of file spatial_cell_gpu.hpp.

◆ velocity_block_with_no_content_list

std::vector<vmesh::GlobalID>* spatial_cell::SpatialCell::velocity_block_with_no_content_list

List of existing cells with no content, only up-to-date after call to update_has_content. This is also never transferred over MPI, so is invalid on remote cells.

Definition at line 378 of file spatial_cell_cpu.hpp.

◆ velocity_block_with_no_content_map

Hashinator::Hashmap<vmesh::GlobalID,vmesh::LocalID> * spatial_cell::SpatialCell::velocity_block_with_no_content_map =0

Definition at line 695 of file spatial_cell_gpu.hpp.


The documentation for this class was generated from the following files: