LSSTApplications  18.1.0
LSSTDataManagementBasePackage
Classes | Functions
lsst.afw.table.schemaMapper.schemaMapperContinued Namespace Reference

Classes

class  SchemaMapper
 

Functions

def makeSchemaMapper (input, output, mappings)
 

Function Documentation

◆ makeSchemaMapper()

def lsst.afw.table.schemaMapper.schemaMapperContinued.makeSchemaMapper (   input,
  output,
  mappings 
)
Build a mapper from two Schemas and the mapping between them.
For pickle support.

Parameters
----------
input : `lsst.afw.table.Schema`
    The input schema for the mapper.
output : `lsst.afw.table.Schema`
    The output schema for the mapper.
mappings : `dict` [`lsst.afw.table.Key`, `lsst.afw.table.Key`]
    The mappings to define between the input and output schema.

Returns
-------
mapper : `lsst.afw.table.SchemaMapper`
    The constructed SchemaMapper.

Definition at line 128 of file schemaMapperContinued.py.

128 def makeSchemaMapper(input, output, mappings):
129  """Build a mapper from two Schemas and the mapping between them.
130  For pickle support.
131 
132  Parameters
133  ----------
134  input : `lsst.afw.table.Schema`
135  The input schema for the mapper.
136  output : `lsst.afw.table.Schema`
137  The output schema for the mapper.
138  mappings : `dict` [`lsst.afw.table.Key`, `lsst.afw.table.Key`]
139  The mappings to define between the input and output schema.
140 
141  Returns
142  -------
143  mapper : `lsst.afw.table.SchemaMapper`
144  The constructed SchemaMapper.
145  """
146  mapper = SchemaMapper(input, output)
147  for key, value in mappings.items():
148  mapper.addMapping(key, value)
149  return mapper
150