我正在尝试使用此功能,但遇到了一些错误。我将使用此功能从 FastICA 实现实时检测来自 Android 相机的 RGB 图像的峰值。我正在使用Double[] Green = ArrayUtils.toObject(arrayGreen);FastICA 的第一个参数输出工作正常。我正在使用double delta=10;第二个参数并且很好。我在使用第三个参数时遇到问题,因为我不明白哪个是我需要的第三个参数。我试图创建一个List<Integer> indices = new ArrayList<Integer>();但没有工作。有人可以帮我吗?提前致谢
我正在尝试的代码:
import java.util.ArrayList;
import java.util.List;
import java.util.HashMap;
import java.util.Map;
public abstract class CustomUtils {
/**
* Detects peaks (calculates local minima and maxima) in the
* vector <code>values</code>. The resulting list contains
* maxima at the first position and minima at the last one.
*
* Maxima and minima maps contain the indice value for a
* given position and the value from a corresponding vector.
*
* A point is considered a maximum peak if it has the maximal
* value, and was preceded (to the left) by a value lower by
* <code>delta</code>.
*
* @param values Vector of values for whom the peaks should be detected
* @param delta The precedor of a maximum peak
* @param indices Vector of indices that replace positions in resulting maps
* @return List of maps (maxima and minima pairs) of detected peaks
*/
编辑 使用第二个函数到第一个我遇到这个错误:
慕莱坞森
相关分类