public final int[] hashSignature(final int[] signature){
  int[] hash=new int[stages];
  int rows=signature.length / stages;
  for (int i=0; i < signature.length; i++) {
    int stage=Math.min(i / rows,stages - 1);
    hash[stage]=(int)((hash[stage] + (long)signature[i] * LARGE_PRIME) % buckets);
  }
  return hash;
}

public final int [ ] hashSignature ( final int [ ] signature ) { int [ ] hash = new int [ stages ] ; int rows = signature . length / stages ; for ( int i = 0 ; i < signature . length ; i ++ ) { int stage = Math . min ( i / rows , stages - 1 ) ; hash [ stage ] = ( int ) ( ( hash [ stage ] + ( long ) signature [ i ] * LARGE_PRIME ) % buckets ) ; } return hash ; }
hash a signature . the signature is divided in s stages ( or bands ) . each stage is hashed to one of the b buckets .
