-
Notifications
You must be signed in to change notification settings - Fork 228
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
Merge implementation of MergingDigest #200
Comments
rnataf
changed the title
Question regarding the implemetation
Merge implementation of MergingDigest
Sep 14, 2022
Normally what prevents this is the scale invariant.
Each of the current scale functions K0 through K3 has an associated proof
that simple merging then centroids of two digests that have the invariant
will result in a digest that satisfies the invariant. Further, there is a
proof that fully merging any digest that meets the invariant will have a
well bounded size.
If you multiply the weights, then you very likely wind up with a digest
that doesn't meet the invariant and that means that all bets are off.
…On Wed, Sep 14, 2022 at 5:18 AM rnataf ***@***.***> wrote:
Hi, I have a question about the implementation of the merge function of
MergingDigest. private void merge(double[] incomingMean, double[]
incomingWeight, int incomingCount, List<List<Double>> incomingData, int[]
incomingOrder, double unmergedWeight, boolean runBackwards, double
compression). In the loop for (int i = 1; i < incomingCount; i++) , what
prevents the variable lastUsedCell not to increase too much, leading to
an illegal access to the array weight[lastUsedCell]. I'm asking because I
did a small modification to the code (multiplying weights by a constant
before continuing adding data, to the object) and it caused lastUsedCell to
have a bigger value than weight.length.
—
Reply to this email directly, view it on GitHub
<#200>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAB5E6V2JK2MNN4ISFS2ADLV6G7CFANCNFSM6AAAAAAQMLO4SM>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Okay, thank you for your answer. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, I have a question about the implementation of the merge function of MergingDigest:
private void merge(double[] incomingMean, double[] incomingWeight, int incomingCount, List<List<Double>> incomingData, int[] incomingOrder, double unmergedWeight, boolean runBackwards, double compression)
. In the loopfor (int i = 1; i < incomingCount; i++)
, what prevents the variablelastUsedCell
not to increase too much, leading to an illegal access to the arrayweight[lastUsedCell]
?I'm asking because I did a small modification to the code (multiplying weights by a constant before continuing adding data, to the object) and it caused
lastUsedCell
to have a bigger value than weight.length.The text was updated successfully, but these errors were encountered: