-
Notifications
You must be signed in to change notification settings - Fork 35
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
Feature to weigh samples differently #87
Comments
I agree this is something we also considered at some point. It would not be too difficult to code it for maximum likelihood. Do you dare to do it? :) I could help you out. ;) |
I can do it for MLE. Can you help? I already made some changes to the sampler. |
Yes, sure! Let me think a bit which would be a simple design. But a first question, do you want to provide specific weights for each instance as an extra attribute in your data set? |
Yes, another column with the weights in the ARFF file might be good. |
Hi, I've been thinking how to do it. I detail my proposal a) Modify Attributes class to include "WEIGHT" as a special attribute name like "TIME_ID" and "SEQUENCE_ID". When an attribute has this specific name, it will be recognized by AMIDST and will be used to weight the instances when learning. b) Within "core" module, create a new java class in the learning parametric package (e.g. ParalelMLWeighted). This class should inherit from ParallelMaximulLikelihood. Overwrite the method "double updateModel(DataOnMemory batch)" to account for the weights of the instances. Weight of the instances can be accessed through the special methods created at point (a). c) Within "core-dynamic" module, create a new java class in the learning parametric package (e.g. ParalelMLWeighted). This class should inherit from ParallelMaximulLikelihood and be based on its counterpart static version created at point b). I recommend you performing independent pull-requests for each one of these steps. |
Will work on this in 2 weeks when we have to scale up. |
It would be useful to weight different samples differently. I have to under sample parts of the data because they occur too often. It will be good to just give them more weight rather than have the raw data in the file.
The text was updated successfully, but these errors were encountered: