Earlier quoted context omitted.
> I am not sure I will ever trust an ML algorithm trained on inputs/outputs only It’s doing TDD!
Imagine a world where all programmers do is write the tests and the generalized learning algos write all the implementations.
Neural programmer better than Quicksort
111–120 of 132 posts
Re: Neural programmer better than Quicksort
#112Earlier quoted context omitted.
What else is hard besides converting (high + low) / 2 To Low + (high - low) / 2 What else about this problem is a "sharp edge"?
I may have been a little too harsh. Binary search is close to being a good interview question, especially since the algorithm does, rarely, come up in real code. But I prefer questions that are more like what people will be doing in their day-to-day job, and binary search is just a little too fiddly.
Candidate: bsearch(key, base, num, size, compare_fn);
Me: "Your offer should arrive within one to two weeks. Need any help with relocation expenses?"
Re: Neural programmer better than Quicksort
#113Earlier quoted context omitted.
Tests are simple to unterstand. Complicated proofs I do not understand, without much effort. And I surely know that you can make mistakes with test cases as well. So I surely do not claim my way to be superior. But it works way better for me.
Test cases are not necessarily simple to understand. Especially the test cases needed to trigger some deep bug.
Re: Neural programmer better than Quicksort
#114Earlier quoted context omitted.
I may have been a little too harsh. Binary search is close to being a good interview question, especially since the algorithm does, rarely, come up in real code. But I prefer questions that are more like what people will be doing in their day-to-day job, and binary search is just a little too fiddly.
Me: "Show me a binary search in C on the whiteboard." Candidate: bsearch(key, base, num, size, compare_fn); Me: "Your offer should arrive within one to two weeks. Need any help with relocation expenses?"
Re: Neural programmer better than Quicksort
#115It's really hard to write correct code. Sorting was broken in java and nobody noticed for a long time: http://envisage-project.eu/wp-content/uploads/2015/02/sortin... The same was true for java's binary search: https://ai.googleblog.com/2006/06/extra-extra-read-all-about... So I am not sure I will ever trust an ML algorithm trained on inputs/outputs only (which is what I think "neural program induction" means). The a…
It would be funny if a two phase approach to sorting would result in increased average performance. First sort using the ML algorithm. Then sort the almost sorted result with a traditional algorithm optimized for almost sorted results. In fact, I think my own brain does the two phase approach to many problems.
Re: Neural programmer better than Quicksort
#116Short version: In summary, this paper makes strong claims of generalisation and efficiency but does not seem to provide sufficently strong evidence to back them up, e.g. it does not perform an asymptotic analysis to support the efficiency claim, it doesn't show actual program output to allow the evaluation of what is actually learned and the claim about strong generalisation is based on a very vaguely described exper…
> I'm still left wondering why an "instruction" is qualitatively different to a "function" Functions can be recursive. So the algorithm that the agent generates is able to use divide-and-conquer.
Re: Neural programmer better than Quicksort
#117It's really hard to write correct code. Sorting was broken in java and nobody noticed for a long time: http://envisage-project.eu/wp-content/uploads/2015/02/sortin... The same was true for java's binary search: https://ai.googleblog.com/2006/06/extra-extra-read-all-about... So I am not sure I will ever trust an ML algorithm trained on inputs/outputs only (which is what I think "neural program induction" means). The a…
Apparently modern GPUs have sorting-networks implemented in hardware (giving you effectively constant-time sorting for fixed-size input) - which may be preferable for use if you’re processing hostile input which may be contrived to hit QuickSort’s worst-case and the cost of hitting the PCI Express bus is less than the cost of randomizing the input to mitigate QuickSort attacks. But yes - I agree it’s weird that many…
If you have a source, I would like to learn more.
Re: Neural programmer better than Quicksort
#118Earlier quoted context omitted.
What else is hard besides converting (high + low) / 2 To Low + (high - low) / 2 What else about this problem is a "sharp edge"?
I may have been a little too harsh. Binary search is close to being a good interview question, especially since the algorithm does, rarely, come up in real code. But I prefer questions that are more like what people will be doing in their day-to-day job, and binary search is just a little too fiddly.
Re: Neural programmer better than Quicksort
#119Earlier quoted context omitted.
Imagine a world where all programmers do is write the tests and the generalized learning algos write all the implementations.
Welcome to my company a few years ago. Except they were not programmers but PM and architects, and algos were subcontractors. Now we have real developers (I'm in one of those teams)
Re: Neural programmer better than Quicksort
#120Earlier quoted context omitted.
> If this thing can efficiently almost-correctly-sort because it's better at these types of pattern matching, we can just run a final pass of insertion sort to make it useful! Depends on what kinds of mistakes the almost-correct approach makes. If it just puts elements in the wrong order, your suggestion works. But if it makes mistakes like duplicating elements, or dropping them, or completely making up new entries,…
> Depends on what kinds of mistakes the almost-correct approach makes. If it just puts elements in the wrong order, your suggestion works. But if it makes mistakes like duplicating elements, or dropping them, or completely making up new entries, no post-processing will help. The algorithm modifies the original list only by swapping entries. As such, it's guaranteed to result in a permutation.
But it also limits their system to in-place algorithms only.