Identity¶

class
astropy.modeling.mappings.
Identity
(n_inputs, name=None, meta=None)[source]¶ Bases:
astropy.modeling.mappings.Mapping
Returns inputs unchanged.
This class is useful in compound models when some of the inputs must be passed unchanged to the next model.
 Parameters
 n_inputsint
Specifies the number of inputs this identity model accepts.
 namestr, optional
A humanfriendly name associated with this model instance (particularly useful for identifying the individual components of a compound model).
 metadictlike
Freeform metadata to associate with this model.
Examples
Transform
(x, y)
by a shift in x, followed by scaling the two inputs:>>> from astropy.modeling.models import (Polynomial1D, Shift, Scale, ... Identity) >>> model = (Shift(1) & Identity(1))  Scale(1.2) & Scale(2) >>> model(1,1) (2.4, 2.0) >>> model.inverse(2.4, 2) (1.0, 1.0)
Attributes Summary
Attributes Documentation

linear
= True¶