Effectively the problem was the uint32 was overflowing when calculating the buffer size: (d*(d-1))/2 ) with d~500000
A mistake I do constantly :D
Thanks for the replies!
Type: Posts; User: Fede
Effectively the problem was the uint32 was overflowing when calculating the buffer size: (d*(d-1))/2 ) with d~500000
A mistake I do constantly :D
Thanks for the replies!
Thanks for the replies.
I don't care about not recovering from the exception but I would like to have warnings printed to std::cerr. The implementation would be to include the try block...
Hi!
I am dealing with a problem in which I have to allocate a huge distance matrix (~600 GB on a cluster node). In order to save some memory, since the matrix is symmetric, I defined an upper...
The binary file is data generated by a colleague with a pre-defined format: raw array of NormalizedPair.
It was not clear in my first post but I am actually using a std::vector<NormalizedPair>. The...
Hi,
I am having a hard time finding the cleanest solution for the following problem.
I want to read a binary file into an std::vector.
Checking online I found the following solution:
ifstream...
I found out what the error was. It was actually a rounding error that the .txt file didn't show because it was truncating the results.
So, as usual, it was 100% my mistake :D.
In any case thanks!
The MatchedPair is a struct:
struct MatchedPair
{
uint32_t ID2;
double distance;
MatchedPair(): ID2(0), distance(0) {}
MatchedPair(uint32_t id2, double d): ID2(id2),...
Hi,
I have a code that outputs the content of an array of std::maps in binary format.
auto outfile = std::fstream(output, std::ios::out | std::ios::binary);
MatchedPair tmp;
for (int i = 0;...
As soon as I have time I'll make a version of the threaded code using gnu pthread library and post it here just in case it is useful for someone.
Once again thanks for all the really useful...
First of all thanks for sharing your code and knowledge, it's been a huge help for me.
I ran some tests using 107 unsigned 32 bit integers and your serial code outperforms bash sort parallel...
Hi,
I need some help with implementing a Radix Sort Algorithm. I found a related thread posted by @rcgldr (don't know how to @user) that although really useful it is now closed.
My question is if...