'Return the optional state attributes.'

@property
def device_state_attributes(self):

    data = {}
    target_temp_high = self.target_temperature_high
    target_temp_low = self.target_temperature_low
    if (target_temp_high is not None):
        data[ATTR_TARGET_TEMP_HIGH] = self._convert_for_display(self.target_temperature_high)
    if (target_temp_low is not None):
        data[ATTR_TARGET_TEMP_LOW] = self._convert_for_display(self.target_temperature_low)
    if self.external_temperature:
        data[ATTR_EXTERNAL_TEMPERATURE] = self._convert_for_display(self.external_temperature)
    if self.smart_temperature:
        data[ATTR_SMART_TEMPERATURE] = self.smart_temperature
    if self.occupied:
        data[ATTR_OCCUPIED] = self.occupied
    if self.eco_target:
        data[ATTR_ECO_TARGET] = self.eco_target
    current_humidity = self.current_humidity
    if (current_humidity is not None):
        data[ATTR_CURRENT_HUMIDITY] = current_humidity
    return data
