#hide
from google.colab import drive
'/content/gdrive', force_remount=True)
drive.mount(= "/content/gdrive/My Drive"
root_dir = root_dir + '/Powell/SD.I_Inventory_Problems/DynamicTrading' base_dir
Mounted at /content/gdrive
Using the Powell Unified Framework & Sequential Decision Analytics to find the optimal time to buy and sell assets
Kobus Esterhuysen
August 8, 2023
August 17, 2024
The overall structure of this project and report follows the traditional CRISP-DM format. However, instead of the CRISP-DM’S “4 Modeling” section, we inserted the “6 step modeling process” of Dr. Warren Powell in section 4 of this document. Dr Powell’s universal framework shows great promise for unifying the formalisms of at least a dozen different fields. Using his framework enables easier access to thinking patterns in these other fields that might be beneficial and informative to the sequential decision problem at hand. Traditionally, this kind of problem would be approached from the reinforcement learning perspective. However, using Dr. Powell’s wider and more comprehensive perspective almost certainly provides additional value.
Here is information on Dr. Powell’s perspective on Sequential Decision Analytics.
In order to make a strong mapping between the code in this notebook and the mathematics in the Powell Universal Framework (PUF), we follow the following convention for naming Python identifier names:
Rhat__fail_tt1_a
which is read: “Rhatfail at t+1 of/with (attribute) a”X__pi
, is read X piXpi
instead of X__pi
, or MSpend_t
instead of M__Spend_t
S_t
, is read ‘S at t’M__Spend_t
which is read: “MSpend at t”Rhat__fail_tt1_a
which is read: “Rhatfail at t+1 of/with (attribute) a” [RLSO-p436]X__piIS_tI
, is read ‘X pi in S at t’I
’s are used to imitate the parentheses around the argumentR_tt1
, is read ‘R at t+1’R__nt1
, is read ‘R at n+1’F
for terminal rewardcumF
for cumulative rewardC
for terminal rewardcumC
for cumulative rewardS_t.R_t
and S_t.p_t
, is read ‘S at t in R at t, and, S at t in p at t’self.State = namedtuple('State', SVarNames)
for the ‘class’ of the vectorself.S_t
for the ‘instance’ of the vectorx_t.x_t_GB
and x_t.x_t_BL
, is read ‘x at t in x at t for GB, and, x at t in x at t for BL’self.Decision = namedtuple('Decision', xVarNames)
for the ‘class’ of the vectorself.x_t
for the ‘instance’ of the vectorThis project deals with a client need relating to making optimal investment decisions regarding a given portfolio. Although we only provide for two financial instruments (stocks, bonds, funds, etc.) in the present example, the code can easily be expanded to provide for multiple financial instruments. A decision can handle buy, hold, or sell options.
This project builds upon a previous project: https://learnableloop.com/posts/assetselling_port
#hide
from google.colab import drive
drive.mount('/content/gdrive', force_remount=True)
root_dir = "/content/gdrive/My Drive"
base_dir = root_dir + '/Powell/SD.I_Inventory_Problems/DynamicTrading'
Mounted at /content/gdrive
# import pdb
# pdb.set_trace()
from collections import namedtuple, defaultdict
import pandas as pd
import numpy as np
import random
import matplotlib.pyplot as plt
from matplotlib.ticker import FormatStrFormatter
import matplotlib as mpl
from copy import copy
import math
pd.options.display.float_format = '{:,.4f}'.format
pd.set_option('display.max_columns', None)
pd.set_option('display.max_rows', None)
pd.set_option('display.max_colwidth', None)
! python --version
Python 3.10.12
The parameters of the system-under-steer (SUS) are:
# PARAMETERS
SNAMES = [ #state variable names
'R_t', #resource
'R0_t', #cash
'p_t', #price
]
xNAMES = ['x_t'] #decision variable names
eNAMES = ['AAA', 'BBB']
piNAMES = ['X__HighLow'] #policy names
thNAMES = ['thLo', 'thHi'] #theta names
SEED_TRAIN = 77777777
SEED_EVALU = 88888888
N_SAMPLEPATHS = 500
N_TRANSITIONS = 40
x = ['Up', 'Neutral', 'Down']
W_BIAS_CDFS = pd.DataFrame(
[[.9, 1., 1.], #'Up' cdf
[.2, .8, 1.], #'Neutral' cdf
[0., .1, 1.]], #'Down' cdf
index=x,
columns=x,
)
W_BIAS_CDFS
INIT_PRICE = {eNAMES[0]: 179.23, eNAMES[1]: 85.4}
INIT_BIAS = {en: 'Neutral' for en in eNAMES}
W_UP_STEP = 1
W_DOWN_STEP = -1
W_VARIANCE = 2
INIT_RESOURCE = {eNAMES[0]: 20, eNAMES[1]: 30}
INIT_CASH = 1_000.00
S_0_INFO = {
'R_t': {en: INIT_RESOURCE[en] for en in eNAMES},
'R0_t': INIT_CASH,
'p_t': {en: INIT_PRICE[en] for en in eNAMES},
}
# 'AAA' 'BBB'
TH_HI = {eNAMES[0]: (200.0, 200.5, .1), eNAMES[1]: (90.0, 90.5, .1)}
TH_LO = {eNAMES[0]: (168.0, 168.5, .1), eNAMES[1]: (72.0, 72.5, .1)}
class PriceSimulator():
def __init__(self,
biasCdfs=W_BIAS_CDFS,
upStep=W_UP_STEP,
downStep=W_DOWN_STEP,
variance=W_VARIANCE,
seed=None):
self.biasCdfs = biasCdfs
self.upStep = upStep
self.downStep = downStep
self.variance = variance
self.prng = np.random.RandomState(seed)
self.bias = 'Neutral'
def simulate(self): #assume the change in price is normal with mean bias and variance 2
phat_tt1_dict = {}
b_tt1_dict = {}
b_tt1_val_dict = {}
for e in eNAMES:
b_t = self.prng.choice(['Down', 'Neutral', 'Up'])
biasCdf = self.biasCdfs.loc[[b_t]]
coin = self.prng.random_sample()
if (coin < float(biasCdf['Up'])):
b_tt1 = 'Up' #new bias
b_tt1_val = self.upStep #bias
elif (coin >= float(biasCdf['Up']) and coin < float(biasCdf['Neutral'])): #.
b_tt1 = 'Neutral' #new bias
b_tt1_val = 0 #bias
else:
b_tt1 = 'Down' #new bias
b_tt1_val = self.downStep #bias
self.bias = b_tt1
# phat_tt1 = self.prng.normal(b_tt1_val, self.variance) #change in price
phat_tt1_dict[e] = self.prng.normal(b_tt1_val, self.variance) #change in price
b_tt1_dict[e] = b_tt1
b_tt1_val_dict[e] = b_tt1_val
W_tt1 = {
"p_t": {e: phat_tt1_dict[e] for e in eNAMES},
"b_t": {e: b_tt1_dict[e] for e in eNAMES}, #just for display
"b_t_val": {e: b_tt1_val_dict[e] for e in eNAMES} #just for display
}
return W_tt1
def plot_output(self, df1):
n_charts = 3
ylabelsize = 16
mpl.rcParams['lines.linewidth'] = 1.2
default_colors = plt.rcParams['axes.prop_cycle'].by_key()['color']
fig, axs = plt.subplots(n_charts, sharex=True)
fig.set_figwidth(13); fig.set_figheight(9)
fig.suptitle('Price Simulation', fontsize=20)
xi = 0
axs[xi].set_title(f'')
axs[xi].set_ylim(auto=True); axs[xi].spines['top'].set_visible(False); axs[xi].spines['right'].set_visible(True); axs[xi].spines['bottom'].set_visible(False)
for e in eNAMES:
axs[xi].step(df1[f'p_t_{e}'], random.choice(default_colors), where='post')
axs[xi].axhline(y=0, color='k', linestyle=':')
y1ab = '$p_{t}$'
axs[xi].set_ylabel(y1ab, rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize)
xi = 1
axs[xi].set_ylim(auto=True); axs[xi].spines['top'].set_visible(False); axs[xi].spines['right'].set_visible(True); axs[xi].spines['bottom'].set_visible(False)
for e in eNAMES:
axs[xi].step(df1[f'b_t_val_{e}'], random.choice(default_colors), where='post')
axs[xi].axhline(y=0, color='k', linestyle=':')
y1ab = '$b_{t,val}$'
axs[xi].set_ylabel(y1ab, rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize)
xi = 2
axs[xi].set_ylim(auto=True); axs[xi].spines['top'].set_visible(False); axs[xi].spines['right'].set_visible(True); axs[xi].spines['bottom'].set_visible(False)
for e in eNAMES:
axs[xi].step(df1[f'b_t_{e}'], random.choice(default_colors), where='post')
y1ab = '$b_{t}$'
axs[xi].set_ylabel(y1ab, rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize)
axs[xi].set_xlabel('$t$', rotation=0, ha='center', va='center', fontweight='bold', size=ylabelsize)
Up | Neutral | Down | |
---|---|---|---|
Up | 0.9000 | 1.0000 | 1.0000 |
Neutral | 0.2000 | 0.8000 | 1.0000 |
Down | 0.0000 | 0.1000 | 1.0000 |
price_sim = PriceSimulator(seed=SEED_TRAIN)
T__sim = 20
PriceData = []
for i in range(T__sim):
res = price_sim.simulate()
entry = [itm[1][e] for itm in list(res.items()) for e in eNAMES]
PriceData.append(entry)
labels = [f'{itm[0]}_{e}' for itm in list(res.items()) for e in eNAMES]
df = pd.DataFrame.from_records(data=PriceData, columns=labels); df[:10]
# df = pd.DataFrame.from_records(data=PriceData); df[:10]
p_t_AAA | p_t_BBB | b_t_AAA | b_t_BBB | b_t_val_AAA | b_t_val_BBB | |
---|---|---|---|---|---|---|
0 | 0.3365 | 3.1084 | Up | Neutral | 1 | 0 |
1 | 2.0958 | 1.1369 | Neutral | Neutral | 0 | 0 |
2 | 0.7226 | -1.1433 | Up | Up | 1 | 1 |
3 | 3.9397 | -0.4858 | Neutral | Down | 0 | -1 |
4 | 2.1811 | 0.4218 | Down | Down | -1 | -1 |
5 | -2.3785 | -0.0162 | Up | Up | 1 | 1 |
6 | -3.9910 | -0.3274 | Neutral | Down | 0 | -1 |
7 | -3.5321 | 3.9864 | Down | Up | -1 | 1 |
8 | -3.1872 | 1.2238 | Down | Up | -1 | 1 |
9 | -0.1920 | 0.7166 | Up | Up | 1 | 1 |
We will use the data provided by the simulator directly. There is no need to perform additional data preparation.
We are holding assets in a portfolio and we are looking for the best time to buy/sell each asset.
For an asset to be bought, its price has to fall below a lower value (specific to the asset). All the available cash is used to buy shares of such an asset. In the case of more than one asset being below their lower value, the available cash is equally divided between the assets to be purchased.
When one or more assets rise above a higher value (specific to each asset), such assets are sold.
We assume that our decisions in the current project do not affect the price of any of the assets. The prices vary according to a stochastic process (as coded in the above price simulator).
In this project, we use two fictitious asset (ticker) names: ‘AAA’ and ‘BBB’.
This section attempts to answer three important questions:
For this problem, the only metric we are interested in is the amount of profit we make after each decision window. A single type of decision needs to be made at the start of each window - whether for each asset we want to buy, hold, or sell the asset at its current price. The only source of uncertainty is the prices of the assets.
A Python class is used to implement the model for the SUS (System-Under-Steer):
class Model():
def __init__(self, S_0_info):
...
...
The state variables represent what we need to know.
The state is:
\(S_t = (R_t, R^0_t, p_t)\)
The state variables are represented by the following variables in the Model
class:
self.State = namedtuple('State', SNAMES) # 'class'
self.S_t = self.build_state(info) # 'instance'
where
SNAMES = [ #state variable names
'R_t', #resource
'R0_t', #cash
'p_t', #price
]
The decision variables represent what we control.
The decision variables are represented by the following variables in the Model
class:
self.Decision = namedtuple('Decision', xNAMES) # 'class'
where
xNAMES = ['x_t']
eNAMES = ['AAA', 'BBB']
The exogenous information variables represent what we did not know (when we made a decision). These are the variables that we cannot control directly. The information in these variables become available after we make the decision \(x_t\).
When we assume that the price in each time period is revealed, without any model to predict the price based on past prices, we have, using approach 1:
\[ p_{t+1} = W_{t+1} \]
Alternatively, when we assume that we observe the change in price \(\hat{p}_{t+1}=p_{t+1}-p_{t}\), we have, using approach 2:
\[ \begin{aligned} p_{t+1} &= p_t + W_{t+1} \\ &= p_t + \hat{p}_{t+1} \end{aligned} \]
We will make use of approach 2 which means that the exogenous information, \(W_{t+1}\), is the observed change in price of the share.
The exogenous information is obtained by a call to
SIM = PriceSimulator.simulate(...)
where SIM
is a global variable.
The latest exogenous information can be accessed by calling the following method from class Model()
, which returns a simulated price change for each asset:
def W_fn(self, t):
W_tt1 = SIM.simulate()
return W_ttl
The transition function describes how the state variables evolve over time. Because we currently have three state variables in the state, \(S_t=(R_t,R^0_t, p_t)\), we have the equations:
For a position in a stock \(R_{te}\): \[ \begin{aligned} R_{t+1,e} &= R_{te} + x_{te} \quad \mathrm{(RLSO-eq13.13)} \end{aligned} \]
For a position in cash \(R_{t,0}\): \[ \begin{aligned} R^0_{t+1} &= R^0_{t} - \sum_{e=1}^M x_{te}p_{te} \quad \mathrm{(RLSO-eq13.14)} \end{aligned} \]
For the price \(p_{t}\): \[ \begin{aligned} p_{t+1,e} &= p_{te} + \hat{p}_{t+1,e} \quad \mathrm{(RLSO-eq13.15)} \end{aligned} \]
Collectively, they represent the general transition function:
\[ S_{t+1} = S^M(S_t, X^{\pi}(S_t|\theta), W_{t+1}) \]
The objective function captures the performance metrics of the solution to the problem.
The transaction cost per transition/step is: \[ \begin{align} C_t(S_t,x_t) = -c^{trans}\sum_{e=1}^M|x_{te}| p_{te}, \mathrm{for\ } t=0, ..., T-1 \end{align} \] where
The risk at the end of the day is: \[ \begin{align} \rho(R_t) = R'_t \Sigma R_t \end{align} \] where \(\Sigma\) is the covariance matrix of returns, which we assume we have estimated from historical data in advance.
The final-period contributions function is given by: \[ \begin{align} C_T(S_T,x_T) = R^0_{T} + \sum_{e=1}^M R_{Te}p_{Te} - \rho(R_T) \end{align} \]
The objective function is: \[ \max_{\pi}\mathbb{E}\{\sum_{t=0}^{T}C_t(S_t, X^{\pi}_t(S_t)) | S_0 \} \]
In practice, the expectation is approximated by using historical prices, which avoids the need to develop an underlying stochastic model.
class Model():
def __init__(self, S_0_info):
self.S_0_info = S_0_info
self.State = namedtuple('State', SNAMES) #. 'class'
self.S_t = self.build_state(S_0_info) #. 'instance'
self.Decision = namedtuple('Decision', xNAMES) #. 'class'
self.Ccum = 0.0 #. cumulative reward
def build_state(self, info):
return self.State(*[info[sn] for sn in SNAMES])
def build_decision(self, info):
return self.Decision(*[info[xn] for xn in xNAMES])
# exogenous information, dependent on a random process (the change in price)
def W_fn(self):
W_tt1 = SIM.simulate()
return W_tt1
def S__M_fn(self, S_t, x_t, W_tt1, theta, piName):
# print(f'...in S__M_fn()...\n\t{S_t=}\n\t{x_t=}\n\t{W_tt1=}\n\t{theta=}')
# R_t
R_tt1 = {}
for en in eNAMES:
R_tt1[en] = S_t.R_t[en] + x_t.x_t[en]
# R0_t
cost = 0.0
for en in eNAMES:
cost += x_t.x_t[en]*S_t.p_t[en]
R0_tt1 = S_t.R0_t - cost
# p_t
# W_tt1['p_t'] has CHANGE in price
# clipped at a penny, else division by zero in X__HighLow
p_t = S_t.p_t
p_tt1 = {}
for en in eNAMES:
p_tt1[en] = max(0.01, p_t[en] + W_tt1['p_t'][en])
S_tt1 = self.build_state({
'R_t': R_tt1,
'R0_t': R0_tt1,
'p_t': p_tt1,
})
return S_tt1
def C_fn(self, S_t, x_t, W_tt1):
# print(f'...in C_fn()...\n\t{S_t=}\n\t{x_t=}\n\t{W_tt1=}')
C_t = 0.0
for en in eNAMES:
C_t += -S_t.p_t[en]*x_t.x_t[en]
return C_t
def step(self, x_t, theta, piName):
# print(f'...in step()...\n\t{x_t=}\n\t{theta=}')
W_tt1 = self.W_fn()
C = self.C_fn(self.S_t, x_t, W_tt1)
self.Ccum += C
self.S_t = self.S__M_fn(self.S_t, x_t, W_tt1, theta, piName)
return (self.S_t, self.Ccum, x_t, W_tt1['b_t_val']) #. for plotting
We will simulate the share price \(p_{t+1} = p_t + \hat{p}_{t+1} = p_t + W_{t+1}\) as described in section 2, for each asset.
There are two main meta-classes of policy design. Each of these has two subclasses:
In this project we will make use of a single policy from the PFA class:
where
\[ X^{HighLow}(S_{te}|\theta^{HighLow}) = \begin{cases} -1 & \text{if } p_{te} < \theta^{low}_e \text{ or } p_{te} > \theta^{high}_e \\ -1 & \text{if } t = T \text{ and } R_{te} = 1 \\ 0 & \text{otherwise } \end{cases} \] for each asset \(e \in \mathcal{E}\)
class Policy():
def __init__(self, model):
self.model = model
self.Policy = namedtuple('Policy', piNAMES) #. 'class'
self.Theta = namedtuple('Theta', thNAMES) #. 'class'
def build_policy(self, info):
return self.Policy(*[info[pin] for pin in piNAMES])
def build_theta(self, info):
return self.Theta(*[info[thn] for thn in thNAMES])
def X__HighLow(self, t, S_t, theta):
# print(f'...in X__HighLow()...\n\t{t=}\n\t{S_t=}\n\t{theta=}')
x_t_info = {
'x_t': {en: 0 for en in eNAMES} #default is hold
}
# print(f'\t%%% {S_t.R0_t=}, {S_t.R_t=}, {S_t.p_t=}')
tickersToSell = []
tickersToBuy = []
# sell all at end of horizon
if (t == T - 1):
tickersToSell = [en for en in eNAMES]
for ticker in tickersToSell:
nShares = S_t.R_t[ticker]
x_t_info['x_t'][ticker] = -nShares
return self.model.build_decision(x_t_info)
# identify buys and sells
for en in eNAMES:
if (S_t.p_t[en] < theta.thLo[en]): #buy
tickersToBuy.append(en)
elif (S_t.p_t[en] > theta.thHi[en]): #sell
tickersToSell.append(en)
totalFunds = S_t.R0_t; #print(f'\t%%% {totalFunds=}')
# sell
# print(f'\t%%% {tickersToSell=}')
if len(tickersToSell) > 0:
for ticker in tickersToSell:
nShares = S_t.R_t[ticker]
x_t_info['x_t'][ticker] = -nShares
totalFunds += nShares*S_t.p_t[ticker]
# print(f'\t%%% totalFunds after selling: {totalFunds}')
# buy
# print(f'\t%%% {tickersToBuy=}')
if len(tickersToBuy) > 0:
availFundsPerTicker = totalFunds/len(tickersToBuy); #print(f'{availFundsPerTicker=}')
for ticker in tickersToBuy:
nShares = int(availFundsPerTicker/S_t.p_t[ticker])
x_t_info['x_t'][ticker] = +nShares
totalFunds -= nShares*S_t.p_t[ticker]
# print(f'\t%%% totalFunds after buying: {totalFunds}')
return self.model.build_decision(x_t_info)
def grid_search_thetas_4(self, thetasLo, thetasHi):
thetas = [
self.build_theta({'thLo': {eNAMES[0]: th0, eNAMES[1]: th1}, 'thHi': {eNAMES[0]: th2, eNAMES[1]: th3}})
for th0 in thetasLo[eNAMES[0]]
for th1 in thetasLo[eNAMES[1]]
for th2 in thetasHi[eNAMES[0]]
for th3 in thetasHi[eNAMES[1]]
]
return thetas
def grid_search_thetas_2(self, thetas1, thetas2):
thetas = [(th1, th2) for th1 in thetas1 for th2 in thetas2]
return thetas
def grid_search_thetas_1(self, thetas1):
thetas = [(th1,) for th1 in thetas1]
return thetas
def run_policy_sample_paths(self, theta, piName, record):
CcumIomega__lI = []
for l in list(range(L)): #for each sample-path
# print(f'%%% {l=}')
M = Model(S_0_INFO)
P = Policy(M)
# SIM = PriceSimulator(seed=SEED_TRAIN)
record_l = [piName, theta, l]
for t in range(T): #for each transition/step
# print(f'\t%%% {t=}')
x_t = getattr(self, piName)(t, M.S_t, theta)
S_t, Ccum, x_t, b_t_val = M.step(x_t, theta, piName)
record_t = [t] + \
[S_t.R_t[en] for en in eNAMES] + [S_t.R0_t] + [S_t.p_t[en] for en in eNAMES] + \
[Ccum] + \
[x_t.x_t[en] for en in eNAMES] + \
[b_t_val[en] for en in eNAMES] #rather than b_t which is text and not ordered
record.append(record_l + record_t)
CcumIomega__lI.append(M.Ccum)
return CcumIomega__lI
def perform_grid_search_sample_paths(self, piName, thetas):
Cbarcum = defaultdict(float)
Ctilcum = defaultdict(float)
expCbarcum = defaultdict(float)
expCtilcum = defaultdict(float)
num_thetas = len(thetas)
record = []
print(f'{num_thetas=}'); print(f'{thetas=}')
nth = 20
i = 0; print(f'... printing every {nth}th theta if considered ...')
for theta in thetas:
# print(f'\n=== {theta=} ===')
if i%nth == 0: print(f'=== ({i:,} / {num_thetas:,}), theta={self.round_theta(theta)} ===')
CcumIomega__lI = self.run_policy_sample_paths(theta, piName, record)
Cbarcum_tmp = np.array(CcumIomega__lI).mean()
Ctilcum_tmp = np.sum(np.square(np.array(CcumIomega__lI) - Cbarcum_tmp))/(L - 1)
# theta=({'AAA': 168.0, 'BBB': 72.0}, {'AAA': 200.0, 'BBB': 90.0})
# a dict cannot be used as a key, so we define
# theta_key = ((168.0, 72.0), (200.0, 90.0)):
theta_key = tuple(tuple(itm.values()) for itm in theta)
Cbarcum[theta_key] = Cbarcum_tmp
Ctilcum[theta_key] = np.sqrt(Ctilcum_tmp/L)
best_theta = max(Cbarcum, key=Cbarcum.get)
worst_theta = min(Cbarcum, key=Cbarcum.get)
expCbarcum_tmp = pd.Series(CcumIomega__lI).expanding().mean()
expCbarcum[theta_key] = expCbarcum_tmp
expCtilcum_tmp = pd.Series(CcumIomega__lI).expanding().std()
expCtilcum[theta_key] = expCtilcum_tmp
i += 1
best_Cbarcum = Cbarcum[best_theta]
best_Ctilcum = Ctilcum[best_theta]
worst_Cbarcum = Cbarcum[worst_theta]
worst_Ctilcum = Ctilcum[worst_theta]
thetaStar_expCbarcum = expCbarcum[best_theta]
thetaStar_expCtilcum = expCtilcum[best_theta]
thetaStar_expCtilcum[0] = 0 #set NaN to 0
best_theta_w_enames = tuple(( ({eNAMES[0]: itm[0], eNAMES[1]: itm[1]})) for itm in best_theta)
best_theta_en = self.build_theta({'thLo': best_theta_w_enames[0], 'thHi': best_theta_w_enames[1]})
print(f'best_theta_en:\n{best_theta_en}\n{best_Cbarcum=:.2f}\n{best_Ctilcum=:.2f}')
worst_theta_w_enames = tuple(( ({eNAMES[0]: itm[0], eNAMES[1]: itm[1]})) for itm in worst_theta)
worst_theta_en = self.build_theta({'thLo': worst_theta_w_enames[0], 'thHi': worst_theta_w_enames[1]})
print(f'worst_theta_en:\n{worst_theta_en}\n{worst_Cbarcum=:.2f}\n{worst_Ctilcum=:.2f}')
return \
thetaStar_expCbarcum, thetaStar_expCtilcum, \
Cbarcum, Ctilcum, \
best_theta_en, worst_theta_en, \
best_Cbarcum, worst_Cbarcum, \
best_Ctilcum, worst_Ctilcum, \
record
def round_theta(self, complex_theta):
thetas_rounded = []
for theta in complex_theta:
evalues_rounded = []
for _, evalue in theta.items():
evalues_rounded.append(float(f"{evalue:f}"))
thetas_rounded.append(tuple(evalues_rounded))
return str(tuple(thetas_rounded))
def plot_Fhat_map(self, FhatI_theta_I, thetasX, thetasY, labelX, labelY, title):
Fhat_values = [FhatI_theta_I[(thetaX,thetaY)] for thetaY in thetasY for thetaX in thetasX]
Fhats = np.array(Fhat_values)
increment_count = len(thetasX)
Fhats = np.reshape(Fhats, (-1, increment_count))#.
fig, ax = plt.subplots()
im = ax.imshow(Fhats, cmap='hot', origin='lower', aspect='auto')
# create colorbar
cbar = ax.figure.colorbar(im, ax=ax)
# cbar.ax.set_ylabel(cbarlabel, rotation=-90, va="bottom")
# ax.set_xticks(np.arange(0, len(thetasX), 5))#.
ax.set_xticks(np.arange(len(thetasX)))
# ax.set_yticks(np.arange(0, len(thetasY), 5))#.
ax.set_yticks(np.arange(len(thetasY)))
# NOTE: round tick labels, else very messy
# function round() does not work, have to do this way
thetasX_form = [f'{th:.1f}' for th in thetasX]
thetasY_form = [f'{th:.1f}' for th in thetasY]
# ax.set_xticklabels(thetasX[::5])#.
# ax.set_xticklabels(thetasX)
ax.set_xticklabels(thetasX_form)
# ax.set_yticklabels(thetasY[::5])#.
# ax.set_yticklabels(thetasY)
ax.set_yticklabels(thetasY_form)
# rotate the tick labels and set their alignment.
#plt.setp(ax.get_xticklabels(), rotation=45, ha="right",rotation_mode="anchor")
ax.set_title(title)
ax.set_xlabel(labelX)
ax.set_ylabel(labelY)
#fig.tight_layout()
plt.show()
return True
def plot_Fhat_map_4(self, FhatI_theta_I, thetasX, thetasY, labelX, labelY, title, thetaFixed1, thetaFixed2):
# Fhat_values = [FhatI_theta_I[(thetaX,thetaY)] for thetaY in thetasY for thetaX in thetasX]
Fhat_values = [FhatI_theta_I[((thetaX,thetaY), (thetaFixed1,thetaFixed2))] for thetaY in thetasY for thetaX in thetasX]
Fhats = np.array(Fhat_values)
increment_count = len(thetasX)
Fhats = np.reshape(Fhats, (-1, increment_count))#.
fig, ax = plt.subplots()
im = ax.imshow(Fhats, cmap='hot', origin='lower', aspect='auto')
# create colorbar
cbar = ax.figure.colorbar(im, ax=ax)
# cbar.ax.set_ylabel(cbarlabel, rotation=-90, va="bottom")
# ax.set_xticks(np.arange(0, len(thetasX), 5))#.
ax.set_xticks(np.arange(len(thetasX)))
# ax.set_yticks(np.arange(0, len(thetasY), 5))#.
ax.set_yticks(np.arange(len(thetasY)))
# NOTE: round tick labels, else very messy
# function round() does not work, have to do this way
thetasX_form = [f'{th:.1f}' for th in thetasX]
thetasY_form = [f'{th:.1f}' for th in thetasY]
# ax.set_xticklabels(thetasX[::5])#.
# ax.set_xticklabels(thetasX)
ax.set_xticklabels(thetasX_form)
# ax.set_yticklabels(thetasY[::5])#.
# ax.set_yticklabels(thetasY)
ax.set_yticklabels(thetasY_form)
# rotate the tick labels and set their alignment.
#plt.setp(ax.get_xticklabels(), rotation=45, ha="right",rotation_mode="anchor")
ax.set_title(title)
ax.set_xlabel(labelX)
ax.set_ylabel(labelY)
#fig.tight_layout()
plt.show()
return True
# color_style examples: 'r-', 'b:', 'g--'
def plot_Fhat_chart(self, FhatI_theta_I, thetasX, labelX, labelY, title, color_style, thetaStar):
mpl.rcParams['lines.linewidth'] = 1.2
xylabelsize = 16
# plt.figure(figsize=(13, 9))
plt.figure(figsize=(13, 4))
plt.title(title, fontsize=20)
Fhats = FhatI_theta_I.values()
plt.plot(thetasX, Fhats, color_style)
plt.axvline(x=thetaStar, color='k', linestyle=':')
plt.xlabel(labelX, rotation=0, labelpad=10, ha='right', va='center', fontweight='bold', size=xylabelsize)
plt.ylabel(labelY, rotation=0, labelpad=1, ha='right', va='center', fontweight='normal', size=xylabelsize)
plt.show()
# expanding Fhat chart
def plot_expFhat_chart(self, df, labelX, labelY, title, color_style):
mpl.rcParams['lines.linewidth'] = 1.2
xylabelsize = 16
plt.figure(figsize=(13, 4))
plt.title(title, fontsize=20)
plt.plot(df, color_style)
plt.xlabel(labelX, rotation=0, labelpad=10, ha='right', va='center', fontweight='bold', size=xylabelsize)
plt.ylabel(labelY, rotation=0, labelpad=1, ha='right', va='center', fontweight='normal', size=xylabelsize)
plt.show()
# expanding Fhat charts
def plot_expFhat_charts(self, means, stdvs, labelX, labelY, suptitle, pars=defaultdict(str)):
n_charts = 2
xlabelsize = 14
ylabelsize = 14
mpl.rcParams['lines.linewidth'] = 1.2
default_colors = plt.rcParams['axes.prop_cycle'].by_key()['color']
fig, axs = plt.subplots(n_charts, sharex=True)
fig.set_figwidth(13); fig.set_figheight(9)
fig.suptitle(suptitle, fontsize=18)
xi = 0
legendlabels = []
axs[xi].set_title(r"$exp\bar{C}^{cum}(\theta^*)$", loc='right', fontsize=16)
for i,itm in enumerate(means.items()):
axs[xi].spines['top'].set_visible(False); axs[xi].spines['right'].set_visible(True); axs[xi].spines['bottom'].set_visible(False)
leg = axs[xi].plot(itm[1], color=pars['colors'][i]); #print(f"{pars['colors'][i]}")
legendlabels.append(itm[0])
axs[xi].set_ylabel(labelY, rotation=0, ha='right', va='center', fontweight='normal', size=ylabelsize)
xi = 1
axs[xi].set_title(r"$exp\tilde{C}^{cum}(\theta^*)$", loc='right', fontsize=16)
for i,itm in enumerate(stdvs.items()):
axs[xi].spines['top'].set_visible(False); axs[xi].spines['right'].set_visible(True); axs[xi].spines['bottom'].set_visible(False)
# leg = axs[xi].plot(itm[1], default_colors[i], linestyle='--')
leg = axs[xi].plot(itm[1], pars['colors'][i], linestyle='--')
axs[xi].set_ylabel(labelY, rotation=0, ha='right', va='center', fontweight='normal', size=ylabelsize)
fig.legend(
# [leg],
labels=legendlabels,
title="Policies",
loc='upper right',
fancybox=True,
shadow=True,
ncol=1)
plt.xlabel(labelX, rotation=0, labelpad=10, ha='right', va='center', fontweight='normal', size=xlabelsize)
plt.show()
def plot_records(self, df, df_non, pars=defaultdict(str)):
# legendlabels = []
n_e = len(eNAMES) #number of entities
n_charts = 3*n_e + 1 + 1
ylabelsize = 14
mpl.rcParams['lines.linewidth'] = 1.2
mycolors = ['g', 'b']
fig, axs = plt.subplots(n_charts, sharex=True)
fig.set_figwidth(13); fig.set_figheight(9)
fig.suptitle(pars['suptitle'], fontsize=14)
xi = 0
for i,e in enumerate(eNAMES):
axs[xi+i].set_ylim(auto=True); axs[xi+i].spines['top'].set_visible(False); axs[xi+i].spines['right'].set_visible(True); axs[xi+i].spines['bottom'].set_visible(False)
axs[xi+i].step(df[f'x_t_{e}'], 'm-', where='post')
if not df_non is None: axs[xi+i].step(df_non[f'x_t_{e}'], 'c-.', where='post')
axs[xi+i].axhline(y=0, color='k', linestyle=':')
# y1ab = '$x_{t}$'
y1ab = '$x_{t,'+f'{e}'+'}$'
axs[xi+i].set_ylabel(y1ab, rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize)
for j in range(df.shape[0]//T): axs[xi+i].axvline(x=(j+1)*T, color='grey', ls=':')
xi = n_e
for i,e in enumerate(eNAMES):
axs[xi+i].set_ylim(auto=True); axs[xi+i].spines['top'].set_visible(False); axs[xi+i].spines['right'].set_visible(True); axs[xi+i].spines['bottom'].set_visible(False)
axs[xi+i].step(df[f'p_t_{e}'], mycolors[xi%len(mycolors)], where='post')
if not df_non is None: axs[xi+i].step(df_non[f'p_t_{e}'], 'c-.', where='post')
# axs[xi+i].axhline(y=0, color='k', linestyle=':')
if(pars['thetaLo']): axs[xi+i].text(-4, pars['thetaLo'][e], r'$\theta^{Lo}$' + f"={pars['thetaLo'][e]:.1f}", size=10, color='m')
if(pars['thetaLo']): axs[xi+i].axhline(y=pars['thetaLo'][e], color='m', linestyle=':')
if(pars['thetaHi']): axs[xi+i].text(-4, pars['thetaHi'][e], r'$\theta^{Hi}$' + f"={pars['thetaHi'][e]:.1f}", size=10, color='m')
if(pars['thetaHi']): axs[xi+i].axhline(y=pars['thetaHi'][e], color='m', linestyle=':')
if(pars['thetaLoNon']): axs[xi+i].text(-4, pars['thetaLoNon'][e], r'$\theta^{Lo}$' + f"={pars['thetaLoNon'][e]:.1f}", size=10, color='c')
if(pars['thetaLoNon']): axs[xi+i].axhline(y=pars['thetaLoNon'][e], color='c', linestyle=':')
if(pars['thetaHiNon']): axs[xi+i].text(-4, pars['thetaHiNon'][e], r'$\theta^{Hi}$' + f"={pars['thetaHiNon'][e]:.1f}", size=10, color='c')
if(pars['thetaHiNon']): axs[xi+i].axhline(y=pars['thetaHiNon'][e], color='c', linestyle=':')
y1ab = '$p_{t,'+f'{e}'+'}$'
axs[xi+i].set_ylabel(y1ab, rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize)
for j in range(df.shape[0]//T): axs[xi+i].axvline(x=(j+1)*T, color='grey', ls=':')
xi = 2*n_e
for i,e in enumerate(eNAMES):
axs[xi+i].set_ylim(auto=True); axs[xi+i].spines['top'].set_visible(False); axs[xi+i].spines['right'].set_visible(True); axs[xi+i].spines['bottom'].set_visible(False)
axs[xi+i].step(df[f'R_t_{e}'], 'm-', where='post')
if not df_non is None: axs[xi+i].step(df_non[f'R_t_{e}'], 'c-.', where='post')
axs[xi+i].axhline(y=0, color='k', linestyle=':')
y1ab = '$R_{t,'+f'{e}'+'}$'
axs[xi+i].set_ylabel(y1ab, rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize)
for j in range(df.shape[0]//T): axs[xi+i].axvline(x=(j+1)*T, color='grey', ls=':')
xi = 3*n_e
axs[xi].set_ylim(auto=True); axs[xi].spines['top'].set_visible(False); axs[xi].spines['right'].set_visible(True); axs[xi].spines['bottom'].set_visible(False)
axs[xi].step(df['R0_t'], 'm-', where='post')
if not df_non is None: axs[xi].step(df_non['Ccum'], 'c-.', where='post')
axs[xi].axhline(y=0, color='k', linestyle=':')
axs[xi].set_ylabel('$R^{0}_t$'+'\n'+''+'$\mathrm{[\$]}$', rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize);
for j in range(df.shape[0]//T): axs[xi].axvline(x=(j+1)*T, color='grey', ls=':')
xi = 3*n_e + 1
axs[xi].set_ylim(auto=True); axs[xi].spines['top'].set_visible(False); axs[xi].spines['right'].set_visible(True); axs[xi].spines['bottom'].set_visible(False)
axs[xi].step(df['Ccum'], 'm-', where='post')
if not df_non is None: axs[xi].step(df_non['Ccum'], 'c-.', where='post')
axs[xi].axhline(y=0, color='k', linestyle=':')
axs[xi].set_ylabel('$C^{cum}$'+'\n'+'$\mathrm{(Profit)}$'+'\n'+''+'$\mathrm{[\$]}$', rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize);
for j in range(df.shape[0]//T): axs[xi].axvline(x=(j+1)*T, color='grey', ls=':')
axs[xi].set_xlabel('$t\ \mathrm{[decision\ windows]}$', rotation=0, ha='right', va='center', fontweight='bold', size=ylabelsize);
# fig.legend(labels=legendlabels, loc='lower left', fontsize=16)
# setup labels to plot info
R_t_labels = ['R_t_'+en for en in eNAMES]
p_t_labels = ['p_t_'+en for en in eNAMES]
b_t_labels = ['b_t']
x_t_labels = ['x_t_'+en for en in eNAMES]
b_t_val_labels = ['b_t_val_'+en for en in eNAMES]
labels = ['piName', 'theta', 'l'] + \
['t'] + R_t_labels + ['R0_t'] + p_t_labels + \
['Ccum'] + x_t_labels + b_t_val_labels
labels
['piName',
'theta',
'l',
't',
'R_t_AAA',
'R_t_BBB',
'R0_t',
'p_t_AAA',
'p_t_BBB',
'Ccum',
'x_t_AAA',
'x_t_BBB',
'b_t_val_AAA',
'b_t_val_BBB']
%%time
L = N_SAMPLEPATHS
T = N_TRANSITIONS
first_n_t = 4*T
last_n_t = 4*T
M = Model(S_0_INFO)
P = Policy(M)
SIM = PriceSimulator(seed=SEED_TRAIN)
th_lo = {en: np.arange(TH_LO[en][0], TH_LO[en][1], TH_LO[en][2]) for en in eNAMES}
th_hi = {en: np.arange(TH_HI[en][0], TH_HI[en][1], TH_HI[en][2]) for en in eNAMES}
thetas = P.grid_search_thetas_4(th_lo, th_hi)
thetaStar_expCbarcum_HighLow, thetaStar_expCtilcum_HighLow, \
Cbarcum_HighLow, Ctilcum_HighLow, \
best_theta_HighLow, worst_theta_HighLow, \
best_Cbarcum_HighLow, worst_Cbarcum_HighLow, \
best_Ctilcum_HighLow, worst_Ctilcum_HighLow, \
record_HighLow = \
P.perform_grid_search_sample_paths("X__HighLow", thetas)
f'{thetaStar_expCbarcum_HighLow.iloc[-1]=:.2f}'
df_first_n_t = pd.DataFrame.from_records(record_HighLow[:first_n_t], columns=labels)
df_last_n_t = pd.DataFrame.from_records(record_HighLow[-last_n_t:], columns=labels)
num_thetas=625
thetas=[Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.0, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.1, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.2, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.0}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.19999999999999}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.29999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.0, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.2, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.29999999999998, 'BBB': 90.39999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.0}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.1}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.19999999999999}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.29999999999998}), Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.39999999999998}, thHi={'AAA': 200.39999999999998, 'BBB': 90.39999999999998})]
... printing every 20th theta if considered ...
=== (0 / 625), theta=((168.0, 72.0), (200.0, 90.0)) ===
=== (20 / 625), theta=((168.0, 72.0), (200.4, 90.0)) ===
=== (40 / 625), theta=((168.0, 72.1), (200.3, 90.0)) ===
=== (60 / 625), theta=((168.0, 72.2), (200.2, 90.0)) ===
=== (80 / 625), theta=((168.0, 72.3), (200.1, 90.0)) ===
=== (100 / 625), theta=((168.0, 72.4), (200.0, 90.0)) ===
=== (120 / 625), theta=((168.0, 72.4), (200.4, 90.0)) ===
=== (140 / 625), theta=((168.1, 72.0), (200.3, 90.0)) ===
=== (160 / 625), theta=((168.1, 72.1), (200.2, 90.0)) ===
=== (180 / 625), theta=((168.1, 72.2), (200.1, 90.0)) ===
=== (200 / 625), theta=((168.1, 72.3), (200.0, 90.0)) ===
=== (220 / 625), theta=((168.1, 72.3), (200.4, 90.0)) ===
=== (240 / 625), theta=((168.1, 72.4), (200.3, 90.0)) ===
=== (260 / 625), theta=((168.2, 72.0), (200.2, 90.0)) ===
=== (280 / 625), theta=((168.2, 72.1), (200.1, 90.0)) ===
=== (300 / 625), theta=((168.2, 72.2), (200.0, 90.0)) ===
=== (320 / 625), theta=((168.2, 72.2), (200.4, 90.0)) ===
=== (340 / 625), theta=((168.2, 72.3), (200.3, 90.0)) ===
=== (360 / 625), theta=((168.2, 72.4), (200.2, 90.0)) ===
=== (380 / 625), theta=((168.3, 72.0), (200.1, 90.0)) ===
=== (400 / 625), theta=((168.3, 72.1), (200.0, 90.0)) ===
=== (420 / 625), theta=((168.3, 72.1), (200.4, 90.0)) ===
=== (440 / 625), theta=((168.3, 72.2), (200.3, 90.0)) ===
=== (460 / 625), theta=((168.3, 72.3), (200.2, 90.0)) ===
=== (480 / 625), theta=((168.3, 72.4), (200.1, 90.0)) ===
=== (500 / 625), theta=((168.4, 72.0), (200.0, 90.0)) ===
=== (520 / 625), theta=((168.4, 72.0), (200.4, 90.0)) ===
=== (540 / 625), theta=((168.4, 72.1), (200.3, 90.0)) ===
=== (560 / 625), theta=((168.4, 72.2), (200.2, 90.0)) ===
=== (580 / 625), theta=((168.4, 72.3), (200.1, 90.0)) ===
=== (600 / 625), theta=((168.4, 72.4), (200.0, 90.0)) ===
=== (620 / 625), theta=((168.4, 72.4), (200.4, 90.0)) ===
best_theta_en:
Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})
best_Cbarcum=6221.91
best_Ctilcum=19.33
worst_theta_en:
Theta(thLo={'AAA': 168.29999999999998, 'BBB': 72.0}, thHi={'AAA': 200.1, 'BBB': 90.39999999999998})
worst_Cbarcum=6069.05
worst_Ctilcum=21.37
CPU times: user 4h 54min 43s, sys: 10min 17s, total: 5h 5min 1s
Wall time: 5h 3min 47s
Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})
P.plot_Fhat_map_4(
FhatI_theta_I=Cbarcum_HighLow,
thetasX=th_lo[eNAMES[0]],
thetasY=th_lo[eNAMES[1]],
labelX=r'$\theta^{Lo}_{AAA}$',
labelY=r'$\theta^{Lo}_{BBB}$',
title="Sample mean of the cumulative reward"+f"\n $L={L}, T={T}$, "+ \
r"$\theta^* =$"+ P.round_theta(best_theta_HighLow)+", " \
r"$\bar{C}^{cum}(\theta^*) =$"+f"{best_Cbarcum_HighLow:.2f}",
thetaFixed1=best_theta_HighLow.thHi[eNAMES[0]],
thetaFixed2=best_theta_HighLow.thHi[eNAMES[1]],
)
print()
P.plot_Fhat_map_4(
FhatI_theta_I=Ctilcum_HighLow,
thetasX=th_lo[eNAMES[0]],
thetasY=th_lo[eNAMES[1]],
labelX=r'$\theta^{Lo}_{AAA}$',
labelY=r'$\theta^{Lo}_{BBB}$',
title="Standard error of the cumulative reward"+f"\n $L={L}, T={T}$, "+ \
r"$\theta^* =$"+ P.round_theta(best_theta_HighLow)+", " \
r"$\tilde{C}^{cum}(\theta^*) =$"+f"{best_Ctilcum_HighLow:.2f}",
thetaFixed1=best_theta_HighLow.thHi[eNAMES[0]],
thetaFixed2=best_theta_HighLow.thHi[eNAMES[1]],
);
P.plot_expFhat_chart(
thetaStar_expCbarcum_HighLow,
r'$\ell$',
r"$exp\bar{C}^{cum}(\theta^*)$"+"\n(Profit)\n[$]",
"Expanding sample mean of the cumulative reward"+f"\n $L={L}, T={T}$, "+ \
r"$\theta^* =$"+ P.round_theta(best_theta_HighLow)+", " \
r"$\bar{C}^{cum}(\theta^*) =$"+f"{best_Cbarcum_HighLow:.2f}",
'b-'
)
print()
P.plot_expFhat_chart(
thetaStar_expCtilcum_HighLow,
r'$\ell$',
r"$exp\tilde{C}^{cum}(\theta^*)$"+"\n(Profit)\n[$]",
"Expanding standard error of the cumulative reward"+f"\n $L={L}, T={T}$, "+ \
r"$\theta^* =$"+ P.round_theta(best_theta_HighLow)+", " \
r"$\tilde{C}^{cum}(\theta^*) =$"+f"{best_Ctilcum_HighLow:.2f}",
'b--'
);
Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})
P.plot_records(
df=df_first_n_t,
df_non=None,
pars=defaultdict(str, {
'policy': 'X__HighLow',
'thetaLo': {en: best_theta_HighLow.thLo[en] for en in eNAMES},
'thetaHi': {en: best_theta_HighLow.thHi[en] for en in eNAMES},
'suptitle': f'TRAINING OF X__HighLow POLICY'+'\n'+f'(first {first_n_t} records)'+'\n'+ \
f'L = {L}, T = {T}, '+ \
r'$\theta^*=$'+f'{P.round_theta(best_theta_HighLow)}',
}),
)
P.plot_records(
df=df_last_n_t,
df_non=None,
pars=defaultdict(str, {
'policy': 'X__HighLow',
'thetaLo': {en: best_theta_HighLow.thLo[en] for en in eNAMES},
'thetaHi': {en: best_theta_HighLow.thHi[en] for en in eNAMES},
'suptitle': f'TRAINING OF X__HighLow POLICY'+'\n'+f'(last {last_n_t} records)'+'\n'+ \
f'L = {L}, T = {T}, '+ \
r'$\theta^*=$'+f'{P.round_theta(best_theta_HighLow)}',
}),
)
L = 100 #N_SAMPLEPATHS
T = 200 #N_TRANSITIONS
# first_n_t = int(.01*L*T)
first_n_t = int(.05*L*T)
M = Model(S_0_INFO)
P = Policy(M)
SIM = PriceSimulator(seed=SEED_EVALU)
thetasOpt = []; thetasOpt.append(best_theta_HighLow)
thetaStar_expCbarcum_HighLow_evalu, thetaStar_expCtilcum_HighLow_evalu, \
Cbarcum_HighLow_evalu, Ctilcum_HighLow_evalu, \
best_theta_HighLow_evalu, worst_theta_HighLow_evalu, \
best_Cbarcum_HighLow_evalu, worst_Cbarcum_HighLow_evalu, \
best_Ctilcum_HighLow_evalu, worst_Ctilcum_HighLow_evalu, \
record_HighLow_evalu = \
P.perform_grid_search_sample_paths("X__HighLow", thetasOpt)
df_X__HighLow_evalu = pd.DataFrame.from_records(record_HighLow_evalu[:first_n_t], columns=labels)
M = Model(S_0_INFO)
P = Policy(M)
SIM = PriceSimulator(seed=SEED_EVALU)
# thetasNon = []; thetasNon.append(worst_theta_HighLow)
thetasNon = []; thetasNon.append(
P.build_theta(
{'thLo': {'AAA': 320, 'BBB': 400}, 'thHi': {'AAA': 350, 'BBB': 430}}
))
thetaStar_expCbarcum_HighLow_evalu_non, thetaStar_expCtilcum_HighLow_evalu_non, \
Cbarcum_HighLow_evalu_non, Ctilcum_HighLow_evalu_non, \
best_theta_HighLow_evalu_non, worst_theta_HighLow_evalu_non, \
best_Cbarcum_HighLow_evalu_non, worst_Cbarcum_HighLow_evalu_non, \
best_Ctilcum_HighLow_evalu_non, worst_Ctilcum_HighLow_evalu_non, \
record_HighLow_evalu_non = \
P.perform_grid_search_sample_paths("X__HighLow", thetasNon)
print(
f'{thetaStar_expCbarcum_HighLow_evalu.iloc[-1]=:.2f}, \
{thetaStar_expCbarcum_HighLow_evalu_non.iloc[-1]=:.2f}')
df_X__HighLow_evalu_non = pd.DataFrame.from_records(record_HighLow_evalu_non[:first_n_t], columns=labels)
num_thetas=1
thetas=[Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})]
... printing every 20th theta if considered ...
=== (0 / 1), theta=((168.4, 72.1), (200.2, 90.1)) ===
best_theta_en:
Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})
best_Cbarcum=6368.94
best_Ctilcum=149.46
worst_theta_en:
Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})
worst_Cbarcum=6368.94
worst_Ctilcum=149.46
num_thetas=1
thetas=[Theta(thLo={'AAA': 320, 'BBB': 400}, thHi={'AAA': 350, 'BBB': 430})]
... printing every 20th theta if considered ...
=== (0 / 1), theta=((320.0, 400.0), (350.0, 430.0)) ===
best_theta_en:
Theta(thLo={'AAA': 320, 'BBB': 400}, thHi={'AAA': 350, 'BBB': 430})
best_Cbarcum=6290.22
best_Ctilcum=134.89
worst_theta_en:
Theta(thLo={'AAA': 320, 'BBB': 400}, thHi={'AAA': 350, 'BBB': 430})
worst_Cbarcum=6290.22
worst_Ctilcum=134.89
thetaStar_expCbarcum_HighLow_evalu.iloc[-1]=6368.94, thetaStar_expCbarcum_HighLow_evalu_non.iloc[-1]=6290.22
P.plot_records(
df=df_X__HighLow_evalu,
df_non=df_X__HighLow_evalu_non,
pars=defaultdict(str, {
'policy': 'X__HighLow',
'thetaLo': {en: thetasOpt[0].thLo[en] for en in eNAMES},
'thetaHi': {en: thetasOpt[0].thHi[en] for en in eNAMES},
'thetaLoNon': {en: thetasNon[0].thLo[en] for en in eNAMES},
'thetaHiNon': {en: thetasNon[0].thHi[en] for en in eNAMES},
'suptitle': f'EVALUATION OF X__HighLow POLICY'+'\n'+f'(first {first_n_t} records)'+'\n'+ \
f'L = {L}, T = {T}, '+ \
r'$\theta^*=$'+f'{P.round_theta(best_theta_HighLow_evalu)}',
}),
)
last_n_l = int(1.*L)
# last_n_l = int(.95*L)
# last_n_l = int(.90*L)
P.plot_expFhat_charts(
means={
'HighLow optimal': thetaStar_expCbarcum_HighLow_evalu[-last_n_l:],
'HighLow non-optimal': thetaStar_expCbarcum_HighLow_evalu_non[-last_n_l:],
},
stdvs={
'HighLow optimal': thetaStar_expCtilcum_HighLow_evalu[-last_n_l:],
'HighLow non-optimal': thetaStar_expCtilcum_HighLow_evalu_non[-last_n_l:],
},
labelX='Sample paths, ' + r'$\ell$',
labelY='Profit\n[$]',
suptitle=f"Comparison of Optimal/Non-optimal Policies after Evaluation\n \
L = {L}, T = {T}\n \
last {last_n_l} records\n \
('exp' refers to expanding)",
pars=defaultdict(str, {
'colors': ['m', 'c']
}),
)
Next, we evaluate with a single, very long sample-path:
# SEED_EVALU = 555
L = 1 #N_SAMPLEPATHS
T = 50_000 #5000 #N_TRANSITIONS
first_n_t = int(1*L*T)
M = Model(S_0_INFO)
P = Policy(M)
SIM = PriceSimulator(seed=SEED_EVALU)
thetasOpt = []; thetasOpt.append(best_theta_HighLow)
thetaStar_expCbarcum_HighLow_evalu, thetaStar_expCtilcum_HighLow_evalu, \
Cbarcum_HighLow_evalu, Ctilcum_HighLow_evalu, \
best_theta_HighLow_evalu, worst_theta_HighLow_evalu, \
best_Cbarcum_HighLow_evalu, worst_Cbarcum_HighLow_evalu, \
best_Ctilcum_HighLow_evalu, worst_Ctilcum_HighLow_evalu, \
record_HighLow_evalu = \
P.perform_grid_search_sample_paths("X__HighLow", thetasOpt)
df_X__HighLow_evalu = pd.DataFrame.from_records(record_HighLow_evalu[:first_n_t], columns=labels)
M = Model(S_0_INFO)
P = Policy(M)
SIM = PriceSimulator(seed=SEED_EVALU)
thetasNon = []; thetasNon.append(
P.build_theta(
{'thLo': {'AAA': 320, 'BBB': 400}, 'thHi': {'AAA': 350, 'BBB': 430}}
))
thetaStar_expCbarcum_HighLow_evalu_non, thetaStar_expCtilcum_HighLow_evalu_non, \
Cbarcum_HighLow_evalu_non, Ctilcum_HighLow_evalu_non, \
best_theta_HighLow_evalu_non, worst_theta_HighLow_evalu_non, \
best_Cbarcum_HighLow_evalu_non, worst_Cbarcum_HighLow_evalu_non, \
best_Ctilcum_HighLow_evalu_non, worst_Ctilcum_HighLow_evalu_non, \
record_HighLow_evalu_non = \
P.perform_grid_search_sample_paths("X__HighLow", thetasNon)
print(
f'{thetaStar_expCbarcum_HighLow_evalu.iloc[-1]=:.2f}, \
{thetaStar_expCbarcum_HighLow_evalu_non.iloc[-1]=:.2f}')
df_X__HighLow_evalu_non = pd.DataFrame.from_records(record_HighLow_evalu_non[:first_n_t], columns=labels)
num_thetas=1
thetas=[Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})]
... printing every 20th theta if considered ...
=== (0 / 1), theta=((168.4, 72.1), (200.2, 90.1)) ===
best_theta_en:
Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})
best_Cbarcum=415654.44
best_Ctilcum=nan
worst_theta_en:
Theta(thLo={'AAA': 168.39999999999998, 'BBB': 72.1}, thHi={'AAA': 200.2, 'BBB': 90.1})
worst_Cbarcum=415654.44
worst_Ctilcum=nan
num_thetas=1
thetas=[Theta(thLo={'AAA': 320, 'BBB': 400}, thHi={'AAA': 350, 'BBB': 430})]
... printing every 20th theta if considered ...
=== (0 / 1), theta=((320.0, 400.0), (350.0, 430.0)) ===
best_theta_en:
Theta(thLo={'AAA': 320, 'BBB': 400}, thHi={'AAA': 350, 'BBB': 430})
best_Cbarcum=257982.45
best_Ctilcum=nan
worst_theta_en:
Theta(thLo={'AAA': 320, 'BBB': 400}, thHi={'AAA': 350, 'BBB': 430})
worst_Cbarcum=257982.45
worst_Ctilcum=nan
thetaStar_expCbarcum_HighLow_evalu.iloc[-1]=415654.44, thetaStar_expCbarcum_HighLow_evalu_non.iloc[-1]=257982.45
RuntimeWarning: invalid value encountered in double_scalars
Ctilcum_tmp = np.sum(np.square(np.array(CcumIomega__lI) - Cbarcum_tmp))/(L - 1)
<ipython-input-11-362db08c2b34>:113: RuntimeWarning: invalid value encountered in double_scalars
Ctilcum_tmp = np.sum(np.square(np.array(CcumIomega__lI) - Cbarcum_tmp))/(L - 1)
P.plot_records(
df=df_X__HighLow_evalu,
df_non=df_X__HighLow_evalu_non,
pars=defaultdict(str, {
'policy': 'X__HighLow',
'thetaLo': {en: thetasOpt[0].thLo[en] for en in eNAMES},
'thetaHi': {en: thetasOpt[0].thHi[en] for en in eNAMES},
'thetaLoNon': {en: thetasNon[0].thLo[en] for en in eNAMES},
'thetaHiNon': {en: thetasNon[0].thHi[en] for en in eNAMES},
'suptitle': f'EVALUATION OF X__HighLow POLICY'+'\n'+f'(first {first_n_t:,} records)'+'\n'+ \
f'L = {L}, T = {T:,}, '+ \
r'$\theta^*=$'+f'{P.round_theta(best_theta_HighLow_evalu_non)}',
}),
)