Use 64 bits instead of 32 bits
This commit is contained in:
parent
a16ae60382
commit
b01543a02a
@ -108,7 +108,7 @@ int main(int argc, char **argv)
|
||||
H5::H5File in_f(fname1, 0);
|
||||
H5::H5File out_f("fields.h5", H5F_ACC_TRUNC);
|
||||
array_type v1_data;
|
||||
uint32_t N1_points, N2_points;
|
||||
uint64_t N1_points, N2_points;
|
||||
|
||||
array3_type bins(boost::extents[Nres][Nres][Nres]);
|
||||
|
||||
@ -124,12 +124,12 @@ int main(int argc, char **argv)
|
||||
MyCell *allCells_1 = new MyCell[N1_points];
|
||||
|
||||
#pragma omp parallel for schedule(static)
|
||||
for (long i = 0; i < Nres*Nres*Nres; i++)
|
||||
for (uint32_t i = 0; i < Nres*Nres*Nres; i++)
|
||||
bins.data()[i] = 0;
|
||||
|
||||
cout << "Shuffling data in cells..." << endl;
|
||||
#pragma omp parallel for schedule(static)
|
||||
for (int i = 0 ; i < N1_points; i++)
|
||||
for (uint64_t i = 0 ; i < N1_points; i++)
|
||||
{
|
||||
for (int j = 0; j < 3; j++)
|
||||
allCells_1[i].coord[j] = v1_data[i][j];
|
||||
|
@ -99,8 +99,8 @@ namespace CosmoTool {
|
||||
typename KDDef<N,CType>::CoordType r, r2;
|
||||
KDCell<N, ValType,CType> **cells;
|
||||
typename KDDef<N,CType>::CoordType *distances;
|
||||
uint32_t currentRank;
|
||||
uint32_t numCells;
|
||||
uint64_t currentRank;
|
||||
uint64_t numCells;
|
||||
};
|
||||
|
||||
|
||||
@ -114,7 +114,7 @@ namespace CosmoTool {
|
||||
|
||||
RecursionMultipleInfo(const typename KDDef<N,CType>::KDCoordinates& rx,
|
||||
KDCell<N,ValType,CType> **cells,
|
||||
uint32_t numCells)
|
||||
uint64_t numCells)
|
||||
: queue(cells, numCells, INFINITY),traversed(0)
|
||||
{
|
||||
std::copy(rx, rx+N, x);
|
||||
@ -153,20 +153,20 @@ namespace CosmoTool {
|
||||
std::copy(replicate, replicate+N, this->replicate);
|
||||
}
|
||||
|
||||
uint32_t getIntersection(const coords& x, CoordType r,
|
||||
uint64_t getIntersection(const coords& x, CoordType r,
|
||||
Cell **cells,
|
||||
uint32_t numCells);
|
||||
uint32_t getIntersection(const coords& x, CoordType r,
|
||||
uint64_t numCells);
|
||||
uint64_t getIntersection(const coords& x, CoordType r,
|
||||
Cell **cells,
|
||||
CoordType *distances,
|
||||
uint32_t numCells);
|
||||
uint32_t countCells(const coords& x, CoordType r);
|
||||
uint64_t numCells);
|
||||
uint64_t countCells(const coords& x, CoordType r);
|
||||
|
||||
Cell *getNearestNeighbour(const coords& x);
|
||||
|
||||
void getNearestNeighbours(const coords& x, uint32_t NumCells,
|
||||
void getNearestNeighbours(const coords& x, uint64_t NumCells,
|
||||
Cell **cells);
|
||||
void getNearestNeighbours(const coords& x, uint32_t NumCells,
|
||||
void getNearestNeighbours(const coords& x, uint64_t NumCells,
|
||||
Cell **cells,
|
||||
CoordType *distances);
|
||||
|
||||
|
@ -80,9 +80,9 @@ namespace CosmoTool {
|
||||
}
|
||||
|
||||
template<int N, typename ValType, typename CType, typename CellSplitter>
|
||||
uint32_t KDTree<N,ValType,CType,CellSplitter>::getIntersection(const coords& x, CoordType r,
|
||||
uint64_t KDTree<N,ValType,CType,CellSplitter>::getIntersection(const coords& x, CoordType r,
|
||||
KDTree<N,ValType,CType,CellSplitter>::Cell **cells,
|
||||
uint32_t numCells)
|
||||
uint64_t numCells)
|
||||
{
|
||||
RecursionInfoCells<N,ValType,CType> info;
|
||||
|
||||
@ -112,10 +112,10 @@ namespace CosmoTool {
|
||||
}
|
||||
|
||||
template<int N, typename ValType, typename CType, typename CellSplitter>
|
||||
uint32_t KDTree<N,ValType,CType,CellSplitter>::getIntersection(const coords& x, CoordType r,
|
||||
uint64_t KDTree<N,ValType,CType,CellSplitter>::getIntersection(const coords& x, CoordType r,
|
||||
Cell **cells,
|
||||
CoordType *distances,
|
||||
uint32_t numCells)
|
||||
uint64_t numCells)
|
||||
{
|
||||
RecursionInfoCells<N,ValType> info;
|
||||
|
||||
@ -144,7 +144,7 @@ namespace CosmoTool {
|
||||
}
|
||||
|
||||
template<int N, typename ValType, typename CType, typename CellSplitter>
|
||||
uint32_t KDTree<N,ValType,CType,CellSplitter>::countCells(const coords& x, CoordType r)
|
||||
uint64_t KDTree<N,ValType,CType,CellSplitter>::countCells(const coords& x, CoordType r)
|
||||
{
|
||||
RecursionInfoCells<N,ValType> info;
|
||||
|
||||
@ -501,7 +501,7 @@ namespace CosmoTool {
|
||||
}
|
||||
|
||||
template<int N, typename ValType, typename CType, typename CellSplitter>
|
||||
void KDTree<N,ValType,CType,CellSplitter>::getNearestNeighbours(const coords& x, uint32_t N2,
|
||||
void KDTree<N,ValType,CType,CellSplitter>::getNearestNeighbours(const coords& x, uint64_t N2,
|
||||
Cell **cells)
|
||||
{
|
||||
RecursionMultipleInfo<N,ValType> info(x, cells, N2);
|
||||
@ -527,7 +527,7 @@ namespace CosmoTool {
|
||||
}
|
||||
|
||||
template<int N, typename ValType, typename CType, typename CellSplitter>
|
||||
void KDTree<N,ValType,CType,CellSplitter>::getNearestNeighbours(const coords& x, uint32_t N2,
|
||||
void KDTree<N,ValType,CType,CellSplitter>::getNearestNeighbours(const coords& x, uint64_t N2,
|
||||
Cell **cells,
|
||||
CoordType *distances)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user