Week 3 - Artificial Intelligent PDF
Document Details
![NiceWichita](https://quizgecko.com/images/avatars/avatar-16.webp)
Uploaded by NiceWichita
International Islamic University Malaysia
Tags
Related
Summary
This document is an overview of artificial intelligence (AI), machine learning (ML), and deep learning (DL). It includes information on different types of learning, popular algorithms, and practical applications of ML.
Full Transcript
ISF 2204 Week 3: Business-Driven ICT for IFIs AI Based on Doug, R. (2018) AI 1817 February 14, 2016, “Sophia the robot” was activated…...
ISF 2204 Week 3: Business-Driven ICT for IFIs AI Based on Doug, R. (2018) AI 1817 February 14, 2016, “Sophia the robot” was activated… 1939 Talos, Greek Mythology 2 “However, when you start to look at how artificially intelligent machines do what they do, it’s hard to be sure whether to scream or yawn…” Doug, R. (2018) 3 Overview of Artificial Intelligence Artificial Intelligence » As a technology, artificial intelligence is any system that exhibits behavior that could be interpreted as human intelligence—the ability to reason and learn. » In artificial intelligence, it is an algorithm that tells the machine how to figure out answers to different issues or questions. » An algorithm refers to a set of software-encoded instructions that allows the machine to complete a certain task. 5 Intelligence? Yield Wisdom Ability to make the best and Knowledge most proper use of Understood knowledge information that (sensing is useful (ability universal laws Intelligence and to identify relationships relationships Information stretching collected from between models and composing beyond the multiple known models, Information them into a sources (ability seeing the to compose coherent whole Data presented to explain visible unseen) relationships in an organized part of the into models) fashion reality) Data (understood relationships/pa Raw facts, tterns) figures, symbols, events Learning/Experience 6 Weak AI vs. Strong AI Strong AI imbues machines with human qualities, including self- awareness and emotions, whereas weak AI enables machines to perform only the specific tasks. 7 AI, ML and DL Artificial Intelligence (AI) Machine Successive Learning stages of (ML) computer and analytics automation Deep Learning (DL) 8 AI, ML and DL (Cont.) » Artificial Intelligence (AI) as a broader area of computer science that aims to create a machine capable of learning how to solve a given problem, that is machine acts in a “smart” way, using advanced decision-making processes to go beyond specific instructions supplied by human operators. » Machine Learning (ML), however, is a subset of AI wherein the machine can produce a solution without the algorithm having been explicitly programmed. In ML machine learns data representations, as opposed to task-specific algorithms. » Deep Learning (DL) is a subset of ML that achieves great power and flexibility by learning to represent the world as nested hierarchy of concepts, with each concept defined in relation to simpler concepts, and more abstract representations computed in terms of less abstract ones. 9 Machine Learning What is Machine Learning? » In traditional programming computer is given data and algorithm composed of explicit instructions of how to interpret/understand the data. In other words, in traditional programming algorithm represent a static model of how to interpret the data. » In ML computer is also given data and algorithm. However, that algorithm is composed of rules of how to build the model while the computer is given the ability to independently build, tweak and adjust the model in the process of trying to make sense out of data. » In ML machine independently creates a model of how to describe/ interpret/ understand the data. » The computer is also given the ability to remember what it learned. 11 Primary Components of ML » Learner: The machine. » Data: Input for training and testing the machine and for using the machine to interpret after training. » Algorithm: A mathematical formula that receives and analyzes input data to predict outputs within an acceptable range. » Parameters: Conditions that affect the way the algorithm works. Think of parameters as dials the machine can turn to control the operation of the algorithm. » Hyperparameters: These are parameters that can’t be learned from the data and are left to a human practitioner. » Model: An algorithm with parameters that tells the machine how to process and interpret input data. 12 How ML Works Add hyperparameters (decide on machine learning algorithm) Feed the machine data, typically input-output pairs, to train it. Using the algorithm, machine performs calculations of the inputs, adjusts the model parameters in order to produce the outputs associated with those inputs. the machine creates a model that consists of the algorithm and parameters that most accurately calculate outputs based on the given inputs When you feed the machine inputs with unknown outputs, the machine can now calculate (predict the outputs) 13 Artificial Neural Networks Artificial Neural Networks » ANN is an algorithm that imitates the human brain and has its own artificial neurons like the human brain. » ANN is composed of the artificial neurons, which physically are nothing more than special mathematical functions written in computer code. » These artificial neurons are connected to each other in layers (similar to how neurons are layered in the human brain). Input Layer Hidden Layers Output Layer … … … … 15 Artificial Neural Networks (Cont’) » Neural networks contain three types of layers: an input layer, a hidden layer(s) and an output layer. » The number of hidden layers can be very large. Deep learning neural networks will typically have a really large number of hidden layers composed of thousands, sometimes millions, of nodes. » Each neuron in every layer is connected to every single neuron in the next layer. Input Layer Hidden Layers Output Layer … … … … 16 Individual Neuron » Perceptron » Sigmoid Neuron Getting to Know an Individual Neuron » Perceptron — essentially a single node (a building block) in an artificial neural network. » The perceptron acts like a tiny machine for making decisions—it takes several inputs, multiplies them with their corresponding weights, totals them, and performs a mathematical function on the result to produce an output. w1 Y w2 w3 f(…) 18 Example—Eating or not eating at a restaurant? » x1: whether or not the restaurant is clean » x2: whether or not the is a Spanish version of the menu » x3: whether or not there is a sombrero on the wall X 1 w1 » y = 1 eat » y = 0 do not eat y 3 w2 𝑤𝑖 × 𝑋𝑖 X2 𝑖=1 w3 3 X3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 ≥ 𝛿 𝑡ℎ𝑒𝑛 𝑌 = 1 Perceptron 𝑖=1 3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 < 𝛿 𝑡ℎ𝑒𝑛 𝑌 = 0 𝑖=1 19 Example—Eating or not eating at a restaurant? » x1 = 1 if the restaurant is clean, and x1 = -1 if it is dirty » x2 = 1 if it has Spanish version of the menu, and x2 = -1 if it does not » x3 = -1 if there is a sombrero and x3 = 1 if it has no sombrero X 1 w1 » y = 1 eat » y = 0 do not eat y 3 w2 𝑤𝑖 × 𝑋𝑖 X2 𝑖=1 w3 3 X3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 ≥ 𝛿 𝑡ℎ𝑒𝑛 𝑌 = 1 𝑖=1 3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 < 𝛿 𝑡ℎ𝑒𝑛 𝑌 = 0 𝑖=1 20 Example—Eating or not eating at a restaurant? » Suppose this perceptron weighs all of those factors, X1, X2 and X3, equally (w1 = w2 = w3 = 1) and performs a simple addition/ subtraction function » And we set the threshold must = 2 or higher X 1 w1 » y = 1 eat » y = 0 do not eat y 3 w2 𝑤𝑖 × 𝑋𝑖 X2 𝑖=1 w3 3 X3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 ≥ 2 𝑡ℎ𝑒𝑛 𝑌 = 1 𝑖=1 𝑤1 = 𝑤2 = 𝑤3 = 1 3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 < 2 𝑡ℎ𝑒𝑛 𝑌 = 0 𝑖=1 21 Example—Eating or not eating at a restaurant? Got No Spanish It is sombrero Version clean on the of the wall menu X1 X2 X3 1 1 1 -1 -1 -1 1 -1 -1 -1 1 -1 -1 -1 1 -1 1 1 1 1 -1 1 -1 1 22 Example—Eating or not eating at a restaurant? Got X1*w1 No + Spanish ItUnfortunately, is this sombrero perceptron is too simple toXbe Version 2*w2 clean of much use because it wouldon the tell you to eat at a+ of the X3*w3 wall particular restaurant menu only if it meets all three of= X1 thewconditions 1 X2 thatware 2 important X3 towyou. 3 Sum It1 also has 1 no way 1 to learn. 1 All it 1does is perform 1 3 -1 1 -1 1 -1 1 -3 its addition function and spit out the 1 1 -1 1 -1 1 -1 recommendation -1 1 1 — thumbs 1 up or-1 thumbs 1 down.-1 -1 1 -1 1 1 1 -1 -1 1 1 1 1 1 1 1 1 1 1 -1 1 1 1 1 -1 1 1 1 1 23 Example—Eating or not eating at a restaurant? » Let’s assign w1 = 3, w2 = 6 and w3 = 2 indicating relative importance of the factors » And we set the threshold must = 2 or higher X W 1 1 = 3 » y = 1 eat » y = 0 do not eat y 3 W2 = 6 𝑤𝑖 × 𝑋𝑖 X2 = 2 𝑖=1 W 3 3 X3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 ≥ 2 𝑡ℎ𝑒𝑛 𝑌 = 1 𝑖=1 3 𝑖𝑓 𝑤𝑖 × 𝑋𝑖 < 2 𝑡ℎ𝑒𝑛 𝑌 = 0 𝑖=1 24 Example—Eating or not eating at a restaurant Got No Spanish It is sombrero Version clean on the of the wall menu X1 w1 X2 w2 X3 w3 Sum 1 ×3 1 ×6 1 ×2 11 -1 ×3 -1 ×6 -1 ×2 -11 1 ×3 -1 ×6 -1 ×2 -5 -1 ×3 1 ×6 -1 ×2 1 -1 ×3 -1 ×6 1 ×2 -7 -1 ×3 1 ×6 1 ×2 5 1 ×3 1 ×6 -1 ×2 7 1 ×3 -1 ×6 1 ×2 -1 25 Example—Eating or not eating at a restaurant Got No The Spanish It isgood news is that the perceptron sombrero can learn, by adjusting the Version weights, as we feed it more data. clean on the Suppose we feedof the that shows you’ve eaten at Mexican it data wall restaurants in the menu past that don’t have a Spanish version of the menu. X1 It can w1 look atXthat datawand adjustXthe weightsw3to make Sum 2 2 3 the 1 model×more 3 accurate. 1 It may × 6 decide to 1 lower the× 2weight of 11 -1having a× Spanish 3 version -1 of×a6menu to -14 and increase × 2 the-11 weight of cleanliness to 4, in which case you might eat at a 1 ×3 -1 ×6 -1 ×2 -5 restaurant that’s clean, has no Spanish menu and no sombrero -1 ×on 3 the wall: 1 (1 x 4) +× 6(–1 x 4) +-1 (1 x 2) = 2× 2 1 -1 ×3 -1 ×6 1 ×2 -7 -1 ×3 1 ×6 1 ×2 5 1 ×3 1 ×6 -1 ×2 7 1 ×3 -1 ×6 1 ×2 -1 26 Example—Eating or not eating at a restaurant Got No Spanish It is sombrero Version clean on the of the wall menu X1 w1 X2 w2 X3 w3 Sum 1 ×4 3 1 ×4 6 1 ×2 10 11 -1 ×4 3 -1 ×4 6 -1 ×2 -11 -10 1 ×4 3 -1 ×4 6 -1 ×2 -5 -2 -1 ×4 3 1 ×4 6 -1 ×2 -2 1 -1 ×4 3 -1 ×4 6 1 ×2 -7 -6 -1 ×4 3 1 ×4 6 1 ×2 5 2 1 ×4 3 1 ×4 6 -1 ×2 7 6 1 ×4 3 -1 ×4 6 1 ×2 -1 2 27 Example—Eating or not eating at a restaurant Got No Spanish It is The perceptron could also add bias to increase or sombrero decrease the Version output as a way of improving clean on the the accuracy of of the the output. wall menu Keep in mind that these examples are oversimplified. X1 w1 X2 w2 X3 w3 Sum The key points to remember are that a perceptron 1 ×43 1 ×4 6 1 ×2 performs a function on multiple inputs to produce a 10 11 -1 single× output, 3 4 -1 and that ×a46perceptron -1 ×2 can learn by -10 -11 1adjusting ×43the weights -1 ×4 of its 6inputs and -1 by adding × 2 bias.-2 -5 -1 ×4 3 1 ×4 6 -1 ×2 -2 1 -1 ×4 3 -1 ×4 6 1 ×2 -7 -6 -1 ×4 3 1 ×4 6 1 ×2 5 2 1 ×4 3 1 ×4 6 -1 ×2 7 6 1 ×4 3 -1 ×4 6 1 ×2 -1 2 28 Example—Eating or not eating at a restaurant » The perceptron we used to make our taco decision just now has all binary inputs. » This perceptron is likely to err in two ways: it could steer us clear of a lot of good restaurants, and it could have us eating at some really bad restaurants. » What we need is a sliding scale that gives us some indication of the relative quality of the restaurant — ideally a number between one and zero. » The closer it is to 1 the more confident the network is in the quality of the restaurant. » If it’s close to 0 then we should probably go somewhere else. 29 Reading Input Data » The computer would see the picture as nothing more than a combination of pixels. » If it is a grey scale image some pixels will be black, some will be white, and some will be of different shades of grey. » This image thus can be presented as a matrix that has the numerical value of each pixel. » This matrix will become the input data: 30 Different Types of Learning » Supervised learning: You feed the machine "labeled data”—dependent and independent variables. » Unsupervised learning: the data is not labeled and the machine learning system must use an algorithm to find patterns in the data, natural clustering of the data to groups or “classes”. » Semi-supervised learning: This approach combines supervised and unsupervised learning. You train the machine just a little bit so it gets a high-level overview, then the machine develops its own rules and strategies based on its examination of the data. 31 Popular ML Algorithms Type of Learning Category of Algorithm the machine tries to figure out Classification in which group a new input belongs Supervised Learning find relationships between Regression independent and dependent variables Machine Learning the machine segregates data Clustering with similar traits and moves them into clusters Unsupervised Learning the machine reduces the Dimensionality number of random variables Reduction under consideration 32 What ANN is Good For » ANNs are excellent tools for finding patterns in data… » …which are far too complex or numerous for a human programmer to extract and teach the machine to recognize. 33 Practical Applications of Machine Learning Data Security Investing Online software Healthcare with ML, security ML software can development Diagnosing illnesses software can identify smallest Gathering data significantly earlier than accurately identify patterns of market about how users they would otherwise be newly created anomalies and predict interact with their diagnosed to identifying malware. changes in the market software and variables that predict and in prices of analyze that data to whether a patient will individual stocks and improve usability develop a specific bonds illness Personalised marketing Fraud detection and Online searches Smart devices Analyzing and prevention Google and other Collect data predicting a user's identify transaction online search sites regarding their behavior; coming up patterns that are use machine usage and with recommendations out of sync with a learning to rank personalize their customer's items in their search operation based on purchase history results those patterns 34 ANN in Financial Services Industry » Citibank uses neural networks to find opportunities in financial markets. By carefully examining historical stock market data with neural network software, Citibank financial managers learn of interesting coincidences or small anomalies (called market inefficiencies). » Visa, American Express, and many other credit card companies use a neural network to spot peculiarities in individual accounts and follow up by checking for fraud. Visa estimates neural networks save it $50 million annually. » Insurance companies along with state compensation funds and other carriers use neural network software to identify fraud. The system searches for patterns in billing charges, laboratory tests, and frequency of office visits. 35 » Robotics Common » Natural Language Processing (NLP) AI Applications » IoT Robotics » Robotics involves manipulating objects in the real world. » Combining robotics with artificial intelligence produces machines that can adapt to changing environments and learn how to perform additional tasks. » Robotic devices increasingly getting better “eyes” and other sensors through which they can collect vast amount of data and improve their own performance with the help of built in machine learning algorithms. 37 Understanding Spoken Language with Natural Language Processing » To enable machines to converse with humans, AI programs use natural language processing (NLP): Siri, Alexa, Cortana, text-to-speech conversion in your phone. » Natural language processing makes the interaction much more human. » Natural language processing isn't just about understanding the words; it's also about understanding the context and meaning. » Natural language processing goes beyond simply matching keywords across a database. 38 IoT » The Internet of Things (IoT) the networking capability of computing devices embedded in everyday objects—these can be machines, equipment, appliances, gadgets, systems, sensors etc.—enabling them to collect, send and receive data without human intervention. » Another term commonly associated with the Internet of Things is machine to machine (M2M), which refers to devices that connect directly to other devices. Sensors Gateway Network Cloud Remote System » These objects can communicate with each other and transfer data over a network without requiring human-to-human or human-to-computer interaction. 39 IoT » IoT empowers computer systems “with their own means of gathering information, so they can see, hear and smell the world for themselves, in all its random glory” (Ashton, 2009). » The value of obtaining real-time unbiased data from interconnected “things” lies in our ability to make better-informed decisions, identify new opportunities, and analyze patterns to predict future patterns (for ex. analyze customer behavioral patterns to predict new behaviors). » IoT is transforming our world into a living information system. » Right now the IoT is most commonly found in businesses, health care and factories. The reason for this is that the IoT gives businesses the opportunity to raise their levels of efficiency by saving businesses, governments and healthcare organizations time and money. » According to one estimate, within the next decade there will be more than 150 billion networked sensors in the world, each of which will be generating data 24/7 365 days a year. 40 41 Business-Driven AI [ Framework/Toolkit ] Key Challenges Obtaining You have to feed the network millions of input data and have it fine-tuned enough quality the parameters (weights and biases) until it successfully identifies data patterns. You need a data set that is large enough and that is of good quality. Don't mix Training Set → Validation Set → Test Data Set. Validation dataset is part of training data the larger training set and its sole purpose is to fine tune the parameters and test data of the network. The test dataset is used only to measure the final performance of the trained network. Is training data If you feed a machine training data that’s not representative of the test representative data, you may think it learned well when it actually didn’t. of the test data? Taking an While supervised machine learning can certainly be used to answer exploratory specific questions and solve specific problems, many organizations approach overlook the exploratory potential of unsupervised learning. Choosing the Don’t assume that machine learning is the best tool for answering every right tool for question or solving every problem. the job 43 Choosing the Right Tool for the Job Yes/ Question Explanation No First check if basic tasks are automated before considering AI You have basic process/task solutions. Automations are cost effective if implemented correctly. 1. ❏ automated? They also standardize your process. This helps in creating the foundation for AI. Can you warranty engagement Assessing the potential impact on existing business processes, roles, ❏ 2. for the adaptation of this and functions is the key. A quick check can reduce the potential for established business process? costly restructurings afterward. Do you have dataset related to Do potentially useful inputs exist? Can you gain access to them? 3. that process that is broad ❏ Quality and quantity of data is the single biggest factor influencing the enough and of high quality? AI decision. Contrary to the hype, the value of AI is determined by the people who Do you have experimental way take it on. Decision-makers and team members alike need to apply a 4. ❏ of thinking in the company? machine learning test-and-learn mentality to establish successful data analysis. Investing in machine learning and seeing results you can not just Do you have access to the right invest in technology. You also need to make sure you have the right 5. ❏ people or specialists? people or specialists to manage the systems and give them the maximum impact. Evaluate how it will contribute to your business: Will it move you closer to becoming frictionless? Will it improve the end-customers Does is contribute value to the 6. ❏ experience? Will it help to get the basics, right? Will it help you to business model/process? innovate (industry, society, technology)? Will it positively reflect on brand? 44 Choosing the Right Tool for the Job AI Expert Machine Deep Systems Learning Learning Supervised Unsupervised supervised Unsupervised » REMEMBER: Just because you have lots of data and need to find patterns in that data doesn’t mean you need AI. 45 ❑ amount of data? AI ❑ variation in that data? ❑ Do you have a clear set of steps for extracting a solution from that data? ✓ Low variation in data/limited ✓ Problem cannot be easily described/it inputs contains certain level of uncertainty /non- ✓ Task require sequential linear problems reasoning (“if… then”), or it just ✓ you need to analyze large volumes of data to need detailed pattern matching make predictions ✓ Problems requires finite steps to ✓ Great variation in data/system must adapt to find a solution changing inputs ✓ Decision making process is quite ✓ Patterns that are difficult to see (you want to transparent identify patterns that you may not even know ✓ Rule-based system exist) ✓ Decision-making process is complete black box. ✓ You need to work with a really large amount of data Expert Machine Deep Systems Learning Learning 46 Semi- Supervised Unsupervised Supervised ✓ Data is clearly and ✓ dataset is too large to ✓ you have massive consistently labeled— be practical for amounts of unlabeled you already have well supervised learning data—you’re unsure how defined categories that ✓ you have some to group and categorize you want the machine to labeled data and lot the data or you want to use to classify input of unlabeled data look at the data in a ✓ You have independent new way ✓ You must have variable and dependent knowledgeable ✓ You have independent variable known pairs trainer and you have variables but no ✓ You must have good data dependent variables knowledgeable trainer ✓ You must have good data (remember GIGO) 47 TQ Recommended Reading Doug, R. (2018) Artificial Intelligence for Business: What You Need to Know about Machine Learning and Neural Networks. Chicago Lakeshore Press. Akerkar, R. (2018). Artificial intelligence for business. Springer. 49