adaptive
adaptive copied to clipboard
SequenceLearner does not fulfill API for data
The keys in data
for the SequenceLearner
are not just the points in the domain: they are tuples that also contain some index into the sequence of values.
This does not conform to the API for data
which is:
data : dict: X → Y
`function` evaluated at certain points.
where X
was previously defined to be the domain of the function being learned.
I would recommend holding the indices in a different datastructure if it is really necessary.
What about these changes?
I don't think that that really addresses the issue. If data
is a public attribute then it should be something that the user can understand and use, especially because right now it is the only way to access the results of an adaptive run. If every learner decides on its own convention for what to keep in data
then this makes adaptive harder to use IMO.
data
is just index
-> value
in the SequenceLearner
.
Like we discussed yesterday, it is not possible to make a point
-> value
dictionary.
Also, learner.result()
will return the list of values in the same order as the sequence
.