Example #1
0
def check_toy_problem():
    customer = get_customer()
    ctype, (age, ft) = customer
    assert isinstance(ctype, int)
    assert isinstance(age, int)
    assert isinstance(ft, float)
    reward = get_rewards(customer)
    assert reward.shape == (3, )
    fts, reward = get_cust_reward()
    df = generate_dataframe(10)
    assert isinstance(df, pd.DataFrame)
    return fts, reward
Example #2
0
def check_action(model):
    customer = get_customer()
    fts = np.array(customer[1])
    action = model.action(fts)
    return action
Example #3
0
def check_sample(model):
    customer = get_customer()
    fts = np.array(customer[1])
    values = model._sample(fts)
    return values
Example #4
0
def check_expected_values(model):
    customer = get_customer()
    fts = np.array(customer[1])
    values = model.expected_values(fts)
    return values