Hello Babak,

Thanks for pointing out these errors. I remember making changes to the
hello world examples when I first started as well. I suggest making a pull
request with your updated files (as you noted) so that the next developer
does not get confused with the same bugs. Here is the website for
contribution guidelines:
https://cwiki.apache.org/confluence/display/MADLIB/Contribution+Guidelines
Since you are interested in contributing to MADlib, I would suggest
checking the following link as well for contribution ideas.
https://cwiki.apache.org/confluence/display/MADLIB/Ideas+for+Contribution

Best Regards,

Orhan Kislal


On Thu, Feb 18, 2016 at 6:34 PM, Babak Alipour <[email protected]>
wrote:

> Greetings everyone,
>
> I am Babak Alipour, a student at University of Florida. I have been trying
> to use MADlib and I hope to contribute to the community later on.
>
> While trying to go through the quick start guide for developers (available
> here :
>
> https://cwiki.apache.org/confluence/display/MADLIB/Quick+Start+Guide+for+Developers
> ),
> I realized that in avg_var.cpp there are some lines that use 'this.member'.
> I think 'this' is a pointer and it should be used with '->'.
> So I tried to build MADlib from source with these files added, and it
> doesn't.
> It produces multiple compile-time errors:
> E.g. ' error: request for member ‘avg’ in ‘this’, which is of pointer type
> ...'
>
> Replacing every 'this.'  with 'this->' takes care of those errors but there
> are still a few more errors in the given example.
>
> Line 53:
> double a = static_cast<double>(state.numRows) / normalizer;
> Produces an error, since 'state' is not defined in this scope. Since this
> function is overloading '+=', I think it's safe to say this was supposed to
> be the state of 'this', so I replaced it with 'this->' and that error went
> away.
>
> Lines 44 & 45:
> template <class OtherHandle>
> AvgVarTransitionState &operator+=(const double x){
>
> This was also producing compile errors. (failed to deduce OtherHandle
> template type) This takes a double and adds it to the state, so I don't see
> any uses for 'OtherHandle' in this context and I commented line 44.
>
> All said and done, MADlib now compiles, installs and works just fine.
>
> I was wondering if anyone else encountered these issues while going through
> the hello world example.
>
> I could fork the project, fix the example and submit a pull-request if you
> think that's the way to go.
>
>
> Best regards,
> *Babak Alipour ,*
> *University of Florida*
>

Reply via email to