Earlier quoted context omitted.
Periodic function like sin(x) are not a dynamical system so its previous state does not determine the current state. So it should be approximated in that way.
Periodic functions like sin(x) are the solutions to differential equations like dy/dx = -y that describe for example, oscillations of springs, to name but one of an extremely large number of dynamical systems that behave this way.
Why train when you can optimize?
31–40 of 70 posts
Re: Why train when you can optimize?
#32Very cool article, but if you want to draw straight lines just use the start and end points :/
Re: Why train when you can optimize?
#33Earlier quoted context omitted.
And yet neural networks can solve symbolic integral and derivative problems and differential equations better than other computer algebra programs. Sure one network might fail to compute sin(x) numerically, but another could easily tell you its derivative is cos(x). Turns out they are pretty flexible. Do they need to do everything?
Source? I would be very surprised if there was a neural symbolic PDE solver better than what’s in wolfram mathematica.
Re: Why train when you can optimize?
#34Earlier quoted context omitted.
Periodic functions like sin(x) are the solutions to differential equations like dy/dx = -y that describe for example, oscillations of springs, to name but one of an extremely large number of dynamical systems that behave this way.
Of course sine can appear in the solution for dynamical systems but the function itself is not dynamical. When evaluating sin(x) you do not need to know about the previous state.
> So it should not be approximated in that way.
We can’t conclude a dynamic approximation is a bad approach based purely on the fact the underlying function isn’t dynamic.
The function might nevertheless be easily approximated via dynamics — as in the case of predicting sine from seeing the recent history.
Re: Why train when you can optimize?
#35Neural networks can approximate any function, but that doesn’t mean they do so efficiently. Depending on the function, they can require incredible amounts of neurons and training. At their worst, they devolve into a lookup table. It’s not hard to find these examples either. Just try training a neural network to compute sin(x)! This is possible! One of the cool things about neural networks is that you can try to encod…
Re: Why train when you can optimize?
#36I've always been interested in reinforcement learning, believing it will magically solve anything I throw at it. Unfortunately, I haven't got it to work everywhere yet. I hoped to learn a couple good RL algorithms and then never have to actually learn the concrete details of optimization, because RL can do almost as good. I don't truly believe this, but I think it is an underlying psychological reason for my love of…
I think that you can use optimization without having to learn anything about its algorithms (learning the basics is always advised of course, but that takes nowhere near as much effort). Nowadays, an off-the-shelf black-box solver will perform better than a custom implementation in most cases: what you lose in fine-tuning is more than compensated by the implementation quality and the sheer number of algorithms available.
> best resources for branching out from RL to more classical control and optimization
It depends on your problem. For general unstructured (nonconvex continuous) optimization, like the OP, you can use NLopt's documentation as a pragmatic starting point [1].
Optimal control is a whole different thing though, and you may have to start with some academic papers/books. I have been recommended this one [2], but I have not read it.
[1] https://nlopt.readthedocs.io/en/latest/
[2] https://link.springer.com/book/10.1007/978-1-4471-0967-9
Re: Why train when you can optimize?
#37Earlier quoted context omitted.
> and then your NN can't represent anything else than periodic functions.. This is a quote from the parent comment where you state that NNs with periodic activations can't represent non periodic functions. Siren (what I linked) uses periodic activations and is able to represent non periodic functions.
Oh OK, thanks yes that's what I was looking for! However if this NN can represent non Periodic functions, what cost does the Periodic function support incur on non Periodic function accuracy, if any?
Re: Why train when you can optimize?
#38Earlier quoted context omitted.
It’s hard to walk if you can’t feel your legs. The problem is improperly evaluating the neural network as a function of time, instead of evaluating the network as a function of previous state. When we humans approximate functions (let’s say you’re drawing it on a piece of paper, or waving your arm around) we do not simply look at a clock and feed forward that information directly into our motor neurons. Rather, we ha…
Periodic function like sin(x) are not a dynamical system so its previous state does not determine the current state. So it should be approximated in that way.
Re: Why train when you can optimize?
#39Neural networks can approximate any function, but that doesn’t mean they do so efficiently. Depending on the function, they can require incredible amounts of neurons and training. At their worst, they devolve into a lookup table. It’s not hard to find these examples either. Just try training a neural network to compute sin(x)! This is possible! One of the cool things about neural networks is that you can try to encod…
Re: Why train when you can optimize?
#40If wonder what classes of problems fit this? For sure, I can't imagine how can you tackle sentiment analysis or text classifiers using optimization.