Added commented lines on weights function

To work on the implementation of the weights function please comment line 10, un-comment line 9 and uncomment lines 107-114.