'This property is used to indicate what units or sets of units the
evaluate method expects, and returns a dictionary mapping inputs to
units (or `None` if any units are accepted).
Model sub-classes can also use function annotations in evaluate to
indicate valid input units, in which case this property should
not be overriden since it will return the input units based on the
annotations.'

@property
def input_units(self):

    if hasattr(self, u'_input_units'):
        return self._input_units
    elif hasattr(self.evaluate, u'__annotations__'):
        annotations = self.evaluate.__annotations__.copy()
        annotations.pop(u'return', None)
        if annotations:
            return dict(((name, annotations[name]) for name in self.inputs))
    else:
        return None
