Inteligencia Artificial Representación del conocimiento a través de restricciones (continuación)



Similar documents
Stochastic Local Search Algorithms

Integer Programming: Algorithms - 3

Smart Graphics: Methoden 3 Suche, Constraints

Genetic Algorithm. Based on Darwinian Paradigm. Intrinsically a robust search and optimization mechanism. Conceptual Algorithm

Sales Management Main Features

Lecture. Simulation and optimization

Hybrid Evolution of Heterogeneous Neural Networks

Práctica 1: PL 1a: Entorno de programación MathWorks: Simulink

Ranking de Universidades de Grupo of Eight (Go8)

Solving (NP-Hard) Scheduling Problems with ovirt & OptaPlanner. Jason Brooks Red Hat Open Source & Standards SCALE13x, Feb 2015

Principles of Data Mining by Hand&Mannila&Smyth

Técnicas Avanzadas de Inteligencia Artificial Dpt. Lenguajes y Sistemas Informáticos. FISS. UPV-EHU

Optimization Algorithms in Function of Binary Character Recognition

Equity and Fixed Income

School of Electrical, Electronic and Telecommunication Engineering, Universidad Industrial de Santander, Colombia.

Propiedades del esquema del Documento XML de envío:

Chapter 12 Intellectual Development from One One to Three to Three

Evaluation of Different Task Scheduling Policies in Multi-Core Systems with Reconfigurable Hardware

Parallel & Distributed Optimization. Based on Mark Schmidt s slides

Cursos Generales Complementarios. Universidad del TURABO. Escuela: Ingeniería Grado: Bachillerato

Lab 4: 26 th March Exercise 1: Evolutionary algorithms

Algoritmo de PRIM para la implementación de laberintos aleatorios en videojuegos

DYNA

Introduction To Genetic Algorithms

Manejo Basico del Servidor de Aplicaciones WebSphere Application Server 6.0

Article received on April 22, 2008; accepted on November 10, 2008

Schema XML_PGE.xsd. element GrupoInformes. attribute XML_PGE.xsd unqualified qualified

Resource Scheduling in Cloud using Bacterial Foraging Optimization Algorithm

ENVIRONMENT: Collaborative Learning Environment

Título del curso Créditos Pre-requisitos

Berkeley CS191x: Quantum Mechanics and Quantum Computation Optional Class Project

Weekly Sales Forecasting

Curriculum Reform in Computing in Spain

PROCESS OF LOAD BALANCING IN CLOUD COMPUTING USING GENETIC ALGORITHM

INTELIGENCIA DE NEGOCIO CON SQL SERVER

New words to remember

IBM PureSystems: Familia de Sistemas Expertos Integrados

EE 1130 Freshman Eng. Design for Electrical and Computer Eng.

Cuánto se demora una pit stop?

Model-based Parameter Optimization of an Engine Control Unit using Genetic Algorithms

Modern Heuristic Optimization Techniques with Applications to Power Systems

CS MidTerm Exam 4/1/2004 Name: KEY. Page Max Score Total 139

Entry to Year 7 - Information for Parents

Memory Allocation Technique for Segregated Free List Based on Genetic Algorithm

Visión general de la integración con asanetwork

Skills Development Matrix

Scenario: Optimization of Conference Schedule.

Guía del Alumno. Inglés. Mantenimiento, Operación y Diseño con Dispositivos y Circuitos Electrónicos Digitales

A Robust Method for Solving Transcendental Equations

A Graphical Visualization Tool for Analyzing the Behavior of Metaheuristic Algorithms

Marta Zorrilla Universidad de Cantabria

Bucle for_in. Sintaxis: Bucles for_in con listas. def assessment(grade_list): """ Computes the average of a list of grades

Entrenamiento a Embajadores Ambassador training

International Journal of Software and Web Sciences (IJSWS)

50399AE Diseño de soluciones Business Intelligence con Microsoft SQL Server 2008

Cambridge IGCSE.

Información On Demand Podemos predecir lo que sucederá?

HPN Product Tools. Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.

The Problem of Scheduling Technicians and Interventions in a Telecommunications Company

Tables of significant values of Jaccard's index of similarity

Comparison of algorithms for automated university scheduling

Tutorial 1. Introduction to robot

Knowledge Engineering (Ingeniería del Conocimiento)

-ING spelling. Write the -ING form of the verbs in the chart. Escriba la forma -ING de los verbos en la tabla.

An Efficient load balancing using Genetic algorithm in Hierarchical structured distributed system

Problema 1. x 2. 4 Optimal Solution. x 1 = 3, x 2 = 1.5 (3,1.5) x 1 (0,0) (4,0) Optimal Solution x 1 = 0, x 2 = 3. Value of Objective Function = 18

About the Author. The Role of Artificial Intelligence in Software Engineering. Brief History of AI. Introduction 2/27/2013

Física Computacional Conceptos de programación.

1 Objetivos didácticos_unit 1 2 Objetivos didácticos_unit 2

CITY OF LAREDO Application for Certification of Compliance for Utility Connection ($ Application Fee Ordinance No.

Original Article Efficient Genetic Algorithm on Linear Programming Problem for Fittest Chromosomes

STUDY ON APPLICATION OF GENETIC ALGORITHM IN CONSTRUCTION RESOURCE LEVELLING

Logistic Regression for Spam Filtering

Asexual Versus Sexual Reproduction in Genetic Algorithms 1

PATTERN RECOGNITION AND MACHINE LEARNING CHAPTER 4: LINEAR MODELS FOR CLASSIFICATION

Leave house 1st class starts. Listen and draw the hands of the clocks. What time is it now? Write the time now in two different ways.

Wireless Sensor Networks Coverage Optimization based on Improved AFSA Algorithm

Towards a Methodology for the Design of Intelligent Tutoring Systems

Work Instruction (Instruccion de Trabajo) Wistron InfoComm (Texas) Corp.

Presente Continuo con idea de futuro

Genetic Algorithms commonly used selection, replacement, and variation operators Fernando Lobo University of Algarve

Projects - Neural and Evolutionary Computing

Prepárate. BT Computer ABCs for Women in Transition

Genetic Algorithms and Sudoku

AP SPANISH LITERATURE 2009 SCORING GUIDELINES

Héctor Vargas P.O. Box 2808 Calexico, CA Phone: ( ) Cell: ( )

Transcription:

Inteligencia Artificial Representación del conocimiento a través de restricciones (continuación) Gloria Inés Alvarez V. Pontifica Universidad Javeriana Cali Periodo 2014-2 Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 1

Comprobación de lectura 1. Dar un ejemplo de una expresión de la lógica de primer orden que contenga los siguientes elementos: términos, cuantificadores, constantes, variables, predicados, funciones 2. Explicar cuál es la semántica del ejemplo anterior 3. Describir los pasos de la ingeniería del conocimiento en lógica de primer orden Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 2

Sobre la Clase de Hoy Estudiaremos: El problema de satisfacción de restricciones Estrategias locales para su solución Objetivos de aprendizaje: Conocer algunas técnicas de búsqueda local y su aplicación a la solución del problema de satisfacción de restricciones. Técnica voraz descendente randomizada Búsqueda local estocástica Técnicas de lista tabu Búsqueda paralela Beam search Algoritmos genéticos Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 3

Local Search Local Search (Greedy Descent): Maintain an assignment of a value to each variable. Repeat: Select a variable to change Select a new value for that variable Until a satisfying assignment is found Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 4

Local Search for CSPs Aim: find an assignment with zero unsatisfied constraints. Given an assignment of a value to each variable, a conflict is an unsatisfied constraint. The goal is an assignment with zero conflicts. Heuristic function to be minimized: the number of conflicts. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 5

Greedy Descent Variants To choose a variable to change and a new value for it: Find a variable-value pair that minimizes the number of conflicts Select a variable that participates in the most conflicts. Select a value that minimizes the number of conflicts. Select a variable that appears in any conflict. Select a value that minimizes the number of conflicts. Select a variable at random. Select a value that minimizes the number of conflicts. Select a variable and value at random; accept this change if it doesn t increase the number of conflicts. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 6

Complex Domains When the domains are small or unordered, the neighbors of an assignment can correspond to choosing another value for one of the variables. When the domains are large and ordered, the neighbors of an assignment are the adjacent values for one of the variables. If the domains are continuous, Gradient descent changes each variable proportionally to the gradient of the heuristic function in that direction. The value of variable X i goes from v i to Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 7

Complex Domains When the domains are small or unordered, the neighbors of an assignment can correspond to choosing another value for one of the variables. When the domains are large and ordered, the neighbors of an assignment are the adjacent values for one of the variables. If the domains are continuous, Gradient descent changes each variable proportionally to the gradient of the heuristic function in that direction. The value of variable X i goes from v i to v i η h X i. η is the step size. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 8

Problems with Greedy Descent a local minimum that is not a global minimum a plateau where the heuristic values are uninformative a ridge is a local minimum where n-step look-ahead might help Ridge Plateau Local Minimum Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 9

Randomized Algorithms Consider two methods to find a minimum value: Greedy descent, starting from some position, keep moving down & report minimum value found Pick values at random & report minimum value found Which do you expect to work better to find a global minimum? Can a mix work better? Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 10

Randomized Greedy Descent As well as downward steps we can allow for: Random steps: move to a random neighbor. Random restart: reassign random values to all variables. Which is more expensive computationally? Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 11

1-Dimensional Ordered Examples Two 1-dimensional search spaces; step right or left: (a) (b) Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 12

Stochastic Local Search Stochastic local search is a mix of: Greedy descent: move to a lowest neighbor Random walk: taking some random steps Random restart: reassigning values to all variables Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 13

Random Walk Variants of random walk: When choosing the best variable-value pair, randomly sometimes choose a random variable-value pair. When selecting a variable then a value: Sometimes choose any variable that participates in the most conflicts. Sometimes choose any variable that participates in any conflict (a red node). Sometimes choose any variable. Sometimes choose the best value and sometimes choose a random value. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 14

Comparing Stochastic Algorithms How can you compare three algorithms when one solves the problem 30% of the time very quickly but doesn t halt for the other 70% of the cases one solves 60% of the cases reasonably quickly but doesn t solve the rest one solves the problem in 100% of the cases, but slowly? Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 15

Comparing Stochastic Algorithms How can you compare three algorithms when one solves the problem 30% of the time very quickly but doesn t halt for the other 70% of the cases one solves 60% of the cases reasonably quickly but doesn t solve the rest one solves the problem in 100% of the cases, but slowly? Summary statistics, such as mean run time, median run time, and mode run time don t make much sense. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 16

Runtime Distribution Plots runtime (or number of steps) and the proportion (or number) of the runs that are solved within that runtime. 1 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 1 10 100 1000 Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 17

Variant: Simulated Annealing Pick a variable at random and a new value at random. If it is an improvement, adopt it. If it isn t an improvement, adopt it probabilistically depending on a temperature parameter, T. With current assignment n and proposed assignment n we move to n with probability e (h(n ) h(n))/t Temperature can be reduced. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 18

Variant: Simulated Annealing Pick a variable at random and a new value at random. If it is an improvement, adopt it. If it isn t an improvement, adopt it probabilistically depending on a temperature parameter, T. With current assignment n and proposed assignment n we move to n with probability e (h(n ) h(n))/t Temperature can be reduced. Probability of accepting a change: Temperature 1-worse 2-worse 3-worse 10 0.91 0.81 0.74 1 0.37 0.14 0.05 0.25 0.02 0.0003 0.000006 0.1 0.00005 2 10 9 9 10 14 Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 19

Tabu lists To prevent cycling we can maintain a tabu list of the k last assignments. Don t allow an assignment that is already on the tabu list. If k = 1, we don t allow an assignment of to the same value to the variable chosen. We can implement it more efficiently than as a list of complete assignments. It can be expensive if k is large. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 20

Parallel Search A total assignment is called an individual. Idea: maintain a population of k individuals instead of one. At every stage, update each individual in the population. Whenever an individual is a solution, it can be reported. Like k restarts, but uses k times the minimum number of steps. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 21

Beam Search Like parallel search, with k individuals, but choose the k best out of all of the neighbors. When k = 1, it is greedy descent. When k =, it is breadth-first search. The value of k lets us limit space and parallelism. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 22

Stochastic Beam Search Like beam search, but it probabilistically chooses the k individuals at the next generation. The probability that a neighbor is chosen is proportional to its heuristic value. This maintains diversity amongst the individuals. The heuristic value reflects the fitness of the individual. Like asexual reproduction: each individual mutates and the fittest ones survive. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 23

Genetic Algorithms Like stochastic beam search, but pairs of individuals are combined to create the offspring: For each generation: Randomly choose pairs of individuals where the fittest individuals are more likely to be chosen. For each pair, perform a cross-over: form two offspring each taking different parts of their parents: Mutate some values. Stop when a solution is found. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 24

Crossover Given two individuals: X 1 = a 1, X 2 = a 2,..., X m = a m Select i at random. Form two offspring: X 1 = b 1, X 2 = b 2,..., X m = b m X 1 = a 1,..., X i = a i, X i+1 = b i+1,..., X m = b m X 1 = b 1,..., X i = b i, X i+1 = a i+1,..., X m = a m The effectiveness depends on the ordering of the variables. Many variations are possible. Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 25

Ejercicio 1 2 3 4 5 6 at, be, he, it, on, eta, hat, her, him, one, desk, dove, easy, else, help, kind, soon, this, dance, first, fuels, given, haste, loses, sense, sound, think, usage Material de David L. Poole and Alan K. Mackworth IA: Representación del conocimiento Pag 26