7#include "CLUEstering/core/detail/defines.hpp"
8#include "CLUEstering/data_structures/internal/PointsCommon.hpp"
9#include "CLUEstering/detail/concepts.hpp"
10#include "CLUEstering/internal/alpaka/memory.hpp"
15#include <alpaka/alpaka.hpp>
19 namespace concepts = detail::concepts;
26 template <u
int8_t Ndim, concepts::device TDev = clue::Device>
33 template <concepts::queue TQueue>
41 template <concepts::queue TQueue>
42 PointsDevice(TQueue& queue, int32_t n_points, std::span<std::byte> buffer);
49 template <concepts::queue TQueue, concepts::contiguous_raw_data... TBuffers>
50 requires(
sizeof...(TBuffers) == 2 ||
sizeof...(TBuffers) == 4)
51 PointsDevice(TQueue& queue, int32_t n_points, TBuffers... buffers);
62 ALPAKA_FN_HOST_ACC int32_t
size()
const;
68 ALPAKA_FN_HOST
auto coords(
size_t dim)
const;
73 ALPAKA_FN_HOST
auto coords(
size_t dim);
87 ALPAKA_FN_HOST
auto rho()
const;
91 ALPAKA_FN_HOST
auto rho();
93 ALPAKA_FN_HOST
auto delta()
const;
94 ALPAKA_FN_HOST
auto delta();
96 ALPAKA_FN_HOST
auto nearestHigher()
const;
97 ALPAKA_FN_HOST
auto nearestHigher();
99 ALPAKA_FN_HOST
auto clusterIndex()
const;
100 ALPAKA_FN_HOST
auto clusterIndex();
102 ALPAKA_FN_HOST
auto isSeed()
const;
103 ALPAKA_FN_HOST
auto isSeed();
105 ALPAKA_FN_HOST
const PointsView* view()
const;
106 ALPAKA_FN_HOST PointsView* view();
109 template <concepts::queue _TQueue, u
int8_t _Ndim, concepts::device _TDev>
110 friend void copyToHost(_TQueue& queue,
113 template <concepts::queue _TQueue, u
int8_t _Ndim, concepts::device _TDev>
114 friend void copyToDevice(_TQueue& queue,
119 device_buffer<TDev, std::byte[]> m_buffer;
120 device_buffer<TDev, PointsView> m_view;
121 host_buffer<PointsView> m_hostView;
127#include "CLUEstering/data_structures/detail/PointsDevice.hpp"
PointsDevice(TQueue &queue, int32_t n_points, std::span< std::byte > buffer)
Construct a PointsDevice object with a pre-allocated buffer.
PointsDevice(TQueue &queue, int32_t n_points, TBuffers... buffers)
Construct a PointsDevice object with a pre-allocated buffer.
ALPAKA_FN_HOST auto rho()
Get the weighted density values of all the points.
ALPAKA_FN_HOST auto weight()
Get the weights of all the points.
ALPAKA_FN_HOST auto weight() const
Get the weights of all the points.
ALPAKA_FN_HOST auto rho() const
Get the weighted density values of all the points.
ALPAKA_FN_HOST auto coords(size_t dim)
Get the coordinates for a specific dimension.
ALPAKA_FN_HOST_ACC int32_t size() const
Get the size of the points.
ALPAKA_FN_HOST auto coords(size_t dim) const
Get the coordinates for a specific dimension.
PointsDevice(TQueue &queue, int32_t n_points)
Construct a PointsDevice object.
The PointsHost class is a data structure that manages points in host memory. It provides methods to a...
Definition PointsHost.hpp:24