Graphite
0.5.0
GPU-accelerated graph optimization framework
Loading...
Searching...
No Matches
block.hpp
Go to the documentation of this file.
1
2
#pragma once
3
#include <boost/container_hash/hash.hpp>
4
5
namespace
graphite
{
6
class
BlockCoordinates
{
7
public
:
8
size_t
row;
9
size_t
col;
10
11
__host__ __device__
bool
operator==(
const
BlockCoordinates
&other)
const
{
12
return
(row == other.row) && (col == other.col);
13
}
14
};
15
16
using
BlockDimension
=
BlockCoordinates
;
17
}
// namespace graphite
18
19
namespace
std {
20
template
<>
struct
hash<
graphite
::BlockCoordinates> {
21
size_t
operator()(
const
graphite::BlockCoordinates
&bc)
const
{
22
size_t
seed = 0;
23
boost::hash_combine(seed, bc.row);
24
boost::hash_combine(seed, bc.col);
25
return
seed;
26
}
27
};
28
}
// namespace std
graphite::BlockCoordinates
Definition
block.hpp:6
graphite
The top-level namespace for Graphite.
Definition
eigen_solver.cpp:4
include
graphite
block.hpp
Generated by Doxygen
1.9.8