human
Complete the below
def lazyproperty(f):

    ''''@lazyprop decorator. Decorated method will be called only on first access
    to calculate a cached property value. After that, the cached value is
    returned.'
    '''

What is a Python code to calculate a cached property value?
assistant
#Here is Python code to calculate a cached property value.
    cache_attr_name = (u'_%s' % f.__name__)
    docstring = f.__doc__
    def get_prop_value(obj):
        try:
            return getattr(obj, cache_attr_name)
        except AttributeError:
            value = f(obj)
            setattr(obj, cache_attr_name, value)
            return value
    return property(get_prop_value, doc=docstring)