Search in sources :

Example 1 with TrainingDatasetFilterCondition

use of io.hops.hopsworks.persistence.entity.featurestore.trainingdataset.TrainingDatasetFilterCondition in project hopsworks by logicalclocks.

the class TrainingDatasetControllerTest method createTrainingDatasetFilterCondition.

public TrainingDatasetFilterCondition createTrainingDatasetFilterCondition(String feature, SqlCondition condition, String value, Integer fgId, Integer filterValueFgId) {
    TrainingDatasetFilterCondition filter = new TrainingDatasetFilterCondition();
    filter.setFeature(feature);
    filter.setCondition(condition);
    filter.setValue(value);
    Featuregroup fg = new Featuregroup();
    fg.setId(fgId);
    filter.setFeatureGroup(fgId == null ? null : fg);
    filter.setValueFeatureGroupId(filterValueFgId);
    return filter;
}
Also used : Featuregroup(io.hops.hopsworks.persistence.entity.featurestore.featuregroup.Featuregroup) TrainingDatasetFilterCondition(io.hops.hopsworks.persistence.entity.featurestore.trainingdataset.TrainingDatasetFilterCondition)

Example 2 with TrainingDatasetFilterCondition

use of io.hops.hopsworks.persistence.entity.featurestore.trainingdataset.TrainingDatasetFilterCondition in project hopsworks by logicalclocks.

the class TrainingDatasetController method makeTrainingDatasetFilter.

private TrainingDatasetFilter makeTrainingDatasetFilter(String path, TrainingDataset trainingDataset, Filter filter, SqlFilterLogic type) {
    TrainingDatasetFilter trainingDatasetFilter = new TrainingDatasetFilter(trainingDataset);
    TrainingDatasetFilterCondition condition = filter == null ? null : convertFilter(filter, trainingDatasetFilter);
    trainingDatasetFilter.setCondition(condition);
    trainingDatasetFilter.setPath(path);
    trainingDatasetFilter.setType(type);
    return trainingDatasetFilter;
}
Also used : TrainingDatasetFilter(io.hops.hopsworks.persistence.entity.featurestore.trainingdataset.TrainingDatasetFilter) TrainingDatasetFilterCondition(io.hops.hopsworks.persistence.entity.featurestore.trainingdataset.TrainingDatasetFilterCondition)

Aggregations

TrainingDatasetFilterCondition (io.hops.hopsworks.persistence.entity.featurestore.trainingdataset.TrainingDatasetFilterCondition)2 Featuregroup (io.hops.hopsworks.persistence.entity.featurestore.featuregroup.Featuregroup)1 TrainingDatasetFilter (io.hops.hopsworks.persistence.entity.featurestore.trainingdataset.TrainingDatasetFilter)1