CS2650 Exercises

CS2650 Exercise 1 (In the interest of time)

(a) Given two events A and B, there are thirteen possible temporal relations between them. The 13 temporal relations, as first described by James Allen, are:
  AAA  BBB

  BBB  AAA

  AAABBB

  BBBAAA

  AAAA
  BBB

  AAA
  BBBB

  AAAA
   BBB

   AAA
  BBBB

  AAAA
    BBBB

    AAAA
  BBBB

  AAAAA
   BBB

  BBBBB
   AAA

  AAAA
  BBBB
Use Petri net to model each temporal relations. (Hint: The events A and B, are modelled by transition tA and tB, respectively. Other transitions tD can be introduced to represent a time delay D.)

(b) A Slow Intelligence System (SIS) has the following phases: ENumeration, PRopagation, ELimination, ADaptation and COncentration. For the slow decision cycle, all five phases are included. For the fast decision cycle, only two phases are included: ENumeration and ELimination. For the slow decision cycle, the time allocated for each phase is TEN, TPR, TEL, TAD and TCO, respectively. For the fast decision cycle, the time allocated for each phase is tEN and tEL, respectively.
Use Petri net to model an SIS with a slow decision cycle and a fast decision cycle. Draw the time lines for a slow decision cycle followed by a fast decision cycle.

CS2650 Exercise 2 (Specify a Slow Intelligence System)

(a) Describe the personal health care (or your own favorite) SIS application with a slow decision cycle and one (or more) fast decision cycle, where the decision cycles can include some of the SIS phases in some preferred order. Use active index, which is an extended Petri net model, to model such an SIS application. Draw the time lines for the SIS application. (Hint: There may be several decision cycles and they may be running concurrently.)

(b) Use the Slow Intelligence System Management Console to specify the SIS described in part (a). The end results should be a collection of XML documents. To avoid name collision, the components should be prefixed by the designer's last name. For example, a component designed by "Doe" for blood sugar monitoring should be named "DoeBPmonitor".

CS2650 Exercise 3 (Test a Slow Intelligence System)

Use the Slow Intelligence Systems Testbed to test run the SIS specified in Exercise 2(b). The predesigned Universal Interface and SIS Server can be downloaded from the SISv2a.zip file. Once downloaded, just following the following Complete Setup Procedure to install them. The messages (XML documents) created in Exercise 2(b) can be loaded to the Universal Interface and sent to the SIS Server. You should follow a pre-described scenario to test run the SIS messages.

CS2650 Exercise 4 (Design a Slow Intelligence System)

This exercise is to use the experiences gained in the previous exercises to design a slow intelligence system consisting of some of the following components: Enumerator, Propagator, Eliminator, Adaptor, Concentrator, and Time Controller. The test bed has the KnowledgeBase component and Eliminator component for blood sugar monitoring. Only the Enumerator component, the parametrized blood sugar monitoring components and the Time Controller are to be implemented. The Enumerator is the first component to be activated, and it should in turn create a large number (such as 10) of blood sugar monitoring components, which can be variations of a generic, parametrized blood sugar monitoring component. When the Enumerator sends a message to create a blood sugar monitoring component, it sends a parameter to customize this component. For example, it may send the threshold for determining whether the blood sugar level is normal. The Eliminator component is provided by the testbed, which will select only those blood sugar monitoring components that perform well. The Time Controller component decides when to invoke the Eliminator. For this exercise the Propagator, Adaptor and Concentrator are not used. They will be useful for the data mining project to be defined for students as a possible term project. Your job is to implement the Enumerator, the parametrized blood sugar monitor and the Time Controller, and to test a feasible scenario with these components. Note: To initialize the knowledge base, send Msg201 to the KB component. For other message exchanges see the following SIS system diagram.

CS2650 Exercise 5 (Planning a Picnic)

(a) Use the IC cards to specify the activities involved in planning a picnic. You can specify the color of an activity using words such as red, yellow, green, etc. (b) How do you handle timing constraints? (c) Do you have any purple activities? If so, how do you decompose or transform them into activities that are not purple? (d) Specify the TAOs and the hypergraph structure.
(A tool you may use to construct the IC cards is the icms system: http://cs.pitt.edu/~chang/icms2".)

CS2650 Exercise 6 (Distance Learning System)

The purpose of this exercise is to gain familiarity of the active index approach for active information system modeling. As discussed in class, the hypermedia model and the active index together can be used to model active distributed multimedia information systems. In this exercise we will first concentrate on the active index component.

Let us consider a (simplified) distance learning system. The distance learning materials are organized into a hypermedia structure. A student user can browse through these multimedia documents and follow the links to access related multimedia documents. As such, the hypermedia structure is passive, waiting to be accessed by the user.

We can make the hypermedia structure active by associating index cells with selected multimedia documents. The following index cell types are specified:

Prefetch: The prefetch index cell would prefetch related multimedia documents into the local store so that when the user accesses them they are readily available. The way prefetch works is that it will send messages to the watchers to find out what documents (pages) the user has already accessed. From this information, prefetch estimates what documents will be accessed next, and starts to load them into the local store.

Watcher: The watcher monitors individual documents or collection of documents to record in its local memory which user has accessed this (collection of) documents. It interacts with the prefetch index cell so that prefetch can determine what to prefetch into the local store.

The above are two index cell types. The instances can be associated with individual multimedia documents (such as WWW pages).

(a) Draw state-transition diagrams to define graphically the two index cell types.

(b) Specify the two index cell types formally using mathematical notations ic = (X, Y, S, so, A, tmax, f, g).

(c) Draw a diagram showing a few multimedia documents enhanced with the index cells to illustrate how these index cells work together to form an active index system.

(d) Use the IC Builder to construct the two index cell types as prefetch.gra and watcher.gra. The output from IC Builder, together with the appropriate actions (C functions) and specification of input message space, output message space, will become input to the IC Compiler to generate the IC Manager.

Comments: (a) If we consider how the active index system passes messages and reaches equilibrium state (if one exists), this leads to a formal study using, for instance, the Petri net model. (b) Notice this is the beginning of a systematica approach to build prototypes for active distributed multimedia systems. Can we create a nwe systematic approach, i.e., a new software process model, for distributed multimedia systems design? (c) The index cells could span several nodes. Therefore, the active index system is a distributed index. The IC Managers must also be distributed to the nodes in the networks.

How to download the IC Builder: There are four files in the directory http://www.cs.pitt.edu/~jung/IC_Builder: README, IC Builder Manual, ictapp.zip and ictype.zip. Use pkunzip to unzip and install under Windows.

Additional Explanation for Exercise 6: For this exercise there is NO NEED to write any C functions. The assignment can be handed in either as a hard copy or via the Internet. For the part where you use IC_Builder to construct IC types, you can turn in the output file(s) generated by the IC_Builder, which are ascii files X.in. You can also provide screen dumps captured during the construction process. If you use Internet, it will be the best if you can give me URL so that I can browse the web pages containing the solutions. In other words, please prepare a set of web pages and figures can be embedded as gif/jpg files. This will be the easiest for other people to read. It will also be useful when you later develop a presentation based upon such materials.

Additional Exercise Add MAWC tags to this document to make it a model-enhanced document in HTML or XML format. Continue to work on an MAWC algorithm for customized presentation of information from a collection of documents, or a sensor network, or a hybrid of documents and sensor network.

CS2650 Exercise 7 (The car accident)

The multimedia database consists of a relational database and a video database, which in turn consists of a time sequence of frames. If we open a frame we can see (i.e. recognize) the objects in that frame, such as cars, buildings, roads, etc. The relational database has a single table whose entries have detailed description of each car instance, such as (type="car", make="BMW", color="red", license-no=123, owner="Smith", state="Pennsylvania"), and so on.

(a) Construct a data model for this multimedia database.

Construct SigmaQL queries for the following:

(b) Get the two cars that collided with each other. (This query may be ambiguoous, so please explain what you want to retrieve, i.e., your interpretation of the query.)

(c) Get the sequence of frames that show this accident, for example, the 120 frames (4 seconds) before the collision, the frames containing the collision, and the 90 frames (3 seconds) after the collision.

(d) Get the licence numbers of the cars involved in the accident, whose color is white and whose registration is out-of-state (i.e., not Pennsylvania). Please note there could be multiple answers to this query.

CS2650 Exercise 8 (The inferno)

(a) Continuing the scenario described in Exercise 7, suppose the collision leads to a fire that can be easily detected from a video frame by applying a pattern recognition algorithm, please reformulate the query in explain how you can efficiently process the query using query refinement techniques.

(b) Using the visual language approach to design the syntax and semantics of a visual interface to answer user's queries involving car accidents from the multimedia database described in Exercise 7.