floyd
2022 年12 月 1 日 12:04
1
在Jaccard算法中,有一个配置参数tol。这个值的作用是什么?假如该值设置为0.5,是否表示算法计算结果都是相似度在0.5以上的数据?
wey
2022 年12 月 1 日 12:05
2
是 approxSimilarityJoin 中的 threshold
def approxSimilarityJoin(
datasetA: Dataset[_],
datasetB: Dataset[_],
threshold: Double,
distCol: String): Dataset[_] = {
...
// Filter the joined datasets where the distance are smaller than the threshold.
joinedDatasetWithDist.filter(col(distCol) < threshold)
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.spark.ml.feature
import org.apache.spark.ml.{Estimator, Model}
This file has been truncated. show original
我刚好在之前问过自己这个问题,写到了文章里
3 个赞
system
关闭
2022 年12 月 31 日 12:06
3
此话题已在最后回复的 30 天后被自动关闭。不再允许新回复。