Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The MinHasher execution depends by the number of nodes #634

Open
Gaglia88 opened this issue Jun 6, 2017 · 1 comment
Open

The MinHasher execution depends by the number of nodes #634

Gaglia88 opened this issue Jun 6, 2017 · 1 comment

Comments

@Gaglia88
Copy link

Gaglia88 commented Jun 6, 2017

Hi,
I am using the Minhasher32 to create clusters of similar records, tokenizing the records values to create the signatures (as I explained here #609), but seems that the resulting buckets depends by the Spark configuration.
I executed the same code on a single node of a cluster machine with 16 cores more times and I always obtained X number of buckets. Than on the same machine I aumented the number of cores to 20, and the number of buckets it is changed to another number Y, I repeated the test and I obtained Y again.

It is possible that the execution of the MinHasher is influenced by the number of nodes? Someone it is able to explain me why?

Thanks

Regards
Luca

@Gaglia88
Copy link
Author

Gaglia88 commented Jun 6, 2017

I confirm that the bucket generation depends by the level of Spark parallelism.
I made a test on my laptop, repartitioning the token before initializing the MinHasher

val attributeWithHashes: RDD[(String, Iterable[MinHashSignature])] = attributesToken.repartition(10).map {
   case (attribute, token) =>
      (attribute, minHasher.init(token))
}.groupByKey()

At the same level of repartition I always obtains the same buckets, if I change it, I obtain different buckets.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant