Changes to temperature handling (more)
This commit is contained in:
parent
27acb96b65
commit
c2b6ba2cee
3 changed files with 6 additions and 6 deletions
|
|
@ -45,7 +45,7 @@ def location_to_weather_stn(location_loc):
|
|||
|
||||
return (station_array[ii[0]][0], station_array[ii[0]][1], station_array[ii[0]][2], station_array[ii[0]][3])
|
||||
|
||||
def location_celcius_per_hour(location):
|
||||
def location_celcius_per_hour(location: object) -> object:
|
||||
#expects a tuple (lat, long)
|
||||
#returns a json format set of weather data
|
||||
w_station = location_to_weather_stn(location)
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ def test_ventilation_slidingwindow(baseline_form: model_generator.FormData):
|
|||
window = models.SlidingWindow(
|
||||
active=models.PeriodicInterval(period=120, duration=10),
|
||||
inside_temp=models.PiecewiseConstant((0, 24), (293,)),
|
||||
outside_temp=data.GenevaTemperatures['Dec'],
|
||||
outside_temp=data.Temperatures['12'],
|
||||
window_height=1.6, opening_length=0.6,
|
||||
)
|
||||
baseline_form.ventilation_type = 'natural_ventilation'
|
||||
|
|
@ -45,7 +45,7 @@ def test_ventilation_slidingwindow(baseline_form: model_generator.FormData):
|
|||
baseline_form.windows_frequency = 120
|
||||
baseline_form.window_opening_regime = 'windows_open_periodically'
|
||||
baseline_form.window_type = 'window_sliding'
|
||||
baseline_form.event_month = 'December'
|
||||
baseline_form.event_month = '12'
|
||||
baseline_form.window_height = 1.6
|
||||
baseline_form.opening_distance = 0.6
|
||||
|
||||
|
|
@ -59,7 +59,7 @@ def test_ventilation_hingedwindow(baseline_form: model_generator.FormData):
|
|||
window = models.HingedWindow(
|
||||
active=models.PeriodicInterval(period=120, duration=10),
|
||||
inside_temp=models.PiecewiseConstant((0, 24), (293,)),
|
||||
outside_temp=data.GenevaTemperatures['Dec'],
|
||||
outside_temp=data.Temperatures['12'],
|
||||
window_height=1.6, window_width=1., opening_length=0.6,
|
||||
)
|
||||
baseline_form.ventilation_type = 'natural_ventilation'
|
||||
|
|
@ -112,7 +112,7 @@ def test_ventilation_window_hepa(baseline_form: model_generator.FormData):
|
|||
window = models.SlidingWindow(
|
||||
active=models.PeriodicInterval(period=120, duration=10),
|
||||
inside_temp=models.PiecewiseConstant((0, 24), (293,)),
|
||||
outside_temp=data.GenevaTemperatures['Dec'],
|
||||
outside_temp=data.Temperatures['12'],
|
||||
window_height=1.6, opening_length=0.6,
|
||||
)
|
||||
hepa = models.HEPAFilter(
|
||||
|
|
|
|||
|
|
@ -81,5 +81,5 @@ def test_piecewiseconstant_vs_interval(time):
|
|||
|
||||
|
||||
def test_piecewiseconstant_transition_times():
|
||||
outside_temp = data.GenevaTemperatures['1']
|
||||
outside_temp = data.Temperatures['1']
|
||||
assert set(outside_temp.transition_times) == outside_temp.interval().transition_times()
|
||||
|
|
|
|||
Loading…
Reference in a new issue