Quantcast
Channel: Cadence Blogs
Viewing all articles
Browse latest Browse all 6678

Learning is the New Programming: Neural Nets

$
0
0
Whenever I hear of "deep learning," it makes me think of Deep Thought, the computer in The Hitchhiker's Guide to the Galaxy that after years of computation concluded that the answer to the ultimate question of life, the universe, and everything was 42. But deep learning is a true paradigm shift in programming. The old way of programming was to come up with a clever, efficient algorithm and write the code. Maybe there would be some parameters to tune but most of the intelligence originated in the programmer's brain and was captured in the code. Neural networks are a new way of doing things. A very rough algorithm is developed that mostly consists of making sure that the data flows through the network in a sensible way. There is then a training period in which a large number of test cases with known answers (this is a 25-mile-an-hour speed-limit sign, this is a stop sign) are run through the system and used to adjust the parameters. Then, almost as if by magic, when similar real data is examined, the network is able to discriminate. For a bit more detail, see my blog How Is Google So Good at Recognizing Cats? . Vision is the main sensor problem. If you look at sensors by unit volume (on the left below) they are spread across all sorts of different types. But if we look at the amount of data generated by each sensor type (on the right), it is as if vision is the only sensor that exists. Processing that visual data is the big challenge in everything from automated vehicles, facial recognition, classifying photographs, and so on. What is going on is that it is possible to write code to do things that we do not know how to do algorithmically. Take the comparatively straightforward task of recognizing road signs. I say straightforward, since it seems a lot simpler to recognize one of a few dozen possible signs compared to recognizing one of millions of faces. Recognizing faces is difficult but also important for humans, and so a large percentage of our brains is apparently dedicated to recognizing faces and emotions. Anyway, if we had to write an algorithm (in C or Python or something similar) to recognize road signs, we might start by finding what shape the sign is, then try and find the pattern on the sign, and then see which of the library of patterns it is closest to. But with neural networks, we train them rather than program them. If you have a whole datacenter to run your neural network on, then you have a lot of computing power at your disposal. A couple of weeks ago, Cadence hosted a symposium on embedded neural networks. You can think of this as doing neural networks when you only have limited compute power and a limited energy/power budget. Chris Rowen, the CTO of Cadence's IP group, talked about why neural networks are good for embedded applications and what the challenges are: Highly flexible and adaptable to new tasks and data Good for complex, noisy data from sensor-rich systems (e.g., imaging) Deterministic throughput and latency BUT Compute intensive, so high power consumption Large memory footprint Not well understood by embedded architects, from the basic "how does it work?" to experience creating training datasets and other nuts and bolt details Jeff Bier of the Embedded Vision Alliance pointed out the difference as we make this paradigm shift. It used to be in the programming world that we needed many algorithm engineers, lots of compute at runtime. But we had no theory of visual perception, which made it really hard to implement what we could describe. With convolutional neural nets, on the other hand, we needs lots of training data, lots of compute time for runtime but especially for training. We still lack theory but now we can mostly implement what we can show. With embedded neural networks, the training is typically done in a data center since the amount of compute is huge. The parameters derived can then be used in the embedded neural network in a smartphone or camera. However, there is scope for doing some of the visual processing on the device and using a cloud backend to do the later stages, which don't need so much data to be transmitted. This depends subtly on how often the parameters need to change, the data volumes, and so on. Power is involved in recognition, but power is involved in transmitting data over radio (or wired) links. Of course, the further the data has to go, the higher the latency. If a self-driving car is discriminating between a child and a mailbox, long delays are clearly unacceptable. This is an area where there are new developments all the time, so some sort of programmable fabric is the way to implement convolutional neural networks. In practice, that means either FPGAs or a programmable solution such as the Cadence Tensilica Vision P5 DSP (see block diagram above), which is optimized for just these sort of tasks. If you are interested in this field, then there is an upcoming event you should attend. The Embedded Vision Summit will be held in the Santa Clara Convention Center on May 2 to 4. Full details are at www.embeddedvisionsummit.com . There is a 15% discount if you register before March 1.

Viewing all articles
Browse latest Browse all 6678

Trending Articles