public static float compare ( final int numOfBits , final byte [ ] data1 , final byte [ ] data2 ) { if ( data1 . length != data2 . length ) { return 0 ; } final int count = countSameBits ( data1 , data2 ) ; return ( float ) count / ( float ) numOfBits ; }
Compare bytes for MinHash .