Commit dfe4a54f authored by Kalinga Bhusan Ray's avatar Kalinga Bhusan Ray
Browse files

with IO complex udf

parent 95941259
......@@ -54,15 +54,14 @@ bool udf(int a, std::vector<boost::any> outVec) {
// Filter all incoming tuples (i) if tuple is less than gloabl minimum OR
// (ii) if tuple is 10 % more than global max OR
// (iii)if tuple is 30 % more than running avg
//if ((boost::any_cast<int>(outVec[0]) < a) || max_diff_perc > 10 || avg_diff_perc > 30) {
if ((boost::any_cast<int>(outVec[0]) < a) || max_diff_perc > 10 || avg_diff_perc > 30) {
//cout <<"\n Process data: "<< a << endl;
// return true;
//}
//else {
return true;
}
else {
//cout <<"\n Filter data: "<< a << endl;
// return false;
//}
return (a%2 == 0);
return false;
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment