object DenseClassifierGraphResolver
Finds the best embedded (or user provided) graph for a dense classifier training run.
The feature vectors and the one hot encoded labels are zero padded to the dimensions of the graph by TensorflowGenericClassifier, so a graph is usable whenever its dimensions are greater than or equal to the dimensions of the training data. Padded inputs contribute nothing to the dense layers and padded labels are never the target class, therefore the training result of a padded graph is equivalent to the training result of an exactly sized graph. Still, the smallest suitable graph is selected, and a graph with the exact number of classes is always preferred, so that the reported metrics are computed over the real classes only.
- Alphabetic
- By Inheritance
- DenseClassifierGraphResolver
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
listGraphs(family: DenseClassifierGraphFamily, localGraphPath: Option[String] = None): Seq[DenseClassifierGraphInfo]
Lists the graphs of the given family, either from the JAR resources or from a user provided folder.
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
parseDimensions(fileName: String, requiredPrefix: Option[String] = None): Option[(Int, Int)]
Extracts (inputDim, outputDim) from a graph file name.
Extracts (inputDim, outputDim) from a graph file name.
- fileName
name of the graph file
- requiredPrefix
when defined, only file names starting with this prefix are accepted
-
def
searchForSuitableGraph(family: DenseClassifierGraphFamily, inputDim: Int, outputDim: Int, localGraphPath: Option[String] = None): DenseClassifierGraphInfo
Returns the smallest graph of this family able to train
inputDimfeatures intooutputDimclasses.Returns the smallest graph of this family able to train
inputDimfeatures intooutputDimclasses.- family
graph family of the annotator being trained
- inputDim
length of the feature vectors
- outputDim
number of classes
- localGraphPath
optional user folder with graphs, takes precedence over the embedded ones
-
def
selectGraph(candidates: Seq[DenseClassifierGraphInfo], inputDim: Int, outputDim: Int): Option[DenseClassifierGraphInfo]
Picks the graph to train with out of the given candidates: the smallest one able to hold the data, preferring an exact number of classes.
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()