basnijholt / adaptive

:chart_with_upwards_trend: Tools for adaptive and parallel samping of mathematical functions
http://adaptive.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

WIP: add support for neighbours in loss computation in LearnerND #91

Closed basnijholt closed 5 years ago

basnijholt commented 5 years ago

(original issue on GitLab)

opened by Jorn Hoofwijk (@Jorn) at 2018-10-26T19:36:45.884Z

Closes gitlab:#120

TODO add support to output in $R^N$

TODO rewrite the code to be more readable, I will do this next week

image

As you can see in the plot, it is getting hard to distinguish the LearnerND from the Learner2D :D

basnijholt commented 5 years ago

_originally posted by Jorn Hoofwijk (@Jorn) at 2018-10-26T19:41:47.446Z on GitLab_

Also do notice I did not actually test it in N dimensions, but it ought to work, I will certainly test it next week

basnijholt commented 5 years ago

_originally posted by Jorn Hoofwijk (@Jorn) at 2018-10-29T11:05:51.877Z on GitLab_

Now, say we optimize this LearnerND (e.g. by switching to C++/Cython) then this (MR + gitlab:#80) may suffice to make the LearnerND as good as the Learner2D and we then could have another look at gitlab:#83

basnijholt commented 5 years ago

_originally posted by Jorn Hoofwijk (@Jorn) at 2018-10-29T13:12:27.234Z on GitLab_

And it works for R^N -> R^M now :) Tested it out in 3d and works great :D Although I'm not gonna pretend that it's fast, it should need less points than the old loss, which is great and should make it faster for sufficiently slow functions :)

basnijholt commented 5 years ago

_originally posted by Bas Nijholt (@basnijholt) at 2018-10-30T13:58:05.003Z on GitLab_

Cool!

Would it be possible to implement this in a similar way to what we did in gitlab:!131?

basnijholt commented 5 years ago

_originally posted by Bas Nijholt (@basnijholt) at 2018-11-05T10:44:09.534Z on GitLab_

@Jorn I introduced this method but I am not sure about the name. Could you fix it if you know a better description?

basnijholt commented 5 years ago

_originally posted by Joseph Weston (@jbweston) at 2018-11-26T14:36:02.721Z on GitLab_

Do we really mean

try:
    return list(inp)
except TypeError:
    return [inp]

?

basnijholt commented 5 years ago

_originally posted by Joseph Weston (@jbweston) at 2018-11-26T14:36:59.572Z on GitLab_

get_curvature_loss -> curvature_loss_function