本文整理汇总了Java中org.dmg.pmml.Model.getOutput方法的典型用法代码示例。如果您正苦于以下问题:Java Model.getOutput方法的具体用法?Java Model.getOutput怎么用?Java Model.getOutput使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.dmg.pmml.Model
的用法示例。
在下文中一共展示了Model.getOutput方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getActiveFields
import org.dmg.pmml.Model; //导入方法依赖的package包/类
static
public Set<Field> getActiveFields(DeepFieldResolver resolver, Model model){
Set<Field> modelFields = getModelFields(resolver, model);
FieldReferenceFinder fieldReferenceFinder = new FieldReferenceFinder(){
@Override
public VisitorAction visit(LocalTransformations localTransformations){
return VisitorAction.SKIP;
}
};
fieldReferenceFinder.applyTo(model);
Set<Field> activeFields = FieldUtil.selectAll(modelFields, fieldReferenceFinder.getFieldNames());
Output output = model.getOutput();
if(output != null){
activeFields.removeAll(output.getOutputFields());
}
return activeFields;
}
示例2: apply
import org.dmg.pmml.Model; //导入方法依赖的package包/类
@Override
public Feature apply(Model model){
Output output = model.getOutput();
if(output == null || !output.hasOutputFields()){
throw new IllegalArgumentException();
}
OutputField outputField = Iterables.getLast(output.getOutputFields());
return new ContinuousFeature(null, outputField.getName(), outputField.getDataType());
}
示例3: apply
import org.dmg.pmml.Model; //导入方法依赖的package包/类
@Override
public Feature apply(Model model){
Output output = model.getOutput();
if(output == null || !output.hasOutputFields()){
throw new IllegalArgumentException();
}
OutputField outputField = Iterables.getLast(output.getOutputFields());
return new ContinuousFeature(null, outputField.getName(), outputField.getDataType());
}
示例4: getEarlierOutputs
import org.dmg.pmml.Model; //导入方法依赖的package包/类
static
private List<Output> getEarlierOutputs(Segmentation segmentation, Segment targetSegment){
List<Output> result = new ArrayList<>();
Segmentation.MultipleModelMethod multipleModelMethod = segmentation.getMultipleModelMethod();
switch(multipleModelMethod){
case MODEL_CHAIN:
break;
default:
return Collections.emptyList();
}
List<Segment> segments = segmentation.getSegments();
for(Segment segment : segments){
Model model = segment.getModel();
if(targetSegment != null && (targetSegment).equals(segment)){
break;
}
Output output = model.getOutput();
if(output != null){
result.add(output);
}
}
return result;
}
示例5: getModelFields
import org.dmg.pmml.Model; //导入方法依赖的package包/类
static
private Set<Field> getModelFields(DeepFieldResolver resolver, Model model){
Output output = model.getOutput();
if(output != null && output.hasOutputFields()){
return resolver.getFields(model, output);
} else
{
return resolver.getFields(model);
}
}