39
Qualitative Spatial- Qualitative Spatial- Temporal Reasoning Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University

Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

  • View
    221

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Qualitative Spatial-Temporal Qualitative Spatial-Temporal ReasoningReasoning

Jason J. LiAdvanced Topics in A.I.

The Australian National University

Page 2: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Spatial-Temporal ReasoningSpatial-Temporal Reasoning

• Space is ubiquitous in intelligent systems

– We wish to reason, make predictions, and plan for events in space

– Modelling space is similar to modelling time.

• Space is ubiquitous in intelligent systems

– We wish to reason, make predictions, and plan for events in space

– Modelling space is similar to modelling time.

Page 3: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Quantitative ApproachesQuantitative Approaches

• Spatial-temporal configurations can be described by specifying coordinates:

– At 10am object A is at position (1,0,1), at 11am it is at (1,2,2)

– From 9am to 11am, object B is at (1,2,2)– At 11am object C is at (13,10,12), and at 1pm it

is at (12,11,12)

• Spatial-temporal configurations can be described by specifying coordinates:

– At 10am object A is at position (1,0,1), at 11am it is at (1,2,2)

– From 9am to 11am, object B is at (1,2,2)– At 11am object C is at (13,10,12), and at 1pm it

is at (12,11,12)

Page 4: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

A Qualitative PerspectiveA Qualitative Perspective

• Often, a qualitative description is more adequate

– Object A collided with object B, then object C appeared

– Object C was not near the collision between A and B when it took place

• Often, a qualitative description is more adequate

– Object A collided with object B, then object C appeared

– Object C was not near the collision between A and B when it took place

Page 5: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Qualitative RepresentationsQualitative Representations

• Uses a finite vocabulary– A finite set of relations

• Efficient when precise information is not available or not necessary

• Handles well with uncertainty– Uncertainty represented by disjunction of

relations

• Uses a finite vocabulary– A finite set of relations

• Efficient when precise information is not available or not necessary

• Handles well with uncertainty– Uncertainty represented by disjunction of

relations

Page 6: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Qualitative vs. FuzzyQualitative vs. Fuzzy

• Fuzzy representations take approximations of real values

• Qualitative representations make only as much distinctions as necessary

– This ensures the soundness of composition

• Fuzzy representations take approximations of real values

• Qualitative representations make only as much distinctions as necessary

– This ensures the soundness of composition

Page 7: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Qualitative Spatial-Temporal ReasoningQualitative Spatial-Temporal Reasoning

• Represent space and time in a qualitative manner

• Reasoning using a constraint calculus with infinite domains

– Space and time is continuous

• Represent space and time in a qualitative manner

• Reasoning using a constraint calculus with infinite domains

– Space and time is continuous

Page 8: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Trinity of a Qualitative CalculusTrinity of a Qualitative Calculus

• Algebra of relations

• Domain

• Weak-Representation

• Algebra of relations

• Domain

• Weak-Representation

Page 9: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Algebra of RelationsAlgebra of Relations

• Formally, it’s called Nonassociatve Algebra– Relation Algebra is a subset of such algebras

that its composition is associative– It prescribes the constraints between elements

in the domain by the relationship between them.

• Formally, it’s called Nonassociatve Algebra– Relation Algebra is a subset of such algebras

that its composition is associative– It prescribes the constraints between elements

in the domain by the relationship between them.

Page 10: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Algebra of RelationsAlgebra of Relations

• It usually has these operations:– Composition:

• If A is related to B, B is related to C, what is A to C

– Converse:• If A is related to B, what is B’s relation to A

– Intersection/union: • Defined set-theoretically

– Complement:• A is not related to B by Rel_A, then what is the relation?

• It usually has these operations:– Composition:

• If A is related to B, B is related to C, what is A to C

– Converse:• If A is related to B, what is B’s relation to A

– Intersection/union: • Defined set-theoretically

– Complement:• A is not related to B by Rel_A, then what is the relation?

Page 11: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example – Point AlgebraExample – Point Algebra

• Points along a line• Composition of

relations– {<} ; {=} = {<}– {<,=} ; {<} = {<}– {<,>} ; {<} = {<,=,>} – {<,=} ; {>,=} = {=}

• Points along a line• Composition of

relations– {<} ; {=} = {<}– {<,=} ; {<} = {<}– {<,>} ; {<} = {<,=,>} – {<,=} ; {>,=} = {=}

Page 12: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example – RCC8Example – RCC8

Page 13: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

DomainDomain

• The set of spatial-temporal objects we wish to reason

• Example:– 2D Generic Regions– Points in time

• The set of spatial-temporal objects we wish to reason

• Example:– 2D Generic Regions– Points in time

Page 14: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Weak-RepresentationWeak-Representation

• How the algebra is mapped to the domain (JEPD)

– Jointly Exhaustive: everything is related to everything else

– Pairwise Disjoint: any two entities in the domain is related by an atomic relation

• How the algebra is mapped to the domain (JEPD)

– Jointly Exhaustive: everything is related to everything else

– Pairwise Disjoint: any two entities in the domain is related by an atomic relation

Page 15: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Mapping of Point AlgebraMapping of Point Algebra

• Domain: Real values– Between any two value there is a value– We say the weak representation is a

representation– Any consistent network can be consistently

extended• Domain: Discrete values (whole numbers)

– Weak representation not representation

• Domain: Real values– Between any two value there is a value– We say the weak representation is a

representation– Any consistent network can be consistently

extended• Domain: Discrete values (whole numbers)

– Weak representation not representation

Page 16: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Network of RelationsNetwork of Relations

• Always complete graphs (JEPD)• Set of vertices (VN) and label of edges (LN)• Vertice VN(i) denotes the ith spatial-temporal variable• Label LN(i,j) denote the possible relations between

the two variables VN(i), VN(j) • A network M is a subnetwork of another network N iff

all nodes and labels of M are in N

• Always complete graphs (JEPD)• Set of vertices (VN) and label of edges (LN)• Vertice VN(i) denotes the ith spatial-temporal variable• Label LN(i,j) denote the possible relations between

the two variables VN(i), VN(j) • A network M is a subnetwork of another network N iff

all nodes and labels of M are in N

Page 17: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example of NetworksExample of Networks

• Greece is part of EU and on its boarder

• Czech Republic is part of EU and not on its boarder

• Russia is externally connected to EU and disconnected to Greece

• Greece is part of EU and on its boarder

• Czech Republic is part of EU and not on its boarder

• Russia is externally connected to EU and disconnected to Greece

Page 18: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example of NetworksExample of Networks

Greece

EU Russia

Czech

TPP

NTPP

EC

DC

U

U

Page 19: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Path-ConsistencyPath-Consistency

• Any two variable assignment can be extended to three variables assignment

• Forall 1 <= i, j, k <= n– Rij = Rij ∩ Rik ; Rkj

• Any two variable assignment can be extended to three variables assignment

• Forall 1 <= i, j, k <= n– Rij = Rij ∩ Rik ; Rkj

Page 20: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example of Path-ConsistencyExample of Path-Consistency

Greece

EU Russia

Czech

TPP

NTPP

EC

DC

U

U

Page 21: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example of Path-ConsistencyExample of Path-Consistency

Greece

EU Russia

Czech

TPP

NTPP

EC

DC

DC

U

EC ; NTPPi = DC

Conv(NTPP) = NTPPi

Page 22: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example of Path-ConsistencyExample of Path-Consistency

Greece

EU Russia

Czech

TPP

NTPP

EC

DC

DC

U

DC ; DC = U

Conv(DC) = DC

Page 23: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example of Path-ConsistencyExample of Path-Consistency

Greece

EU Russia

Czech

TPP

NTPP

EC

DC

DC

DC,EC,PO,TPPi,NTPPi

TPP ; NTPPi = {DC,EC,PO,TPPi, NTPPi}

Conv(NTPP) = NTPPi

Page 24: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Example of Path-ConsistencyExample of Path-Consistency

• From the information given, we were able to eliminate some possibilities of the relation between Czech and Greece

• From the information given, we were able to eliminate some possibilities of the relation between Czech and Greece

Page 25: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

ConsistencyConsistency

• A network is consistent iff– There is an instantiation in the domain

such that all constraints are satisfied.

• A network is consistent iff– There is an instantiation in the domain

such that all constraints are satisfied.

Page 26: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

ConsistencyConsistency

• A nice property of a calculus, would be that path-consistency entails consistency for CSPs with only atomic constraints.

– If all the transitive constraints are satisfied, then it can be realized.

• RCC8, Point Algebra all have this property• But many do not…

• A nice property of a calculus, would be that path-consistency entails consistency for CSPs with only atomic constraints.

– If all the transitive constraints are satisfied, then it can be realized.

• RCC8, Point Algebra all have this property• But many do not…

Page 27: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Path-Consistency and ConsistencyPath-Consistency and Consistency

• Path-consistency is different to (general) consistency

– Consider 5 circular disks– All externally connected to

each other– This is PC, but not Consistent!

• Path-consistency is different to (general) consistency

– Consider 5 circular disks– All externally connected to

each other– This is PC, but not Consistent!

Page 28: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Important Problems in Qualitative Spatial-Temporal Reasoning

Important Problems in Qualitative Spatial-Temporal Reasoning

• A very nice property of a qualitative calculus is that if path-consistency entails consistency

– If the network is path-consistent, then you can get an instantiation in the domain

– Usually, it requires a manual proof – Any way to do it automatically?

• A very nice property of a qualitative calculus is that if path-consistency entails consistency

– If the network is path-consistent, then you can get an instantiation in the domain

– Usually, it requires a manual proof – Any way to do it automatically?

Page 29: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Important Problems in Qualitative Spatial-Temporal Reasoning

Important Problems in Qualitative Spatial-Temporal Reasoning

• Computational Complexity– What is the complexity for deciding

consistency?• P? NP? NP-Hard? P-SPACE? EXP-SPACE?

• Computational Complexity– What is the complexity for deciding

consistency?• P? NP? NP-Hard? P-SPACE? EXP-SPACE?

Page 30: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Important Problems in Qualitative Spatial-Temporal Reasoning

Important Problems in Qualitative Spatial-Temporal Reasoning

• Unified theory of spatial-temporal reasoning– Many spatial-temporal calculi have been

proposed• Point Algebra, Interval Algebra, RCC8, OPRA, STAR,

etc.

– How do we combine efficient reasoning calculi for more expressive queries.

• Unified theory of spatial-temporal reasoning– Many spatial-temporal calculi have been

proposed• Point Algebra, Interval Algebra, RCC8, OPRA, STAR,

etc.

– How do we combine efficient reasoning calculi for more expressive queries.

Page 31: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Important Problems in Qualitative Spatial-Temporal Reasoning

Important Problems in Qualitative Spatial-Temporal Reasoning

• Unified theory of spatial-temporal reasoning

– Some approaches combines two calculi to form a new calculi, with mixed results• IA (PA+PA), INDU (IA + Size), etc• BIG Calculus containing all information?• Meta-reasoning to switch calculi?

• Unified theory of spatial-temporal reasoning

– Some approaches combines two calculi to form a new calculi, with mixed results• IA (PA+PA), INDU (IA + Size), etc• BIG Calculus containing all information?• Meta-reasoning to switch calculi?

Page 32: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Important Problems in Qualitative Spatial-Temporal Reasoning

Important Problems in Qualitative Spatial-Temporal Reasoning

• Qualitative representations may have different levels of granularity

– How coarse/fine you want to define the relations• Do you care PP vs. TPP?

– What resolution do you want your representation?

– What level of information do you want to use?

• Qualitative representations may have different levels of granularity

– How coarse/fine you want to define the relations• Do you care PP vs. TPP?

– What resolution do you want your representation?

– What level of information do you want to use?

Page 33: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Important Problems in Qualitative Spatial-Temporal Reasoning

Important Problems in Qualitative Spatial-Temporal Reasoning

• Spatial Planning– Most automated planning problems ignore

spatial aspects of the problem– Most real-life applications uses an ad-hoc

representation for reasoning– How do we use make use of efficient reasoning

algorithms to better plan for spatial-change

• Spatial Planning– Most automated planning problems ignore

spatial aspects of the problem– Most real-life applications uses an ad-hoc

representation for reasoning– How do we use make use of efficient reasoning

algorithms to better plan for spatial-change

Page 34: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Solving ComplexitySolving Complexity

• If path-consistency decide consistency, the problem is polynomial

• If not, then some complexity proof is required

– Transform the problem to one of the known problems

• If path-consistency decide consistency, the problem is polynomial

• If not, then some complexity proof is required

– Transform the problem to one of the known problems

Page 35: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Solving ComplexitySolving Complexity

• Show NP-Hardness, you need to show 1-1 transformation for a subset of the problems to a known NP-Complete Problem

– Deciding consistency for some spatial-temporal networks

– Deciding the Boolean satisfiability problem (3-SAT)

• Show NP-Hardness, you need to show 1-1 transformation for a subset of the problems to a known NP-Complete Problem

– Deciding consistency for some spatial-temporal networks

– Deciding the Boolean satisfiability problem (3-SAT)

Page 36: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Transforming ProblemTransforming Problem

• Boolean satisfiability problem has

– Variables– Literals – Constraints

• Transform each component to spatial networks

• Boolean satisfiability problem has

– Variables– Literals – Constraints

• Transform each component to spatial networks

Page 37: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Transforming ProblemTransforming Problem

– Show deciding consistency is same as deciding consistency for SAT problem, and vice versa

– Program written to do this automatically (Renz & Li, KR’2008)

– Show deciding consistency is same as deciding consistency for SAT problem, and vice versa

– Program written to do this automatically (Renz & Li, KR’2008)

Page 38: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

SummarySummary

• Qualitative Spatial-Temporal Reasoning uses constraint networks of infinite domains

• It reasons with relations between entities, and make only as few distinctions as necessary

• It is useful for imprecise / uncertain information• Many open questions / problems in the field.

• Qualitative Spatial-Temporal Reasoning uses constraint networks of infinite domains

• It reasons with relations between entities, and make only as few distinctions as necessary

• It is useful for imprecise / uncertain information• Many open questions / problems in the field.

Page 39: Qualitative Spatial- Temporal Reasoning Jason J. Li Advanced Topics in A.I. The Australian National University Jason J. Li Advanced Topics in A.I. The

Further ReadingFurther Reading

• A. G. Cohn and J. Renz, Qualitative Spatial Representation and Reasoning, in: F. van Hermelen, V. Lifschitz, B. Porter, eds., Handbook of Knowledge Representation, Elsevier, 551-596, 2008.

• J. J. Li, T. Kowalski, J. Renz, and S. Li, Combining Binary Constraint Networks in Qualitative Reasoning, Proceedings of the 18th European Conference on Artificial Intelligence (ECAI'08), Patras, Greece, July 2008, 515-519.

• G. Ligozat, J. Renz, What is a Qualitative Calculus? A General Framework, 8th Pacific Rim International Conference on Artificial Intelligence (PRICAI'04), Auckland, New Zealand, August 2004, 53-64

• J. Renz, Qualitative Spatial Reasoning with Topological Information, LNCS 2293, Springer-Verlag, Berlin, 2002.

• The above can all be accessed at http://www.jochenrenz.info

• A. G. Cohn and J. Renz, Qualitative Spatial Representation and Reasoning, in: F. van Hermelen, V. Lifschitz, B. Porter, eds., Handbook of Knowledge Representation, Elsevier, 551-596, 2008.

• J. J. Li, T. Kowalski, J. Renz, and S. Li, Combining Binary Constraint Networks in Qualitative Reasoning, Proceedings of the 18th European Conference on Artificial Intelligence (ECAI'08), Patras, Greece, July 2008, 515-519.

• G. Ligozat, J. Renz, What is a Qualitative Calculus? A General Framework, 8th Pacific Rim International Conference on Artificial Intelligence (PRICAI'04), Auckland, New Zealand, August 2004, 53-64

• J. Renz, Qualitative Spatial Reasoning with Topological Information, LNCS 2293, Springer-Verlag, Berlin, 2002.

• The above can all be accessed at http://www.jochenrenz.info