AI For Embedded Systems 07.03.2023
AI For Embedded Systems 07.03.2023
Systems
Dr.D.Vaithiyanathan
Assistant Professor
Department of Electronics and Communication Engineering
We don't know how far industry will be able to follow Moore's law.
“Not that many people can afford to (design chips at 10nm and 7nm)
unless they have a high-volume runner and can see a return-on-
investment,” said Samuel Wang, an analyst with Gartner
Recent Technology Nodes
In fact foundries are coming up with intermediate nodes like 8nm which is
shrieked version of 10nm.
It may not cost as high as 7nm but still give some area and power
advantage.
Other way to work around this is stacked die or 3D IC which allow you to
get more transistors in same area.
There is good amount of research around this but I don't see that
commercially popular yet, reason mostly because of thermal issues and
cost.
SMALL DIMENSIONS EFFECTS
Difficulty of MOSFET Devices in nano scale regime
Increased Leakage current
Large Sub-threshold swing
Low Switching Speed
Short Channel Effects
Low reliability
Solution
FinFET
For conventional MOS structure, as the channel length shrinks, the gate
does not have full control over the channel which is not desirable.
In conventional MOS, the gate cannot control leakage path which is far
removed from it. This can be improved using various MOS structures
which allow the scaling of a transistor beyond conventional MOS scaling
limit.
The two new MOS structures, Silicon on Insulator (SOI) and FinFET
are introduced. The main objective of both the structures is to
maximize gate-to-channel capacitance and minimize drain-to-channel
capacitance.
FINFET IN MICROELECTRONICS INDUSTRY
Other foundries that are offering FinFET technology are TSMC, Global
Foundry, and Samsung.
In 2014, TSMC announced that it has produced its first fully functional
ARM-based networking processor with 16nm FinFET technology.
Foundries that are offering FD-SOI technology are IBM, Global Foundry,
and Samsung.
Both FinFET and SOI structure have better gate control and lower
threshold voltage with less leakage.
Metallic carbon nanotubes (CNTs) are promising candidates that can potentially
address the challenges faced by copper and thereby extend the lifetime of
electrical interconnects.
The key drivers behind this trend are benefits in terms of the power, area, plus
various other features that become possible with lower geometries.
Distributed Systems
Internet-of-Things
Narrow definition:
A computer system (software and hardware) that interacts
with its physical environment, mainly without human
intervention
That would exclude printers, modems, portable devices such as dvd
and mp3 players, etc.
Some common characteristics of embedded
systems
Single-functioned
Executes a single program, repeatedly
Tightly-constrained
Low cost, low power, small, fast, etc.
General-Purpose Processor:
More expensive
Medium processing power
Suitable but not optimized for any application
High power consumption
FPGA:
Good processing power
Longer development time
Medium cost
Low power consumption
ASIC:
High processing power
Very low power consumption
Expensive at low volume
Optimized for specific application (hardware accelerators)
Long development time
Design challenge – optimizing design metrics
Obvious design goal:
Construct an implementation with desired functionality
Design metric
A measurable feature of a system’s implementation
Optimizing design metrics is a key challenge
Design challenge – optimizing design metrics
Common metrics
Unit cost: the monetary cost of manufacturing each copy of the system,
excluding NRE cost
A designer must be
Digital camera chip comfortable with various
CCD
A2D
CCD preprocessor Pixel coprocessor D2A technologies in order to
lens choose the best for a given
JPEG codec Microcontroller Multiplier/Accum application and constraints
DMA controller Display ctrl
Market window
Period during which the
product would have highest
sales
Time (months)
Average time-to-market
constraint is about 8 months
Delays can be costly
Losses due to delayed market entry
Simplified revenue model
Peak revenue
Product life = 2W, peak at W
Revenues ($)
Loss
D W 2W The difference between the on-
On-time Delayed Time
entry entry
time and delayed triangle areas
Losses due to delayed market entry (cont.)
Area = 1/2 * base * height
Peak revenue On-time = 1/2 * 2W * W
Revenues ($)
Hard deadline
Failsafe
Fail-operational
Soft deadline
Firm deadline
If a result has utility even after the deadline has passed, the
deadline is classified as soft, otherwise it is firm.
If severe consequences could result if a firm deadline is missed,
the deadline is called hard.
Example: Consider a traffic signal at a road before a railway
crossing. If the traffic signal does not change to red before the
train arrives, an accident could result.
Fail-Safe hard-deadline RT
systems
If a safe state can be identified and quickly reached upon the
occurrence of a failure, then we call the system fail-safe.
Microprocessor
Intel: 4004, ..8080,.. x86
Comsumer Industrial
Freescale: 6800, .. 9S12,.. PowerPC
ARM, DEC, SPARC, MIPS,
PowerPC, Natl. Semi.,…
1-54
An embedded system example – Digital camera
Digital camera chip
CCD
lens
Courtesy: Philips
Design at a crossroad - System-on-a-Chip
• Embedded applications
where cost, performance,
Multi- and energy are the real
500 k Gates FPGA
Analog
Spectral issues!
RAM + 1 Gbit DRAM
Imager • DSP and control intensive
Preprocessing • Mixed-mode
• Combines programmable
C and application-specific
64 SIMD Processor system modules
Array + SRAM +2 Gbit • Software plays crucial role
DRAM
Image Conditioning Recog-
nition
100 GOPS
The Future of Embedded Systems
In the past an embedded system was more or less isolated
Safety issues
The EPC is unique product identification, but does not reveal anything
about the properties of the product.
Two things that have the same properties, but are designed by two different
manufacturers, will have completely different EPCs.
Passive RFID tags
Passive RFID Tags. No power supply. They get the power needed
for their operation from energy harvested out of the electric field
that is beamed on them by the RFID reader. The energy required
to operate a passive tag of the latest generation is below 30 mW
and the cost of such a tag is below 5 ¢.
Due to the low level of the available power and the cost pressure
on the production of RFID tags, the communication protocols of
passive RFID tags do not conform to the standard Internet
protocols. Specially designed communication protocols between
the RFID tag and the RFID reader that consider the constraints of
passive RFID tags have been standardized by the ISO (e.g., ISO
18000-6C also known as the EPC global Gen 2) and are
supported by a number of manufacturers.
Active RFID tags
Active RFID Tags
have their own on-board power supply
The lifetime of an active tag is limited by the lifetime of the battery
typically in the order of a year.
a microcontroller
a wireless communication
controller
WSN node
A sensor node can acquire a variety of physical,
chemical, or biological signals to measure properties of
its environment.
WSN node constraints
Sensor nodes are resource constrained.
issues are:
authentic identification of a smart object,
autonomic management and self-organization of networks of smart objects,
diagnostics and maintenance,
intrusion of privacy
Safety issues
Autonomous mobile robots and self-driving cars
Key technologies for IoT
low-power wireless communication: no need of a
physical connection.
The future: of IoT devices opens many new opportunities for energy savings:
Smart buildings: individual climate and lighting control in residential buildings
Smart grids: reduced energy loss in transmission by the installation of smart grids,
Smart meters: better coordination of energy supply and energy demand
A smart object can monitor its own operation and call for
preventive or spontaneous maintenance in case a part wears
out or a physical fault is diagnosed
Body area networks that are part of the clothing can monitor the
behavior of impaired persons and send out alarm messages if an
emergency is developing.
Smart labels on drugs can help a patient to take the right medication at
the right time and enforce drug compliance.
The division of work between a smart object and the cloud will be
determined, to a considerable degree, by privacy and energy
considerations
If the energy required to execute a task locally is larger than the energy
required to send the task parameters to a server in the cloud, then the
task is a candidate for remote processing.
However, there are other aspects that influence the decision about work
distribution: autonomy of the smart object, response time, reliability,
and security.
SoC Design
Key topics of system-on-a-chip
Divide-and-conquer view of SoC
Design
Programmable Processor
Rapid development in the Multimedia algorithm
research – No. of approaches to meet the diverse
computing requirement.
97 May 5, 2024
Programmable Processor
The functionality of a specific system can be easily
upgraded by a change in software.
99 May 5, 2024
A common software-hardware co-design methodology
3. Algorithm optimization.
4. Software optimization.
By using existing and high-performance IP, Soc designers not only can save
time and resources, but also can create a mind blowing solutions that users want.
Emerging 3D stacking technology introduces more freedom and also places more
constraints on future designs.
116 May 5, 2024
Multi-Processor SoCs
A design can integrate multiple programmable cores,
Which are individually optimized to a particular characteristic of different
application fields in order to deliver high performances.
They complement each other with flexibility at reduced system cost.
Additionally, if the IPs integrated onto a chip come from more than
once source, IP providers and SoC integrators must work closely
together to define effective test strategies.
2. IP Integration
3. Network-on-Chip
4. Embedded Memory
5. Reliability
1. How to integrate analog IP safely; in particular, how to deal with noise from the analog
domain to the digital domain or vice versa.
3. How to handle its I/O requests in a timely manner without over-provisioning resources for
it.
4. How to migrate IPs from one process technology to the next one as quickly as possible. Is
synthesizable soft IP better than customized hard IP even though customized hard IP may be
more efficient.
5. How to effectively test and verify the whole system when the IPs come from different
sources.
These are the challenges beyond simply placing components together. We need good strategies
126 for the integration of hardware and software IP components. May 5, 2024
Network-on-Chip
The performance of next-generation SoCs will be limited by the ability to
efficiently connect the functional blocks together, and to accommodate their
communication requirements.
First, the delay and energy of communication wires do not scale down linearly as
the transistor size shrinks in the future. The interconnect will consume a
significant amount of chip energy.
127 May 5, 2024
Network-on-Chip
Second, because processor and interconnect architecture share a common power
and thermal budget, optimizing the power consumption of each in isolation can
have a significant impact on the other’s power and performance.
Nevertheless, the on-die communication architectures cannot just mimic the off-
die communication.
We need different designs, for eg., while compression of contents in saved power
consumption for off-die bus communication, compression may need more power
for on-die and short-distance communicaiton.
An architect must examine all these factors to determine the best one for the
design.
The amount and the placement of each kind of memory in the SoC will
greatly affect access efficiency and power.
130 May 5, 2024
Embedded Memory
Additionally, cache may introduce indeterminate delay, cache coherence, and
memory consistency challenges.
An example of this is the cell architecture developed by Sony, Toshiba, and IBM.
A software control local buffer reduces the uncertainty when it comes to latency,
but of its use makes the software more complex.
Furthermore, because digital, mixed-signal, RF, and memory blocks are tightly
integrated, the power and substrate noise may cause sensitive blocks to suffer
from functional failures.
Smaller feature sizes lead to more failures over time from electrostatic
overstressing and electro-migration. While transistors might fail, the
entire system cannot fault.
Some of the basic fault tolerance principles that we used in the era of
mainframe computers can potentially be applied to today’s designs.
133 May 5, 2024
Reliability
For example, we can detect when a circuit fails and shift the work
to another circuit through hardware/firmware based self-
management.
Future!!
!
Early mobile phones - Ericsson
SoC
Central processing core
Data-dominated Subsystem
regular & predictable
transformational tasks
with high parallelism
SOC Complexity / Abstraction
Conquer the SoC Complexity
Use a known real entity
A pre-designed component (IP, VC reuse)
Modeling
At different level
Consistent and accurate
Example-Set Top Box Controller
IBM’s SoC
Generic Wireless / Computing
Emotion Engine in PS2
Traditional Embedded System
Power Supply
Ethernet Audio CLK
CLK
MAC Codec
GP I/O Interrupt
Controller
Timer
Address
Decode
Unit
CPU UART
L
(uP / DSP) Co- C
Memory Proc. custom
CLK Controller IF-logic
GP I/O Interrupt
Controller
Timer
Address
Decode
Unit
CPU UART
L
(uP / DSP) Co- C
Memory Proc. custom
CLK Controller IF-logic
Power Supply
L
C
Machine
Learning Planning
Expert
NLP Vision Robotics Systems
What is Artificial Intelligence ?
• making computers that think?
• the automation of activities we associate with human
thinking, like decision making, learning ... ?
• the art of creating machines that perform functions that
require intelligence when performed by people ?
• the study of mental faculties through the use of
computational models ?
What is Artificial Intelligence ?
• the study of computations that make it possible to
perceive, reason and act ?
• a field of study that seeks to explain and emulate
intelligent behaviour in terms of computational
processes ?
• a branch of computer science that is concerned with
the automation of intelligent behaviour ?
• anything in Computing Science that we don't yet
know how to do properly ? (!)
What is Artificial Intelligence ?
HUMAN RATIONAL
Systems that act like humans:
Turing Test
• “The art of creating machines that
perform functions that require
intelligence when performed by people.”
(Kurzweil)
• “The study of how to make computers do
things at which, at the moment, people
are better.” (Rich and Knight)
Systems that act like humans
?
• You enter a room which has a computer terminal. You
have a fixed period of time to type what you want into
the terminal, and study the replies. At the other end of
the line is either a human being or a computer system.
• Intelligent behavior
– to achieve human-level performance in all
cognitive tasks
Systems that act like humans
• These cognitive tasks include:
– Natural language processing
• for communication with human
– Knowledge representation
• to store information effectively & efficiently
– Automated reasoning
• to retrieve & answer questions using the stored
information
– Machine learning
• to adapt to new circumstances
The total Turing Test
• Includes two more issues:
– Computer vision
• to perceive objects (seeing)
– Robotics
• to move objects (acting)
What is Artificial Intelligence ?
HUMAN RATIONAL
Systems that think like humans:
cognitive modeling
• Humans as observed from ‘inside’
• How do we know how humans think?
– Introspection vs. psychological experiments
• Cognitive Science
HUMAN RATIONAL
Systems that think ‘rationally’
"laws of thought"
• Humans are not always ‘rational’
• Rational - defined in terms of logic?
• Logic can’t express everything (e.g. uncertainty)
• Logical approach is often not feasible in terms of
computation time (needs ‘guidance’)
• “The study of mental facilities through the use of
computational models” (Charniak and
McDermott)
• “The study of the computations that make it
possible to perceive, reason, and act” (Winston)
What is Artificial Intelligence ?
HUMAN RATIONAL
Systems that act rationally:
“Rational agent”
• Rational behavior: doing the right thing
• The right thing: that which is expected to
maximize goal achievement, given the
available information
• Giving answers to questions is ‘acting’.
[f: P* A]
For any given class of environments and tasks, we seek the agent
(or class of agents) with the best performance
• Psychology
– How do humans think and act?
– The study of human reasoning and acting
– Provides reasoning models for AI
– Strengthen the ideas
• humans and other animals can be considered as
information processing machines
The Foundation of AI
• Computer Engineering
– How to build an efficient computer?
– increased costs
– difficulty with software development - slow
and expensive
– few experienced programmers
– few practical products have reached the
market as yet.
Search
• Search is the fundamental technique of AI.
– Possible answers, decisions or courses of action are structured
into an abstract space, which we then search.
• Search is either "blind" or “uninformed":
– blind
• we move through the space without worrying
about what is coming next, but recognising the
answer if we see it
– informed
• we guess what is ahead, and use that information
to decide where to look next.
• We may want to search for the first answer that satisfies our goal,
or we may want to keep searching until we find the best answer .
Knowledge Representation & Reasoning
• The second most important concept in AI
Declarative Procedural
• Declarative knowledge deals with factoid questions (what is the capital of India?
Etc.)
• Procedural knowledge deals with “How”
• Procedural knowledge can be embedded in declarative knowledge
Planning
Given a set of goals, construct a sequence of actions that achieves those
goals:
– often very large search space
– but most parts of the world are independent of most other parts
– often start with goals and connect them to actions
– no necessary connection between order of planning and order of
execution
– what happens if the world changes as we execute the plan and/or our
actions don’t produce the expected results?
Learning
• If a system is going to act truly appropriately,
then it must be able to change its actions in
the light of experience:
– how do we generate new facts from old ?
– how do we generate new concepts ?
– how do we learn to distinguish different
situations in new environments ?
Interacting with the Environment
• In order to enable intelligent behaviour, we will have to
interact with our environment.
• Properly intelligent systems may be expected to:
– accept sensory input
• vision, sound, …
– interact with humans
• understand language, recognise speech,
generate text, speech and graphics, …
– modify the environment
• robotics
History of AI
• AI has a long history
– Ancient Greece
• Aristotle
– Historical Figures Contributed
• Ramon Lull
• Al Khowarazmi
• Leonardo da Vinci
• David Hume
• George Boole
• Charles Babbage
• John von Neuman
– As old as electronic computers themselves (c1940)
The ‘von Neuman’ Architecture
History of AI
• Origins
– The Dartmouth conference: 1956
• John McCarthy (Stanford)
• Marvin Minsky (MIT)
• Herbert Simon (CMU)
• Allen Newell (CMU)
• Arthur Samuel (IBM)
• The Turing Test (1950)
• “Machines who Think”
– By Pamela McCorckindale
Periods in AI
• Early period - 1950’s & 60’s
– Game playing
• brute force (calculate your way out)
– Theorem proving
• symbol manipulation
– Biological models
• neural nets
• Symbolic application period - 70’s
– Early expert systems, use of knowledge
• Commercial period - 80’s
– boom in knowledge/ rule bases
Periods in AI cont’d
• period - 90’s and New Millenium
• Real-world applications, modelling, better
evidence, use of theory, ......?
• Topics: data mining, formal models, GA’s, fuzzy
logic, agents, neural nets, autonomous systems
• Applications
– visual recognition of traffic
– medical diagnosis
– directory enquiries
– power plant control
– automatic cars
Fashions in AI
Progress goes in stages, following funding booms and crises: Some examples:
1. Machine translation of languages
1950’s to 1966 - Syntactic translators
1966 - all US funding cancelled
1980 - commercial translators available
2. Neural Networks
1943 - first AI work by McCulloch & Pitts
1950’s & 60’s - Minsky’s book on “Perceptrons” stops nearly all work on nets
1986 - rediscovery of solutions leads to massive growth in neural nets research
The UK had its own funding freeze in 1973 when the Lighthill report reduced AI work
severely -Lesson: Don’t claim too much for your discipline!!!!
Look for similar stop/go effects in fields like genetic algorithms and evolutionary
computing. This is a very active modern area dating back to the work of Friedberg in
1958.
Symbolic and Sub-symbolic AI
• Symbolic AI is concerned with describing and
manipulating our knowledge of the world as explicit
symbols, where these symbols have clear relationships to
entities in the real world.
– dependability,
– efficiency,
– autonomy,
– easy modeling,
– maintenance costs
– insufficient alternatives
Intelligent Embedded Systems (IES)
• IES are ES having the capacity of reasoning
about their external environments even in the
presence of uncertainty and adapt their
behavior accordingly.