Exemplo n.º 1
0
    kf.fit()
    kf.display(out="./co2_kf.png")

if model.lower() == "ar":
    p = 50
    my_ar = AutoRegressive(data_dict, p)
    my_ar.fit()
    my_ar.predict()
    my_ar.display(out="./co2_ar.png")

if model.lower() == "ac":
    p = 50
    my_ac = AutoCorrelation(data_dict, p)
    my_ac.fit()
    my_ac.predict()
    my_ac.display(out="./co2_ac.png")
    my_ac.spectrum()


if model.lower() == "gp":

    Q = 3
    use_kernels = "exponential_quadratic* cosine"
    for _ in range(Q - 1):
        use_kernels += "+ exponential_quadratic * cosine"
#     use_kernels = 'rational_quadratic + periodic'
    use_means = "constant"
    estimator = "MLE"

    my_gp = GaussianProcess(data_dict=data_dict,
                            use_kernels=use_kernels,
Exemplo n.º 2
0
    kf.fit()
    kf.display(out="./mg_kf.png")

if model.lower() == "ar":
    p = 50
    my_ar = AutoRegressive(data_dict, p)
    my_ar.fit()
    my_ar.predict()
    my_ar.display(out="./mg_ar.png")

if model.lower() == "ac":
    p = 50
    my_ac = AutoCorrelation(data_dict, p)
    my_ac.fit()
    my_ac.predict()
    my_ac.display(out="./mg_ac.png")
    my_ac.spectrum()
    my_ac.plot_attr("spectrum", show=True)


if model.lower() == "gp":

    Q = 3
    use_kernels = "exponential_quadratic* cosine"
    for _ in range(Q - 1):
        use_kernels += "+ exponential_quadratic * cosine"
#     use_kernels = 'rational_quadratic + periodic'
    use_means = "constant"
    estimator = "MLE"

    my_gp = GaussianProcess(data_dict=data_dict,
Exemplo n.º 3
0
    kf.fit()
    kf.display(out="./sun_kf.png")

if model.lower() == "ar":
    p = 50
    my_ar = AutoRegressive(data_dict, p)
    my_ar.fit()
    my_ar.predict()
    my_ar.display(out="./sun_ar.png")

if model.lower() == "ac":
    p = 50
    my_ac = AutoCorrelation(data_dict, p)
    my_ac.fit()
    my_ac.predict()
    my_ac.display(out="./sun_ac.png")
    my_ac.spectrum()


if model.lower() == "gp":

#     Q = 3
#     use_kernels = "exponential_quadratic* cosine"
#     for _ in range(Q - 1):
#         use_kernels += "+ exponential_quadratic * cosine"
        
    use_kernels = "matern_32 + periodic"
    use_means = "constant"
    estimator = "MLE"
    
    params = [0.34, 1., 26.5, 1e-06, 3.18, -2.9]
Exemplo n.º 4
0
    kf.fit()
    kf.display(out="./fin_kf.png")

if model.lower() == "ar":
    p = 50
    my_ar = AutoRegressive(data_dict, p)
    my_ar.fit()
    my_ar.predict()
    my_ar.display(out="./fin_ar.png")

if model.lower() == "ac":
    p = 50
    my_ac = AutoCorrelation(data_dict, p)
    my_ac.fit()
    my_ac.predict()
    my_ac.display(out="./fin_ac.png")
    my_ac.spectrum()


if model.lower() == "gp":

    Q = 3
    use_kernels = "exponential_quadratic* cosine"
    for _ in range(Q - 1):
        use_kernels += "+ exponential_quadratic * cosine"
#     use_kernels = 'rational_quadratic + periodic'
    use_means = "constant"
    estimator = "MLE"

    my_gp = GaussianProcess(data_dict=data_dict,
                            use_kernels=use_kernels,