Ugly fix:
weather_data = weather_data[:len(sh_profile)]
weather_data[pd.isna(weather_data)] = np.min(weather_data[pd.notna(weather_data)])
temp_brine_ = temp_brine[:len(sh_profile)]
and
low_temp = kelvin_offset+tech_instance._cop_source_constant_temperature_value if tech_instance._cop_source_temperature == 'constant_temperature' else kelvin_offset+weather_data
low_temp[pd.isna(low_temp)] = np.min(low_temp[pd.notna(low_temp)])
carnot_eff = hot_temp / (hot_temp - low_temp)
in COP calculation (may cause freezing temperatures in summer)
Ugly fix:
and
in COP calculation (may cause freezing temperatures in summer)