/// <summary> /// Set the SVM detector /// </summary> /// <param name="detector">The SVM detector</param> public void SetSVMDetector(float[] detector) { using (VectorOfFloat vec = new VectorOfFloat()) { vec.Push(detector); GpuInvoke.gpuHOGSetSVMDetector(_ptr, vec); } }
/// <summary> /// Set the SVM detector /// </summary> /// <param name="detector">The SVM detector</param> public void SetSVMDetector(float[] detector) { using (VectorOfFloat vec = new VectorOfFloat()) { vec.Push(detector); CvInvoke.CvHOGSetSVMDetector(_ptr, vec); } }
/// <summary> /// Set the SVM detector /// </summary> /// <param name="detector">The SVM detector</param> public void SetSVMDetector(float[] detector) { _vector.Clear(); _vector.Push(detector); gpuHOGSetSVMDetector(_ptr, _vector); }
public void Test_VectorOfFloat() { VectorOfFloat vf = new VectorOfFloat(); float[] values = new float[20]; for (int i = 0; i < values.Length; i++) values[i] = i; vf.Push(values); float[] valuesCopy = vf.ToArray(); for (int i = 0; i < values.Length; i++) EmguAssert.AreEqual(values[i], valuesCopy[i]); }