use InputArray instead of vector<float>