IBM/pytorchpipe

View on GitHub
configs/default/components/models/general_usage/feed_forward_network.yml

Summary

Maintainability
Test Coverage
# This file defines the default values for the Multi-Layer Feed-Forward Network.

####################################################################
# 1. CONFIGURATION PARAMETERS that will be LOADED by the component.
####################################################################

# Optional (LOADED)
# Number of hidden layers, along with their sizes (numbers of neurons).
# hidden_sizes: [dim hidden 1, dim hidden 2, ...]

# Dropout rate (LOADED)
# Default: 0 (means that it is turned off)
dropout_rate: 0

# If true, output of the last layer will be additionally processed with Log Softmax (LOADED)
use_logsoftmax: True

# Number of dimensions, where:
#   - 2 means [Batch size, Input size]
#   - n means [Batch size, dim 1, ..., dim n-2, Input size]
# And the FFN is broadcasted over the last (Input Size) Dimension.
# Also, all the dimensions sizes but the last are conserved, as the FFN is applied over the last dimension.
dimensions: 2

streams: 
  ####################################################################
  # 2. Keymappings associated with INPUT and OUTPUT streams.
  ####################################################################

  # Stream containing batch of inputs (INPUT)
  inputs: inputs

  # Stream containing predictions (OUTPUT)
  predictions: predictions

globals:
  ####################################################################
  # 3. Keymappings of variables that will be RETRIEVED from GLOBALS.
  ####################################################################

  # Size of the input (RETRIEVED)
  input_size: input_size

  # Size of the prediction (RETRIEVED)
  prediction_size: prediction_size

  ####################################################################
  # 4. Keymappings associated with GLOBAL variables that will be SET.
  ####################################################################

  ####################################################################
  # 5. Keymappings associated with statistics that will be ADDED.
  ####################################################################