Package org.datavec.api.io.labels
Class ParentPathLabelGenerator
- java.lang.Object
-
- org.datavec.api.io.labels.ParentPathLabelGenerator
-
- All Implemented Interfaces:
Serializable,PathLabelGenerator
public class ParentPathLabelGenerator extends Object implements PathLabelGenerator
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ParentPathLabelGenerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description WritablegetLabelForPath(String path)WritablegetLabelForPath(URI uri)booleaninferLabelClasses()If true: infer the set of possible label classes, and convert these to integer indexes.
-
-
-
Method Detail
-
getLabelForPath
public Writable getLabelForPath(String path)
- Specified by:
getLabelForPathin interfacePathLabelGenerator
-
getLabelForPath
public Writable getLabelForPath(URI uri)
- Specified by:
getLabelForPathin interfacePathLabelGenerator
-
inferLabelClasses
public boolean inferLabelClasses()
Description copied from interface:PathLabelGeneratorIf true: infer the set of possible label classes, and convert these to integer indexes. If when true, the returned Writables should be text writables.
For regression use cases (or PathLabelGenerator classification instances that do their own label -> integer assignment), this should return false.- Specified by:
inferLabelClassesin interfacePathLabelGenerator- Returns:
- whether label classes should be inferred
-
-