'Add the dot product of m1 and m2 to the matrix.'

def add_dot(self, m1, m2, mult=1.0):

    err_code = _cudamat.dot(m1.p_mat, m2.p_mat, self.p_mat, ct.c_float(1.0), ct.c_float(mult))
    if err_code:
        raise generate_exception(err_code)
    return self
