# coding: utf-8

"""
    Weheat Backend

    This is the backend for the Weheat project

    The version of the OpenAPI document: v1
    Generated by OpenAPI Generator (https://openapi-generator.tech)

    Do not edit the class manually.
"""  # noqa: E501


from __future__ import annotations
import pprint
import re  # noqa: F401
import json

from datetime import datetime
from typing import Any, ClassVar, Dict, List, Optional, Union
from pydantic import BaseModel, StrictFloat, StrictInt, StrictStr
from pydantic import Field
try:
    from typing import Self
except ImportError:
    from typing_extensions import Self

class HeatPumpLogViewDto(BaseModel):
    """
    HeatPumpLogViewDto
    """ # noqa: E501
    time_bucket: Optional[datetime] = Field(default=None, description="Timestamp of the beginning of this interval (UTC)", alias="timeBucket")
    interval: Optional[StrictStr] = Field(default=None, description="Interval Granularity of this HeatPumpLogViewDto (Correct intervals include: \"Hour\", \"Day\", \"Week\", \"Month\", \"Year\")")
    time_covered_in_interval: Optional[StrictInt] = Field(default=None, description="Amount of time covered by this interval in seconds out of a maximum of the Interval (Granularity) in seconds", alias="timeCoveredInInterval")
    heat_pump_state_standby: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the standby state for this interval", alias="heatPumpStateStandby")
    heat_pump_state_heating: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the heating state for this interval", alias="heatPumpStateHeating")
    heat_pump_state_defrost: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the defrost required active state for this interval", alias="heatPumpStateDefrost")
    heat_pump_state_cooling: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the cooling state for this interval", alias="heatPumpStateCooling")
    heat_pump_state_dhw: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the (heating) Domestic Hot Water stae for this interval", alias="heatPumpStateDHW")
    heat_pump_state_legionella: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Legionnaires' Disease Prevention state for this interval", alias="heatPumpStateLegionella")
    rpm_control_startup: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in one of the RPM Control Startup states for this interval", alias="rpmControlStartup")
    rpm_control_running: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in one of the RPM Control Running state for this interval", alias="rpmControlRunning")
    rpm_control_running_abnormally: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the RPM Control Running Abnormally states for this interval", alias="rpmControlRunningAbnormally")
    rpm_control_shutdown: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in one of the RPM Control Shutdown states for this interval", alias="rpmControlShutdown")
    control_bridge_status_water_pump: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Control Bridge Status Water Pump state to true for this interval", alias="controlBridgeStatusWaterPump")
    control_bridge_status_dhw_valve: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Control Bridge Status DHW Valve state to true for this interval", alias="controlBridgeStatusDhwValve")
    control_bridge_status_gas_boiler: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Control Bridge Status Gas Boiler state to true for this interval", alias="controlBridgeStatusGasBoiler")
    control_bridge_status_electric_heater: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Control Bridge Status Electric Heater state to true for this interval", alias="controlBridgeStatusElectricHeater")
    control_bridge_status_water_pump2: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Control Bridge Status Water Pump 2 state to true for this interval", alias="controlBridgeStatusWaterPump2")
    dtc_none: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the No DTC codes Error state for this interval (staff only)", alias="dtcNone")
    dtc_continue: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC but can Continue Error state for this interval (staff only)", alias="dtcContinue")
    dtc_compressor_off: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC Compressor Off Error state for this interval (staff only)", alias="dtcCompressorOff")
    dtc_defrost_forbidden: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC Defrost Forbidden Error state for this interval (staff only)", alias="dtcDefrostForbidden")
    dtc_request_service: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC Request Service Error state for this interval (staff only)", alias="dtcRequestService")
    dtc_use_heating_curve: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC Use Heating Curve (only) Error state for this interval (staff only)", alias="dtcUseHeatingCurve")
    dtc_dhw_forbidden: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC HW Forbidden Error state for this interval (staff only)", alias="dtcDhwForbidden")
    dtc_error: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC DTC Error state for this interval (staff only)", alias="dtcError")
    dtc_inactive: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the DTC Inactive Error state for this interval (staff only)", alias="dtcInactive")
    signal_strength_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average of the Signal Strength (integer out of 20) of the heat pump for this interval (staff only)", alias="signalStrengthAverage")
    signal_strength_min: Optional[StrictInt] = Field(default=None, description="Minimal Signal Strength (integer out of 20) of the heat pump for this interval (staff only)", alias="signalStrengthMin")
    signal_strength_max: Optional[StrictInt] = Field(default=None, description="Maximum Signal Strength (integer out of 20) of the heat pump for this interval (staff only)", alias="signalStrengthMax")
    t1_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the top DHW sensor (T1) of the heat pump for this interval", alias="t1Average")
    t1_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the top DHW sensor (T1) of the heat pump for this interval", alias="t1Min")
    t1_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the top DHW sensor (T1) of the heat pump for this interval", alias="t1Max")
    t2_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the bottom DHW sensor (T2) of the heat pump for this interval", alias="t2Average")
    t2_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the bottom DHW sensor (T2) of the heat pump for this interval", alias="t2Min")
    t2_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the bottom DHW sensor (T2) of the heat pump for this interval", alias="t2Max")
    t_spare_ntc_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the spare DHW sensor (TSpareNTC) of the heat pump for this interval (staff only)", alias="tSpareNtcAverage")
    t_spare_ntc_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the spare DHW sensor (TSpareNTC) of the heat pump for this interval (staff only)", alias="tSpareNtcMin")
    t_spare_ntc_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the spare DHW sensor (TSpareNTC) of the heat pump for this interval (staff only)", alias="tSpareNtcMax")
    t_board_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the control board of the heat pump for this interval (staff only)", alias="tBoardAverage")
    t_board_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the control board of the heat pump for this interval (staff only)", alias="tBoardMin")
    t_board_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the control board of the heat pump for this interval (staff only)", alias="tBoardMax")
    t_air_in_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of air going into the heat pump for this interval", alias="tAirInAverage")
    t_air_in_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="tAirInMin")
    t_air_in_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="tAirInMax")
    t_air_out_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of air going out of the heat pump for this interval", alias="tAirOutAverage")
    t_air_out_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of air going out of the heat pump for this interval", alias="tAirOutMin")
    t_air_out_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of air going out of the heat pump for this interval", alias="tAirOutMax")
    t_water_in_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the water going into the heat pump for this interval", alias="tWaterInAverage")
    t_water_in_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the water going into the heat pump for this interval", alias="tWaterInMin")
    t_water_in_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the water going into the heat pump for this interval", alias="tWaterInMax")
    t_water_out_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the water going out of the heat pump for this interval", alias="tWaterOutAverage")
    t_water_out_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the water going out of the heat pump for this interval", alias="tWaterOutMin")
    t_water_out_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the water going out of the heat pump for this interval", alias="tWaterOutMax")
    t_water_house_in_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the water going into the house for this interval", alias="tWaterHouseInAverage")
    t_water_house_in_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the water going into the house for this interval", alias="tWaterHouseInMin")
    t_water_house_in_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the water going into the house for this interval", alias="tWaterHouseInMax")
    rpm_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average RPM of the compressor for this interval (not for consumers)", alias="rpmAverage")
    rpm_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum RPM of the compressor for this interval (not for consumers)", alias="rpmMin")
    rpm_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum RPM of the compressor for this interval (not for consumers)", alias="rpmMax")
    rpm_limiter_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average RPM value the heat pump was limited to for this interval (staff only)", alias="rpmLimiterAverage")
    rpm_limiter_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum RPM value the heat pump was limited to for this interval (staff only)", alias="rpmLimiterMin")
    rpm_limiter_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum RPM value the heat pump was limited to for this interval (staff only)", alias="rpmLimiterMax")
    rpm_limiter_no_limit: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was not Limited at all by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterNoLimit")
    rpm_limiter_power_limit: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited by the amount of Power by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterPowerLimit")
    rpm_limiter_defrost: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited because of Defrost by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterDefrost")
    rpm_limiter_silent_hours: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited because of Silent Hours by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterSilentHours")
    rpm_limiter_hp_control: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited because of HP Control method by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterHPControl")
    rpm_limiter_pressure: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited because of its Pressure by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterPressure")
    rpm_limiter_water_out: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited because of its Water Out temperature by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterWaterOut")
    rpm_limiter_envelope: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited because of Envelope control method by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterEnvelope")
    rpm_limiter_house_in: Optional[StrictInt] = Field(default=None, description="Amount of time the compressor RPM was being most limited because of its Water In temperature by the RPM Limiter state for this interval (staff only)", alias="rpmLimiterHouseIn")
    p_compressor_in_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average pressure on the intake side of the compressor for this interval (not for consumers)", alias="pCompressorInAverage")
    p_compressor_in_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum pressure on the intake side of the compressor for this interval (not for consumers)", alias="pCompressorInMin")
    p_compressor_in_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum pressure on the intake side of the compressor for this interval (not for consumers)", alias="pCompressorInMax")
    p_compressor_out_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average pressure on the output side of the compressor for this interval (not for consumers)", alias="pCompressorOutAverage")
    p_compressor_out_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum pressure on the output side of the compressor for this interval (not for consumers)", alias="pCompressorOutMin")
    p_compressor_out_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum pressure on the output side of the compressor for this interval (not for consumers)", alias="pCompressorOutMax")
    p_compressor_in_target_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average target pressure (on the intake side) of the compressor for this interval (not for consumers)", alias="pCompressorInTargetAverage")
    p_compressor_in_target_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum target pressure (on the intake side) of the compressor for this interval (not for consumers)", alias="pCompressorInTargetMin")
    p_compressor_in_target_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum target pressure (on the intake side) of the compressor for this interval (not for consumers)", alias="pCompressorInTargetMax")
    t_inverter_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the inverter for this interval (staff only)", alias="tInverterAverage")
    t_inverter_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the inverter for this interval (staff only)", alias="tInverterMin")
    t_inverter_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the inverter for this interval (staff only)", alias="tInverterMax")
    t_compressor_in_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of intake side of the compressor for this interval (not for consumers)", alias="tCompressorInAverage")
    t_compressor_in_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of intake side of the compressor for this interval (not for consumers)", alias="tCompressorInMin")
    t_compressor_in_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of intake side of the compressor for this interval (not for consumers)", alias="tCompressorInMax")
    t_compressor_out_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of output side of the compressor for this interval (not for consumers)", alias="tCompressorOutAverage")
    t_compressor_out_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of output side of the compressor for this interval (not for consumers)", alias="tCompressorOutMin")
    t_compressor_out_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of output side of the compressor for this interval (not for consumers)", alias="tCompressorOutMax")
    t_compressor_in_transient_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature transient for the intake side of the compressor for this interval (staff only)", alias="tCompressorInTransientAverage")
    t_compressor_in_transient_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature transient for the intake side of the compressor for this interval (staff only)", alias="tCompressorInTransientMin")
    t_compressor_in_transient_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature transient for the intake side of the compressor for this interval (staff only)", alias="tCompressorInTransientMax")
    t_compressor_out_transient_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature transient for the output side of the compressor for this interval (staff only)", alias="tCompressorOutTransientAverage")
    t_compressor_out_transient_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature transient for the output side of the compressor for this interval (staff only)", alias="tCompressorOutTransientMin")
    t_compressor_out_transient_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature transient for the output side of the compressor for this interval (staff only)", alias="tCompressorOutTransientMax")
    delta_t_compressor_in_superheat_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature difference in the compressor for Superheat for this interval (staff only)", alias="deltaTCompressorInSuperheatAverage")
    delta_t_compressor_in_superheat_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature difference in the compressor for Superheat for this interval (staff only)", alias="deltaTCompressorInSuperheatMin")
    delta_t_compressor_in_superheat_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature difference in the compressor for Superheat for this interval (staff only)", alias="deltaTCompressorInSuperheatMax")
    compressor_power_low_accuracy_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average power used by the compressor (low accuracy) for this interval (staff only)", alias="compressorPowerLowAccuracyAverage")
    compressor_power_low_accuracy_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum power used by the compressor (low accuracy) for this interval (staff only)", alias="compressorPowerLowAccuracyMin")
    compressor_power_low_accuracy_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum power used by the compressor (low accuracy) for this interval (staff only)", alias="compressorPowerLowAccuracyMax")
    fan_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average percentage of the fan used for this interval (staff only)", alias="fanAverage")
    fan_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum percentage of the fan used for this interval (staff only)", alias="fanMin")
    fan_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum percentage of the fan used for this interval (staff only)", alias="fanMax")
    fan_power_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average power used by the fan for this interval (staff only)", alias="fanPowerAverage")
    fan_power_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum power used by the fan for this interval (staff only)", alias="fanPowerMin")
    fan_power_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum power used by the fan for this interval (staff only)", alias="fanPowerMax")
    cm_mass_power_in_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average of the total amount of energy produced by the heat pump for this interval (staff only)", alias="cmMassPowerInAverage")
    cm_mass_power_out_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average of the total amount of energy produced by the heat pump for this interval (staff only)", alias="cmMassPowerOutAverage")
    temperature_error_integral_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average value of the TemperatureErrorIntegral for this interval (staff only)", alias="temperatureErrorIntegralAverage")
    temperature_error_integral_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum value of the TemperatureErrorIntegral for this interval (staff only)", alias="temperatureErrorIntegralMin")
    temperature_error_integral_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum value of the TemperatureErrorIntegral for this interval (staff only)", alias="temperatureErrorIntegralMax")
    thermostat_state_off: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Thermostat State Off state for this interval", alias="thermostatStateOff")
    thermostat_state_on: Optional[StrictInt] = Field(default=None, description="Amount of seconds the heat pump spend in the Thermostat State On state for this interval", alias="thermostatStateOn")
    t_room_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature of the room for this interval", alias="tRoomAverage")
    t_room_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature of the room for this interval", alias="tRoomMin")
    t_room_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature of the room for this interval", alias="tRoomMax")
    t_room_target_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average target room temperature of the thermostat for this interval", alias="tRoomTargetAverage")
    t_room_target_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum target room temperature of the thermostat for this interval", alias="tRoomTargetMin")
    t_room_target_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum target room temperature of the thermostat for this interval", alias="tRoomTargetMax")
    t_thermostat_setpoint_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average temperature setpoint of the thermostat for this interval OR the water setpoint of the heat pump", alias="tThermostatSetpointAverage")
    t_thermostat_setpoint_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum temperature setpoint of the thermostat for this interval OR the water setpoint of the heat pump", alias="tThermostatSetpointMin")
    t_thermostat_setpoint_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum temperature setpoint of the thermostat for this interval OR the water setpoint of the heat pump", alias="tThermostatSetpointMax")
    ot_boiler_feed_temperature_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average OpenTherm boiler water feed temperature for this interval", alias="otBoilerFeedTemperatureAverage")
    ot_boiler_feed_temperature_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum OpenTherm boiler water feed temperature for this interval", alias="otBoilerFeedTemperatureMin")
    ot_boiler_feed_temperature_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum OpenTherm boiler water feed temperature for this interval", alias="otBoilerFeedTemperatureMax")
    ot_boiler_return_temperature_average: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Average OpenTherm boiler water return temperature for this interval", alias="otBoilerReturnTemperatureAverage")
    ot_boiler_return_temperature_min: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Minimum OpenTherm boiler water return temperature for this interval", alias="otBoilerReturnTemperatureMin")
    ot_boiler_return_temperature_max: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Maximum OpenTherm boiler water return temperature for this interval", alias="otBoilerReturnTemperatureMax")
    __properties: ClassVar[List[str]] = ["timeBucket", "interval", "timeCoveredInInterval", "heatPumpStateStandby", "heatPumpStateHeating", "heatPumpStateDefrost", "heatPumpStateCooling", "heatPumpStateDHW", "heatPumpStateLegionella", "rpmControlStartup", "rpmControlRunning", "rpmControlRunningAbnormally", "rpmControlShutdown", "controlBridgeStatusWaterPump", "controlBridgeStatusDhwValve", "controlBridgeStatusGasBoiler", "controlBridgeStatusElectricHeater", "controlBridgeStatusWaterPump2", "dtcNone", "dtcContinue", "dtcCompressorOff", "dtcDefrostForbidden", "dtcRequestService", "dtcUseHeatingCurve", "dtcDhwForbidden", "dtcError", "dtcInactive", "signalStrengthAverage", "signalStrengthMin", "signalStrengthMax", "t1Average", "t1Min", "t1Max", "t2Average", "t2Min", "t2Max", "tSpareNtcAverage", "tSpareNtcMin", "tSpareNtcMax", "tBoardAverage", "tBoardMin", "tBoardMax", "tAirInAverage", "tAirInMin", "tAirInMax", "tAirOutAverage", "tAirOutMin", "tAirOutMax", "tWaterInAverage", "tWaterInMin", "tWaterInMax", "tWaterOutAverage", "tWaterOutMin", "tWaterOutMax", "tWaterHouseInAverage", "tWaterHouseInMin", "tWaterHouseInMax", "rpmAverage", "rpmMin", "rpmMax", "rpmLimiterAverage", "rpmLimiterMin", "rpmLimiterMax", "rpmLimiterNoLimit", "rpmLimiterPowerLimit", "rpmLimiterDefrost", "rpmLimiterSilentHours", "rpmLimiterHPControl", "rpmLimiterPressure", "rpmLimiterWaterOut", "rpmLimiterEnvelope", "rpmLimiterHouseIn", "pCompressorInAverage", "pCompressorInMin", "pCompressorInMax", "pCompressorOutAverage", "pCompressorOutMin", "pCompressorOutMax", "pCompressorInTargetAverage", "pCompressorInTargetMin", "pCompressorInTargetMax", "tInverterAverage", "tInverterMin", "tInverterMax", "tCompressorInAverage", "tCompressorInMin", "tCompressorInMax", "tCompressorOutAverage", "tCompressorOutMin", "tCompressorOutMax", "tCompressorInTransientAverage", "tCompressorInTransientMin", "tCompressorInTransientMax", "tCompressorOutTransientAverage", "tCompressorOutTransientMin", "tCompressorOutTransientMax", "deltaTCompressorInSuperheatAverage", "deltaTCompressorInSuperheatMin", "deltaTCompressorInSuperheatMax", "compressorPowerLowAccuracyAverage", "compressorPowerLowAccuracyMin", "compressorPowerLowAccuracyMax", "fanAverage", "fanMin", "fanMax", "fanPowerAverage", "fanPowerMin", "fanPowerMax", "cmMassPowerInAverage", "cmMassPowerOutAverage", "temperatureErrorIntegralAverage", "temperatureErrorIntegralMin", "temperatureErrorIntegralMax", "thermostatStateOff", "thermostatStateOn", "tRoomAverage", "tRoomMin", "tRoomMax", "tRoomTargetAverage", "tRoomTargetMin", "tRoomTargetMax", "tThermostatSetpointAverage", "tThermostatSetpointMin", "tThermostatSetpointMax", "otBoilerFeedTemperatureAverage", "otBoilerFeedTemperatureMin", "otBoilerFeedTemperatureMax", "otBoilerReturnTemperatureAverage", "otBoilerReturnTemperatureMin", "otBoilerReturnTemperatureMax"]

    model_config = {
        "populate_by_name": True,
        "validate_assignment": True,
        "protected_namespaces": (),
    }


    def to_str(self) -> str:
        """Returns the string representation of the model using alias"""
        return pprint.pformat(self.model_dump(by_alias=True))

    def to_json(self) -> str:
        """Returns the JSON representation of the model using alias"""
        # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
        return json.dumps(self.to_dict())

    @classmethod
    def from_json(cls, json_str: str) -> Self:
        """Create an instance of HeatPumpLogViewDto from a JSON string"""
        return cls.from_dict(json.loads(json_str))

    def to_dict(self) -> Dict[str, Any]:
        """Return the dictionary representation of the model using alias.

        This has the following differences from calling pydantic's
        `self.model_dump(by_alias=True)`:

        * `None` is only added to the output dict for nullable fields that
          were set at model initialization. Other fields with value `None`
          are ignored.
        """
        _dict = self.model_dump(
            by_alias=True,
            exclude={
            },
            exclude_none=True,
        )
        # set to None if interval (nullable) is None
        # and model_fields_set contains the field
        if self.interval is None and "interval" in self.model_fields_set:
            _dict['interval'] = None

        # set to None if rpm_control_startup (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_control_startup is None and "rpm_control_startup" in self.model_fields_set:
            _dict['rpmControlStartup'] = None

        # set to None if rpm_control_running (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_control_running is None and "rpm_control_running" in self.model_fields_set:
            _dict['rpmControlRunning'] = None

        # set to None if rpm_control_shutdown (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_control_shutdown is None and "rpm_control_shutdown" in self.model_fields_set:
            _dict['rpmControlShutdown'] = None

        # set to None if control_bridge_status_dhw_valve (nullable) is None
        # and model_fields_set contains the field
        if self.control_bridge_status_dhw_valve is None and "control_bridge_status_dhw_valve" in self.model_fields_set:
            _dict['controlBridgeStatusDhwValve'] = None

        # set to None if dtc_none (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_none is None and "dtc_none" in self.model_fields_set:
            _dict['dtcNone'] = None

        # set to None if dtc_continue (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_continue is None and "dtc_continue" in self.model_fields_set:
            _dict['dtcContinue'] = None

        # set to None if dtc_compressor_off (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_compressor_off is None and "dtc_compressor_off" in self.model_fields_set:
            _dict['dtcCompressorOff'] = None

        # set to None if dtc_defrost_forbidden (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_defrost_forbidden is None and "dtc_defrost_forbidden" in self.model_fields_set:
            _dict['dtcDefrostForbidden'] = None

        # set to None if dtc_request_service (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_request_service is None and "dtc_request_service" in self.model_fields_set:
            _dict['dtcRequestService'] = None

        # set to None if dtc_use_heating_curve (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_use_heating_curve is None and "dtc_use_heating_curve" in self.model_fields_set:
            _dict['dtcUseHeatingCurve'] = None

        # set to None if dtc_dhw_forbidden (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_dhw_forbidden is None and "dtc_dhw_forbidden" in self.model_fields_set:
            _dict['dtcDhwForbidden'] = None

        # set to None if dtc_error (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_error is None and "dtc_error" in self.model_fields_set:
            _dict['dtcError'] = None

        # set to None if dtc_inactive (nullable) is None
        # and model_fields_set contains the field
        if self.dtc_inactive is None and "dtc_inactive" in self.model_fields_set:
            _dict['dtcInactive'] = None

        # set to None if signal_strength_average (nullable) is None
        # and model_fields_set contains the field
        if self.signal_strength_average is None and "signal_strength_average" in self.model_fields_set:
            _dict['signalStrengthAverage'] = None

        # set to None if signal_strength_min (nullable) is None
        # and model_fields_set contains the field
        if self.signal_strength_min is None and "signal_strength_min" in self.model_fields_set:
            _dict['signalStrengthMin'] = None

        # set to None if signal_strength_max (nullable) is None
        # and model_fields_set contains the field
        if self.signal_strength_max is None and "signal_strength_max" in self.model_fields_set:
            _dict['signalStrengthMax'] = None

        # set to None if t1_average (nullable) is None
        # and model_fields_set contains the field
        if self.t1_average is None and "t1_average" in self.model_fields_set:
            _dict['t1Average'] = None

        # set to None if t1_min (nullable) is None
        # and model_fields_set contains the field
        if self.t1_min is None and "t1_min" in self.model_fields_set:
            _dict['t1Min'] = None

        # set to None if t1_max (nullable) is None
        # and model_fields_set contains the field
        if self.t1_max is None and "t1_max" in self.model_fields_set:
            _dict['t1Max'] = None

        # set to None if t2_average (nullable) is None
        # and model_fields_set contains the field
        if self.t2_average is None and "t2_average" in self.model_fields_set:
            _dict['t2Average'] = None

        # set to None if t2_min (nullable) is None
        # and model_fields_set contains the field
        if self.t2_min is None and "t2_min" in self.model_fields_set:
            _dict['t2Min'] = None

        # set to None if t2_max (nullable) is None
        # and model_fields_set contains the field
        if self.t2_max is None and "t2_max" in self.model_fields_set:
            _dict['t2Max'] = None

        # set to None if t_spare_ntc_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_spare_ntc_average is None and "t_spare_ntc_average" in self.model_fields_set:
            _dict['tSpareNtcAverage'] = None

        # set to None if t_spare_ntc_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_spare_ntc_min is None and "t_spare_ntc_min" in self.model_fields_set:
            _dict['tSpareNtcMin'] = None

        # set to None if t_spare_ntc_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_spare_ntc_max is None and "t_spare_ntc_max" in self.model_fields_set:
            _dict['tSpareNtcMax'] = None

        # set to None if t_board_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_board_average is None and "t_board_average" in self.model_fields_set:
            _dict['tBoardAverage'] = None

        # set to None if t_board_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_board_min is None and "t_board_min" in self.model_fields_set:
            _dict['tBoardMin'] = None

        # set to None if t_board_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_board_max is None and "t_board_max" in self.model_fields_set:
            _dict['tBoardMax'] = None

        # set to None if t_air_out_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_air_out_average is None and "t_air_out_average" in self.model_fields_set:
            _dict['tAirOutAverage'] = None

        # set to None if t_air_out_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_air_out_min is None and "t_air_out_min" in self.model_fields_set:
            _dict['tAirOutMin'] = None

        # set to None if t_air_out_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_air_out_max is None and "t_air_out_max" in self.model_fields_set:
            _dict['tAirOutMax'] = None

        # set to None if rpm_average (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_average is None and "rpm_average" in self.model_fields_set:
            _dict['rpmAverage'] = None

        # set to None if rpm_min (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_min is None and "rpm_min" in self.model_fields_set:
            _dict['rpmMin'] = None

        # set to None if rpm_max (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_max is None and "rpm_max" in self.model_fields_set:
            _dict['rpmMax'] = None

        # set to None if rpm_limiter_average (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_average is None and "rpm_limiter_average" in self.model_fields_set:
            _dict['rpmLimiterAverage'] = None

        # set to None if rpm_limiter_min (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_min is None and "rpm_limiter_min" in self.model_fields_set:
            _dict['rpmLimiterMin'] = None

        # set to None if rpm_limiter_max (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_max is None and "rpm_limiter_max" in self.model_fields_set:
            _dict['rpmLimiterMax'] = None

        # set to None if rpm_limiter_no_limit (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_no_limit is None and "rpm_limiter_no_limit" in self.model_fields_set:
            _dict['rpmLimiterNoLimit'] = None

        # set to None if rpm_limiter_power_limit (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_power_limit is None and "rpm_limiter_power_limit" in self.model_fields_set:
            _dict['rpmLimiterPowerLimit'] = None

        # set to None if rpm_limiter_defrost (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_defrost is None and "rpm_limiter_defrost" in self.model_fields_set:
            _dict['rpmLimiterDefrost'] = None

        # set to None if rpm_limiter_silent_hours (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_silent_hours is None and "rpm_limiter_silent_hours" in self.model_fields_set:
            _dict['rpmLimiterSilentHours'] = None

        # set to None if rpm_limiter_hp_control (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_hp_control is None and "rpm_limiter_hp_control" in self.model_fields_set:
            _dict['rpmLimiterHPControl'] = None

        # set to None if rpm_limiter_pressure (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_pressure is None and "rpm_limiter_pressure" in self.model_fields_set:
            _dict['rpmLimiterPressure'] = None

        # set to None if rpm_limiter_water_out (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_water_out is None and "rpm_limiter_water_out" in self.model_fields_set:
            _dict['rpmLimiterWaterOut'] = None

        # set to None if rpm_limiter_envelope (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_envelope is None and "rpm_limiter_envelope" in self.model_fields_set:
            _dict['rpmLimiterEnvelope'] = None

        # set to None if rpm_limiter_house_in (nullable) is None
        # and model_fields_set contains the field
        if self.rpm_limiter_house_in is None and "rpm_limiter_house_in" in self.model_fields_set:
            _dict['rpmLimiterHouseIn'] = None

        # set to None if p_compressor_in_average (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_in_average is None and "p_compressor_in_average" in self.model_fields_set:
            _dict['pCompressorInAverage'] = None

        # set to None if p_compressor_in_min (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_in_min is None and "p_compressor_in_min" in self.model_fields_set:
            _dict['pCompressorInMin'] = None

        # set to None if p_compressor_in_max (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_in_max is None and "p_compressor_in_max" in self.model_fields_set:
            _dict['pCompressorInMax'] = None

        # set to None if p_compressor_out_average (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_out_average is None and "p_compressor_out_average" in self.model_fields_set:
            _dict['pCompressorOutAverage'] = None

        # set to None if p_compressor_out_min (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_out_min is None and "p_compressor_out_min" in self.model_fields_set:
            _dict['pCompressorOutMin'] = None

        # set to None if p_compressor_out_max (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_out_max is None and "p_compressor_out_max" in self.model_fields_set:
            _dict['pCompressorOutMax'] = None

        # set to None if p_compressor_in_target_average (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_in_target_average is None and "p_compressor_in_target_average" in self.model_fields_set:
            _dict['pCompressorInTargetAverage'] = None

        # set to None if p_compressor_in_target_min (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_in_target_min is None and "p_compressor_in_target_min" in self.model_fields_set:
            _dict['pCompressorInTargetMin'] = None

        # set to None if p_compressor_in_target_max (nullable) is None
        # and model_fields_set contains the field
        if self.p_compressor_in_target_max is None and "p_compressor_in_target_max" in self.model_fields_set:
            _dict['pCompressorInTargetMax'] = None

        # set to None if t_inverter_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_inverter_average is None and "t_inverter_average" in self.model_fields_set:
            _dict['tInverterAverage'] = None

        # set to None if t_inverter_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_inverter_min is None and "t_inverter_min" in self.model_fields_set:
            _dict['tInverterMin'] = None

        # set to None if t_inverter_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_inverter_max is None and "t_inverter_max" in self.model_fields_set:
            _dict['tInverterMax'] = None

        # set to None if t_compressor_in_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_in_average is None and "t_compressor_in_average" in self.model_fields_set:
            _dict['tCompressorInAverage'] = None

        # set to None if t_compressor_in_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_in_min is None and "t_compressor_in_min" in self.model_fields_set:
            _dict['tCompressorInMin'] = None

        # set to None if t_compressor_in_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_in_max is None and "t_compressor_in_max" in self.model_fields_set:
            _dict['tCompressorInMax'] = None

        # set to None if t_compressor_out_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_out_average is None and "t_compressor_out_average" in self.model_fields_set:
            _dict['tCompressorOutAverage'] = None

        # set to None if t_compressor_out_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_out_min is None and "t_compressor_out_min" in self.model_fields_set:
            _dict['tCompressorOutMin'] = None

        # set to None if t_compressor_out_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_out_max is None and "t_compressor_out_max" in self.model_fields_set:
            _dict['tCompressorOutMax'] = None

        # set to None if t_compressor_in_transient_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_in_transient_average is None and "t_compressor_in_transient_average" in self.model_fields_set:
            _dict['tCompressorInTransientAverage'] = None

        # set to None if t_compressor_in_transient_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_in_transient_min is None and "t_compressor_in_transient_min" in self.model_fields_set:
            _dict['tCompressorInTransientMin'] = None

        # set to None if t_compressor_in_transient_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_in_transient_max is None and "t_compressor_in_transient_max" in self.model_fields_set:
            _dict['tCompressorInTransientMax'] = None

        # set to None if t_compressor_out_transient_average (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_out_transient_average is None and "t_compressor_out_transient_average" in self.model_fields_set:
            _dict['tCompressorOutTransientAverage'] = None

        # set to None if t_compressor_out_transient_min (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_out_transient_min is None and "t_compressor_out_transient_min" in self.model_fields_set:
            _dict['tCompressorOutTransientMin'] = None

        # set to None if t_compressor_out_transient_max (nullable) is None
        # and model_fields_set contains the field
        if self.t_compressor_out_transient_max is None and "t_compressor_out_transient_max" in self.model_fields_set:
            _dict['tCompressorOutTransientMax'] = None

        # set to None if delta_t_compressor_in_superheat_average (nullable) is None
        # and model_fields_set contains the field
        if self.delta_t_compressor_in_superheat_average is None and "delta_t_compressor_in_superheat_average" in self.model_fields_set:
            _dict['deltaTCompressorInSuperheatAverage'] = None

        # set to None if delta_t_compressor_in_superheat_min (nullable) is None
        # and model_fields_set contains the field
        if self.delta_t_compressor_in_superheat_min is None and "delta_t_compressor_in_superheat_min" in self.model_fields_set:
            _dict['deltaTCompressorInSuperheatMin'] = None

        # set to None if delta_t_compressor_in_superheat_max (nullable) is None
        # and model_fields_set contains the field
        if self.delta_t_compressor_in_superheat_max is None and "delta_t_compressor_in_superheat_max" in self.model_fields_set:
            _dict['deltaTCompressorInSuperheatMax'] = None

        # set to None if compressor_power_low_accuracy_average (nullable) is None
        # and model_fields_set contains the field
        if self.compressor_power_low_accuracy_average is None and "compressor_power_low_accuracy_average" in self.model_fields_set:
            _dict['compressorPowerLowAccuracyAverage'] = None

        # set to None if compressor_power_low_accuracy_min (nullable) is None
        # and model_fields_set contains the field
        if self.compressor_power_low_accuracy_min is None and "compressor_power_low_accuracy_min" in self.model_fields_set:
            _dict['compressorPowerLowAccuracyMin'] = None

        # set to None if compressor_power_low_accuracy_max (nullable) is None
        # and model_fields_set contains the field
        if self.compressor_power_low_accuracy_max is None and "compressor_power_low_accuracy_max" in self.model_fields_set:
            _dict['compressorPowerLowAccuracyMax'] = None

        # set to None if fan_average (nullable) is None
        # and model_fields_set contains the field
        if self.fan_average is None and "fan_average" in self.model_fields_set:
            _dict['fanAverage'] = None

        # set to None if fan_min (nullable) is None
        # and model_fields_set contains the field
        if self.fan_min is None and "fan_min" in self.model_fields_set:
            _dict['fanMin'] = None

        # set to None if fan_max (nullable) is None
        # and model_fields_set contains the field
        if self.fan_max is None and "fan_max" in self.model_fields_set:
            _dict['fanMax'] = None

        # set to None if fan_power_average (nullable) is None
        # and model_fields_set contains the field
        if self.fan_power_average is None and "fan_power_average" in self.model_fields_set:
            _dict['fanPowerAverage'] = None

        # set to None if fan_power_min (nullable) is None
        # and model_fields_set contains the field
        if self.fan_power_min is None and "fan_power_min" in self.model_fields_set:
            _dict['fanPowerMin'] = None

        # set to None if fan_power_max (nullable) is None
        # and model_fields_set contains the field
        if self.fan_power_max is None and "fan_power_max" in self.model_fields_set:
            _dict['fanPowerMax'] = None

        # set to None if cm_mass_power_in_average (nullable) is None
        # and model_fields_set contains the field
        if self.cm_mass_power_in_average is None and "cm_mass_power_in_average" in self.model_fields_set:
            _dict['cmMassPowerInAverage'] = None

        # set to None if cm_mass_power_out_average (nullable) is None
        # and model_fields_set contains the field
        if self.cm_mass_power_out_average is None and "cm_mass_power_out_average" in self.model_fields_set:
            _dict['cmMassPowerOutAverage'] = None

        # set to None if temperature_error_integral_average (nullable) is None
        # and model_fields_set contains the field
        if self.temperature_error_integral_average is None and "temperature_error_integral_average" in self.model_fields_set:
            _dict['temperatureErrorIntegralAverage'] = None

        # set to None if temperature_error_integral_min (nullable) is None
        # and model_fields_set contains the field
        if self.temperature_error_integral_min is None and "temperature_error_integral_min" in self.model_fields_set:
            _dict['temperatureErrorIntegralMin'] = None

        # set to None if temperature_error_integral_max (nullable) is None
        # and model_fields_set contains the field
        if self.temperature_error_integral_max is None and "temperature_error_integral_max" in self.model_fields_set:
            _dict['temperatureErrorIntegralMax'] = None

        # set to None if ot_boiler_feed_temperature_average (nullable) is None
        # and model_fields_set contains the field
        if self.ot_boiler_feed_temperature_average is None and "ot_boiler_feed_temperature_average" in self.model_fields_set:
            _dict['otBoilerFeedTemperatureAverage'] = None

        # set to None if ot_boiler_feed_temperature_min (nullable) is None
        # and model_fields_set contains the field
        if self.ot_boiler_feed_temperature_min is None and "ot_boiler_feed_temperature_min" in self.model_fields_set:
            _dict['otBoilerFeedTemperatureMin'] = None

        # set to None if ot_boiler_feed_temperature_max (nullable) is None
        # and model_fields_set contains the field
        if self.ot_boiler_feed_temperature_max is None and "ot_boiler_feed_temperature_max" in self.model_fields_set:
            _dict['otBoilerFeedTemperatureMax'] = None

        # set to None if ot_boiler_return_temperature_average (nullable) is None
        # and model_fields_set contains the field
        if self.ot_boiler_return_temperature_average is None and "ot_boiler_return_temperature_average" in self.model_fields_set:
            _dict['otBoilerReturnTemperatureAverage'] = None

        # set to None if ot_boiler_return_temperature_min (nullable) is None
        # and model_fields_set contains the field
        if self.ot_boiler_return_temperature_min is None and "ot_boiler_return_temperature_min" in self.model_fields_set:
            _dict['otBoilerReturnTemperatureMin'] = None

        # set to None if ot_boiler_return_temperature_max (nullable) is None
        # and model_fields_set contains the field
        if self.ot_boiler_return_temperature_max is None and "ot_boiler_return_temperature_max" in self.model_fields_set:
            _dict['otBoilerReturnTemperatureMax'] = None

        return _dict

    @classmethod
    def from_dict(cls, obj: Dict) -> Self:
        """Create an instance of HeatPumpLogViewDto from a dict"""
        if obj is None:
            return None

        if not isinstance(obj, dict):
            return cls.model_validate(obj)

        _obj = cls.model_validate({
            "timeBucket": obj.get("timeBucket"),
            "interval": obj.get("interval"),
            "timeCoveredInInterval": obj.get("timeCoveredInInterval"),
            "heatPumpStateStandby": obj.get("heatPumpStateStandby"),
            "heatPumpStateHeating": obj.get("heatPumpStateHeating"),
            "heatPumpStateDefrost": obj.get("heatPumpStateDefrost"),
            "heatPumpStateCooling": obj.get("heatPumpStateCooling"),
            "heatPumpStateDHW": obj.get("heatPumpStateDHW"),
            "heatPumpStateLegionella": obj.get("heatPumpStateLegionella"),
            "rpmControlStartup": obj.get("rpmControlStartup"),
            "rpmControlRunning": obj.get("rpmControlRunning"),
            "rpmControlRunningAbnormally": obj.get("rpmControlRunningAbnormally"),
            "rpmControlShutdown": obj.get("rpmControlShutdown"),
            "controlBridgeStatusWaterPump": obj.get("controlBridgeStatusWaterPump"),
            "controlBridgeStatusDhwValve": obj.get("controlBridgeStatusDhwValve"),
            "controlBridgeStatusGasBoiler": obj.get("controlBridgeStatusGasBoiler"),
            "controlBridgeStatusElectricHeater": obj.get("controlBridgeStatusElectricHeater"),
            "controlBridgeStatusWaterPump2": obj.get("controlBridgeStatusWaterPump2"),
            "dtcNone": obj.get("dtcNone"),
            "dtcContinue": obj.get("dtcContinue"),
            "dtcCompressorOff": obj.get("dtcCompressorOff"),
            "dtcDefrostForbidden": obj.get("dtcDefrostForbidden"),
            "dtcRequestService": obj.get("dtcRequestService"),
            "dtcUseHeatingCurve": obj.get("dtcUseHeatingCurve"),
            "dtcDhwForbidden": obj.get("dtcDhwForbidden"),
            "dtcError": obj.get("dtcError"),
            "dtcInactive": obj.get("dtcInactive"),
            "signalStrengthAverage": obj.get("signalStrengthAverage"),
            "signalStrengthMin": obj.get("signalStrengthMin"),
            "signalStrengthMax": obj.get("signalStrengthMax"),
            "t1Average": obj.get("t1Average"),
            "t1Min": obj.get("t1Min"),
            "t1Max": obj.get("t1Max"),
            "t2Average": obj.get("t2Average"),
            "t2Min": obj.get("t2Min"),
            "t2Max": obj.get("t2Max"),
            "tSpareNtcAverage": obj.get("tSpareNtcAverage"),
            "tSpareNtcMin": obj.get("tSpareNtcMin"),
            "tSpareNtcMax": obj.get("tSpareNtcMax"),
            "tBoardAverage": obj.get("tBoardAverage"),
            "tBoardMin": obj.get("tBoardMin"),
            "tBoardMax": obj.get("tBoardMax"),
            "tAirInAverage": obj.get("tAirInAverage"),
            "tAirInMin": obj.get("tAirInMin"),
            "tAirInMax": obj.get("tAirInMax"),
            "tAirOutAverage": obj.get("tAirOutAverage"),
            "tAirOutMin": obj.get("tAirOutMin"),
            "tAirOutMax": obj.get("tAirOutMax"),
            "tWaterInAverage": obj.get("tWaterInAverage"),
            "tWaterInMin": obj.get("tWaterInMin"),
            "tWaterInMax": obj.get("tWaterInMax"),
            "tWaterOutAverage": obj.get("tWaterOutAverage"),
            "tWaterOutMin": obj.get("tWaterOutMin"),
            "tWaterOutMax": obj.get("tWaterOutMax"),
            "tWaterHouseInAverage": obj.get("tWaterHouseInAverage"),
            "tWaterHouseInMin": obj.get("tWaterHouseInMin"),
            "tWaterHouseInMax": obj.get("tWaterHouseInMax"),
            "rpmAverage": obj.get("rpmAverage"),
            "rpmMin": obj.get("rpmMin"),
            "rpmMax": obj.get("rpmMax"),
            "rpmLimiterAverage": obj.get("rpmLimiterAverage"),
            "rpmLimiterMin": obj.get("rpmLimiterMin"),
            "rpmLimiterMax": obj.get("rpmLimiterMax"),
            "rpmLimiterNoLimit": obj.get("rpmLimiterNoLimit"),
            "rpmLimiterPowerLimit": obj.get("rpmLimiterPowerLimit"),
            "rpmLimiterDefrost": obj.get("rpmLimiterDefrost"),
            "rpmLimiterSilentHours": obj.get("rpmLimiterSilentHours"),
            "rpmLimiterHPControl": obj.get("rpmLimiterHPControl"),
            "rpmLimiterPressure": obj.get("rpmLimiterPressure"),
            "rpmLimiterWaterOut": obj.get("rpmLimiterWaterOut"),
            "rpmLimiterEnvelope": obj.get("rpmLimiterEnvelope"),
            "rpmLimiterHouseIn": obj.get("rpmLimiterHouseIn"),
            "pCompressorInAverage": obj.get("pCompressorInAverage"),
            "pCompressorInMin": obj.get("pCompressorInMin"),
            "pCompressorInMax": obj.get("pCompressorInMax"),
            "pCompressorOutAverage": obj.get("pCompressorOutAverage"),
            "pCompressorOutMin": obj.get("pCompressorOutMin"),
            "pCompressorOutMax": obj.get("pCompressorOutMax"),
            "pCompressorInTargetAverage": obj.get("pCompressorInTargetAverage"),
            "pCompressorInTargetMin": obj.get("pCompressorInTargetMin"),
            "pCompressorInTargetMax": obj.get("pCompressorInTargetMax"),
            "tInverterAverage": obj.get("tInverterAverage"),
            "tInverterMin": obj.get("tInverterMin"),
            "tInverterMax": obj.get("tInverterMax"),
            "tCompressorInAverage": obj.get("tCompressorInAverage"),
            "tCompressorInMin": obj.get("tCompressorInMin"),
            "tCompressorInMax": obj.get("tCompressorInMax"),
            "tCompressorOutAverage": obj.get("tCompressorOutAverage"),
            "tCompressorOutMin": obj.get("tCompressorOutMin"),
            "tCompressorOutMax": obj.get("tCompressorOutMax"),
            "tCompressorInTransientAverage": obj.get("tCompressorInTransientAverage"),
            "tCompressorInTransientMin": obj.get("tCompressorInTransientMin"),
            "tCompressorInTransientMax": obj.get("tCompressorInTransientMax"),
            "tCompressorOutTransientAverage": obj.get("tCompressorOutTransientAverage"),
            "tCompressorOutTransientMin": obj.get("tCompressorOutTransientMin"),
            "tCompressorOutTransientMax": obj.get("tCompressorOutTransientMax"),
            "deltaTCompressorInSuperheatAverage": obj.get("deltaTCompressorInSuperheatAverage"),
            "deltaTCompressorInSuperheatMin": obj.get("deltaTCompressorInSuperheatMin"),
            "deltaTCompressorInSuperheatMax": obj.get("deltaTCompressorInSuperheatMax"),
            "compressorPowerLowAccuracyAverage": obj.get("compressorPowerLowAccuracyAverage"),
            "compressorPowerLowAccuracyMin": obj.get("compressorPowerLowAccuracyMin"),
            "compressorPowerLowAccuracyMax": obj.get("compressorPowerLowAccuracyMax"),
            "fanAverage": obj.get("fanAverage"),
            "fanMin": obj.get("fanMin"),
            "fanMax": obj.get("fanMax"),
            "fanPowerAverage": obj.get("fanPowerAverage"),
            "fanPowerMin": obj.get("fanPowerMin"),
            "fanPowerMax": obj.get("fanPowerMax"),
            "cmMassPowerInAverage": obj.get("cmMassPowerInAverage"),
            "cmMassPowerOutAverage": obj.get("cmMassPowerOutAverage"),
            "temperatureErrorIntegralAverage": obj.get("temperatureErrorIntegralAverage"),
            "temperatureErrorIntegralMin": obj.get("temperatureErrorIntegralMin"),
            "temperatureErrorIntegralMax": obj.get("temperatureErrorIntegralMax"),
            "thermostatStateOff": obj.get("thermostatStateOff"),
            "thermostatStateOn": obj.get("thermostatStateOn"),
            "tRoomAverage": obj.get("tRoomAverage"),
            "tRoomMin": obj.get("tRoomMin"),
            "tRoomMax": obj.get("tRoomMax"),
            "tRoomTargetAverage": obj.get("tRoomTargetAverage"),
            "tRoomTargetMin": obj.get("tRoomTargetMin"),
            "tRoomTargetMax": obj.get("tRoomTargetMax"),
            "tThermostatSetpointAverage": obj.get("tThermostatSetpointAverage"),
            "tThermostatSetpointMin": obj.get("tThermostatSetpointMin"),
            "tThermostatSetpointMax": obj.get("tThermostatSetpointMax"),
            "otBoilerFeedTemperatureAverage": obj.get("otBoilerFeedTemperatureAverage"),
            "otBoilerFeedTemperatureMin": obj.get("otBoilerFeedTemperatureMin"),
            "otBoilerFeedTemperatureMax": obj.get("otBoilerFeedTemperatureMax"),
            "otBoilerReturnTemperatureAverage": obj.get("otBoilerReturnTemperatureAverage"),
            "otBoilerReturnTemperatureMin": obj.get("otBoilerReturnTemperatureMin"),
            "otBoilerReturnTemperatureMax": obj.get("otBoilerReturnTemperatureMax")
        })
        return _obj


