NLtest



In [25]:
import numpy as np
from ContNoRegret.Domains import unitbox
from ContNoRegret.LossFunctions import QuadraticLossFunction
from ContNoRegret.NLopt import NLoptProblem
import matplotlib.pyplot as plt
%matplotlib inline

dom = unitbox(2)
objective = QuadraticLossFunction(dom, [0,0], np.array([[2,0.5], [0.5,1]]), 0)
etas = 500*1/np.arange(1,501)

prob = NLoptProblem(dom, objective)
actions = np.array(prob.run_minimization(etas, 1))

In [38]:
i=0
plt.plot(actions[15:25,i,0], actions[15:25,i,1])


Out[38]:
[<matplotlib.lines.Line2D at 0x116548710>]

In [ ]:
from ContNoRegret.D