当前位置: 首页>>代码示例>>Java>>正文


Java Object2DoubleOpenHashMap.getDouble方法代码示例

本文整理汇总了Java中it.unimi.dsi.fastutil.objects.Object2DoubleOpenHashMap.getDouble方法的典型用法代码示例。如果您正苦于以下问题:Java Object2DoubleOpenHashMap.getDouble方法的具体用法?Java Object2DoubleOpenHashMap.getDouble怎么用?Java Object2DoubleOpenHashMap.getDouble使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在it.unimi.dsi.fastutil.objects.Object2DoubleOpenHashMap的用法示例。


在下文中一共展示了Object2DoubleOpenHashMap.getDouble方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getGenericRelatedness

import it.unimi.dsi.fastutil.objects.Object2DoubleOpenHashMap; //导入方法依赖的package包/类
private double getGenericRelatedness(int wid1, int wid2, Object2DoubleOpenHashMap<Pair<Integer,Integer>> cache, String url){
	if (wid2 < wid1) {
		int tmp = wid2;
		wid2 = wid1;
		wid2 = tmp;
	}
	Pair <Integer,Integer> p = new Pair<Integer,Integer>(wid1,wid2);
	if (!cache.containsKey(p))
		cache.put(p, queryJsonRel(wid1, wid2, url));
		
	return cache.getDouble(p);
}
 
开发者ID:marcocor,项目名称:smaph,代码行数:13,代码来源:WATRelatednessComputer.java

示例2: interestingRules

import it.unimi.dsi.fastutil.objects.Object2DoubleOpenHashMap; //导入方法依赖的package包/类
public List<AssociationRule> interestingRules(double confidenceThreshold,
                                              double interestThreshold,
                                              Object2DoubleOpenHashMap<IntRBTreeSet> confidenceMap) {
    List<AssociationRule> rules = model.learn(confidenceThreshold);
    for (AssociationRule rule : rules) {
        double interest = rule.confidence - confidenceMap.getDouble(rule.consequent);
        if (Math.abs(interest) < interestThreshold) {
            rules.remove(rule);
        }
    }
    return rules;
}
 
开发者ID:jtablesaw,项目名称:tablesaw,代码行数:13,代码来源:AssociationRuleMining.java

示例3: getItemAspectModel

import it.unimi.dsi.fastutil.objects.Object2DoubleOpenHashMap; //导入方法依赖的package包/类
@Override
public ItemAspectModel<I, F> getItemAspectModel(List<Tuple2od<I>> items) {
    Object2DoubleOpenHashMap<F> probNorm = new Object2DoubleOpenHashMap<>();
    items.forEach(iv -> getItemIntents(iv.v1).forEach(f -> probNorm.addTo(f, iv.v2)));

    return (iv, f) -> iv.v2 / probNorm.getDouble(f);
}
 
开发者ID:RankSys,项目名称:RankSys,代码行数:8,代码来源:ScoresAspectModel.java


注:本文中的it.unimi.dsi.fastutil.objects.Object2DoubleOpenHashMap.getDouble方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。