public class SWIGTrainData extends Object implements AutoCloseable
| Modifier and Type | Field and Description |
|---|---|
boolean |
fairnessConstrained
Whether the LightGBM model is fairness constrained (aka FairGBM).
|
int |
numFeatures
Number of features per instance.
|
| Constructor and Description |
|---|
SWIGTrainData(int numFeatures,
long numInstancesChunk)
Constructor.
|
SWIGTrainData(int numFeatures,
long numInstancesChunk,
boolean fairnessConstrained)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addConstraintGroupValue(int value)
Adds a value to the constraint group ChunkedArray.
|
void |
addFeatureValue(double value)
Adds a value to the features' ChunkedArray.
|
void |
addLabelValue(float value)
Adds a value to the labels' ChunkedArray.
|
void |
close()
Release any allocated resources.
|
long |
getNumInstancesChunk() |
public final int numFeatures
public final boolean fairnessConstrained
public SWIGTrainData(int numFeatures,
long numInstancesChunk)
numFeatures - The number of features.numInstancesChunk - The number of instances per chunk of data.initSwigDatasetHandle()public SWIGTrainData(int numFeatures,
long numInstancesChunk,
boolean fairnessConstrained)
numFeatures - The number of features.numInstancesChunk - The number of instances per chunk of data.fairnessConstrained - Whether this data will be used for a model with fairness (group) constraints.public void addFeatureValue(double value)
value - value to insert.public void addLabelValue(float value)
public void addConstraintGroupValue(int value)
value - the value to add.public long getNumInstancesChunk()
public void close()
close in interface AutoCloseableCopyright © 2022 Feedzai. All rights reserved.