Loading...
Searching...
No Matches
PLMD::metatomic::vesin::cuda Namespace Reference

Classes

struct  CellListBuffers
 Buffers for cell list-based neighbor search. More...
 
struct  CudaNeighborListExtras
 

Functions

void free_neighbors (VesinNeighborList &neighbors)
 Frees GPU memory associated with a VesinNeighborList.
 
CudaNeighborListExtrasget_cuda_extras (VesinNeighborList *neighbors)
 Get the CudaNeighborListExtras stored inside VesinNeighborList's opaque pointer.
 
void neighbors (const double(*points)[3], size_t n_points, const double box[3][3], const bool periodic[3], VesinOptions options, VesinNeighborList &neighbors)
 Computes the neighbor list on the GPU.
 

Function Documentation

◆ free_neighbors()

void PLMD::metatomic::vesin::cuda::free_neighbors ( VesinNeighborList & neighbors)

Frees GPU memory associated with a VesinNeighborList.

This function should be called to release all CUDA-allocated memory tied to the given neighbor list. It does not delete the structure itself, only the device-side memory buffers.

Parameters
neighborsReference to the VesinNeighborList to clean up.

◆ get_cuda_extras()

CudaNeighborListExtras * PLMD::metatomic::vesin::cuda::get_cuda_extras ( VesinNeighborList * neighbors)

Get the CudaNeighborListExtras stored inside VesinNeighborList's opaque pointer.

◆ neighbors()

void PLMD::metatomic::vesin::cuda::neighbors ( const double(*) points[3],
size_t n_points,
const double box[3][3],
const bool periodic[3],
VesinOptions options,
VesinNeighborList & neighbors )

Computes the neighbor list on the GPU.

This function only works under Minimum Image Convention for now.

This function generates a neighbor list for a set of points within a periodic simulation box using GPU acceleration. The output is stored in a VesinNeighborList structure, which must be initialized for GPU usage.

Parameters
pointsPointer to an array of 3D points (shape: [n_points][3]).
n_pointsNumber of points (atoms, particles, etc.).
box3×3 matrix defining the bounding box of the system.
periodicArray of three booleans indicating periodicity in each dimension.
optionsStruct holding parameters such as cutoff, symmetry, etc.
neighborsOutput neighbor list (device memory will be allocated as needed).