IBM/pytorchpipe

View on GitHub
configs/default/components/masking/string_to_mask.yml

Summary

Maintainability
Test Coverage
# This file defines the default values for the String To Mask component.

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

# Value that will be used when word is out of vocabulary (LOADED)
# (Mask for that element will be 0 as well)
# -100 is the default value used by PyTroch loss functions to specify
# target values that will ignored and does not contribute to the input gradient.
# (ignore_index=-100)
out_of_vocabulary_value: -100

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

  # Stream containing input strings (INPUT)
  strings: strings

  # Stream containing output masks (OUTPUT)
  masks: masks

  # Stream containing output indices (OUTPUT)
  string_indices: string_indices

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

  # Vocabulary used to produce masks and indices (RETRIEVED)
  word_mappings: word_mappings

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

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