public class ContextTrainingExampleData
extends java.lang.Object
TrainingExample
data to be stored in the
contextual ego network's contexts.
It is indented to be used as a dynamically created instance on contexts (which are cross module components)
by calling context.getOrCreateInstance(GNNNodeData.class)
to either retrieve of create it.Modifier and Type | Field | Description |
---|---|---|
mklab.JGNN.core.Tensor |
transformToDstEmbedding |
|
mklab.JGNN.core.Tensor |
transformToSrcEmbedding |
Constructor | Description |
---|---|
ContextTrainingExampleData() |
Modifier and Type | Method | Description |
---|---|---|
void |
addTrainingExample(TrainingExample example) |
|
void |
degrade(double factor,
double removalThreshold) |
Calls the
TrainingExample.degrade(double) operation for each TrainingExample in the
data (e.g. |
java.util.ArrayList<TrainingExample> |
getTrainingExampleList() |
Grants direct access to a list of training examples to traverse or edit.
|
public mklab.JGNN.core.Tensor transformToSrcEmbedding
public mklab.JGNN.core.Tensor transformToDstEmbedding
public void addTrainingExample(TrainingExample example)
public java.util.ArrayList<TrainingExample> getTrainingExampleList()
public void degrade(double factor, double removalThreshold)
TrainingExample.degrade(double)
operation for each TrainingExample
in the
data (e.g. to reduce all weights) and removes those that end up on a very small weight.factor
- The degrading factor passed on to the degrade operation.removalThreshold
- The threshold weight under which training examples are removed.TrainingExample.getWeight()