[SPARK-2091][MLLIB] use numpy.dot instead of ndarray.dot

`ndarray.dot` is not available in numpy 1.4. This PR makes pyspark/mllib compatible with numpy 1.4.