### Navigation

- index
- modules
- next
- previous
- Home »
- Contents »
- InaSAFE’s API documentation »
- Package::safe »
- Package::safe.postprocessors »

# Module: safe.postprocessors.postprocessor_factory

Postprocessors package.

Tip

import like this from safe.postprocessors import get_post_processors and then call get_post_processors(requested_postprocessors)

`safe.postprocessors.postprocessor_factory.``get_post_processors`(requested_postprocessors)

  Creates a dictionary of applicable postprocessor instances

  Args:
    - requested_postprocessors: dictionary of requested

        postprocessors such as { ‘Gender’: {‘on’: True}, ‘Age’: {‘on’: True,

        > ‘params’: {

        >   ‘youth_ratio’: defaults[‘YOUTH_RATIO’], ‘adult_ratio’: defaults[‘ADULT_RATIO’], ‘elder_ratio’: defaults[‘ELDER_RATIO’] }

        > }

        } with ‘PostprocessorName’: {‘on’: True} being the minimum needed to activate a postprocessor. If asked for unimplemented postprocessors, the factory will just skip it returning the valid ones

  Returns:
    dict of postprocessors instances e.g.
      {‘Gender’:GenderPostprocessors instance}

`safe.postprocessors.postprocessor_factory.``get_postprocessor_human_name`(postprocesor)

  Returns the human readable name of post processor

  Args:
    - postprocessor: Machine name of the postprocessor
  Returns:
    str with the human readable name

This module forms part of the InaSAFE tool.

### Navigation

- index
- modules
- next
- previous
- Home »
- Contents »
- InaSAFE’s API documentation »
- Package::safe »
- Package::safe.postprocessors »