Package ai.djl.nn

Class AbstractSymbolBlock

java.lang.Object
ai.djl.nn.AbstractBaseBlock
ai.djl.nn.AbstractSymbolBlock
All Implemented Interfaces:
Block, SymbolBlock

public abstract class AbstractSymbolBlock extends AbstractBaseBlock implements SymbolBlock
AbstractSymbolBlock is an abstract implementation of SymbolBlock.
  • Constructor Details

    • AbstractSymbolBlock

      public AbstractSymbolBlock()
      Constructs a new AbstractSymbolBlock instance.
    • AbstractSymbolBlock

      public AbstractSymbolBlock(byte version)
      Builds an empty block with the given version for parameter serialization.
      Parameters:
      version - the version to use for parameter serialization.
  • Method Details

    • getOutputShapes

      public Shape[] getOutputShapes(Shape[] inputShapes)
      Returns the expected output shapes of the block for the specified input shapes.
      Specified by:
      getOutputShapes in interface Block
      Parameters:
      inputShapes - the shapes of the inputs
      Returns:
      the expected output shapes of the block
    • getChildren

      public BlockList getChildren()
      Returns a list of all the children of the block.
      Specified by:
      getChildren in interface Block
      Returns:
      the list of child blocks