4 ms·
I've seen a definite shift in what "artificial intelligence" means. Norvig's PAIP is all about manipulating symbols. It's so fundamental that in any other lan
by ken 6y ago
I've seen a definite shift in what "artificial intelligence" means.
Norvig's PAIP is all about manipulating symbols. It's so fundamental that in any other language you'd have to Greenspun an interpreter first, just to solve the same problems in the same way.
Today, AI seems to mostly mean matrices. If that's all you need, then you can do it in any language, especially if you're just wrapping old C or Fortran libraries.
I haven't done any new-style AI but I get the feeling that most "research" is in finding new nails to pound with the same hammer. That's a legitimate area of research, but it also should be no surprise that the concept of "AI research" expanded so much in recent years because it changed from "learn to build your own lightsaber" to "pick up a hammer and hit something with it".
- newen 6y agoThere seems to be a misconception among non machine learning programmers that ML is all about multiplying matrices. In reality, there is a lot of architecture involved and having a programming languages that facilitates that would be enormously helpful. Yes, there is a lot of multiplying matrices. But you need to think of a matrix as like a <div> or something and multiplying matrices and placing two <div>s next to each other. Then, think of how to create a dynamic website from that. There is a lot of architecturing involved other than multiplying matrices.
- thesz 6y agoBehind matrices, there is a lot of symbolic processing in the data cleanup part. Most of the time, Python suffices. Most of the time, people does not leave Python when it is not satisfactory. They stick with it because they have no clue, most of the time. For example, it is not quite natural for Python folks to even think about creating rewrite rules (as in Haskell) for programs to stay at higher level of expression. E.g., if you use dictionary with default value, why not lift all operations up (inline, so to say) and avoid calling these that are overloaded? It bit me many times, yet other users of Python just gave me blank stare when I tried to explain these things.
- ianandrich 6y agoOoh, good observation. I never really thought about how many problems I've had explaining why I'm lifting something or how it makes things better.
- typest 6y agoSorry, can you explain what you mean here? I am always trying to get better at both python and functional programming, but I don't know what you mean about lifting operations up/inlining them in this case with defaultdicts.
- thesz 6y agoTake a look here to get a feel of what rewrite rules are: https://downloads.haskell.org/~ghc/7.0.1/docs/html/users_guide/rewrite-rules.html https://downloads.haskell.org/~ghc/7.0.1/docs/html/users_gui... Haskell has two very nice libraries, bytestring and vector which use rewrite rules to have performance comparable to C code. Operations on dictionaries with default values implemented using inheritance from dictionary. This means that instead of just having conditional expression on the right side I have a call to virtual function and there is an expression on the right side of assignment or return statement. Most of OO virtual machines can JIT things like these into efficient machine code, by specializing. The same is also quite possible with bytecode like in CPython - by optimization in the compiler or by introduction of rewrite rules like above for library implementors to specify rules that apply to any (transformed) user code.
- BerislavLopac 6y agoSo something like Cython or numba?
- thesz 6y agoWhat are these? Do they support rewrite rules on programs?
- 6y ago