<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def python_value(self, value):
 """Return the value in the database as an Pendulum object. Returns: pendulum.Pendulum: An instance of Pendulum with the field filled in. """

        value = super(PendulumDateTimeField, self).python_value(value)

        if isinstance(value, datetime.datetime):
            value = pendulum.instance(value)
        elif isinstance(value, datetime.date):
            value = pendulum.instance(
                datetime.datetime.combine(
                    value, datetime.datetime.min.time()
                )
            )
        elif isinstance(value, string_types):
            value = pendulum.parse(value)

        return value