Towards Spike-Based Speech Processing: A Biologically Plausible Approach to Simple Acoustic Classification Shortcomings of automatic speech recognition (ASR) applications are becoming more evident as they are more widely used in real life. The inherent non-stationarity associated with the timing of speech signals as well as the dynamical changes in the environment make the ensuing analysis and recognition extremely difficult. Researchers often turn to biology seeking clues to make better engineered systems, and ASR is no exception with the usage of feature sets such as Mel frequency cepstral coefficients, which employ filter banks similar to cochlear filter banks in frequency distribution and bandwidth. In this paper, we delve deeper into the mechanics of the human auditory system to take this biological inspiration to the next level. The main goal of this research is to investigate the computation potential of spike trains produced at the early stages of the auditory system for a simple acoustic classification task. First, various spike coding schemes from temporal to rate coding are explored, together with various spike-based encoders with various simplicity levels such as rank order coding and liquid state machine. Based on these findings, a biologically plausible system architecture is proposed for the recognition of phonetically simple acoustic signals which makes exclusive use of spikes for computation. The performance tests show superior performance on a noisy vowel data set when compared with a conventional ASR system. The research discussed in this paper has two mutually inclusive goals. While exploring the spike coding mechanisms employed by the auditory system at different sound pressure levels (SPLs) and signal-to-noise ratios (SNRs), we aim to introduce a novel way of information processing for speech signals trying to imitate the auditory neural computation. The biggest motivation behind this research is the fact that human engineered automatic speech recognition (ASR) systems perform poorly as the variability associated with the speech signal increases, especially in noisy environments. On the other hand, the human brain is capable of processing the ever-continuous stream of input with an unparalleled accuracy. Even though much is still unknown about how brain exactly works, it is well known that neurons in the brain use action potentials to communicate the timing information from the sensory to more complex levels of processing in the cortex. We strongly believe that computation with spike trains is not a mere artifact of biology, but instead it holds the key to the robustness and performance of the auditory system. The idea of using bio-inspired techniques for machine recognition tasks is certainly not a new concept. In ASR, the most commonly used feature set, Mel frequency cepstral coefficients (MFCC), imitates the distribution of cochlear filter banks by employing logarithmically distributed filters along the frequency axis (Davis and Mermelstein, 1980) . More elaborated approaches include human factor cepstral coefficients, which use known facts from human psychoacoustics such as the relationship between center frequency and critical bandwidth to decouple filter bandwidth from filter spacing (Skowronski and Harris, 2004) . The performance and robustness of those techniques compared with previous commonly used feature extractors, such as linear predictive coding, clearly shows the advantage of using inspiration from biology and psychoacoustics in particular (Atal and Hanauer, 1971 ).. The objective of this research is to take this inspiration one step further to include the neural computation used in the human auditory system for both the feature extraction and recognition stages of a simple acoustic classification problem. In order to accomplish this goal, we have followed a systematic approach where dif- Fig. 1 . Speech-to-spike conversion block which shows the transduction of sound waves into trains of action potentials at nerve fibers connected to inner hair cells.. ferent spike-based operators are evaluated along with different spike coding techniques for different types and intensities of noise and input acoustic stimuli (Uysal et al., 2006; Uysal et al., 2007a; Uysal et al., 2007b) . Section 2 briefly discusses the mechanism which converts incoming acoustic signals to action potentials on nerve fibers. Various coding schemes applied on these spike trains are discussed in Section 3. Sections 4 and 5 deal with spike-based operators and how they are used in conjunction with spike coding schemes. The acoustic classification problem and test results are provided in Section 6.

O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O


Algebraic Structures of B-series Abstract B-series are a fundamental tool in practical and theoretical aspects of numerical integrators for ordinary differential equations. A composition law for B-series permits an elegant derivation of order conditions, and a substitution law gives much insight into modified differential equations of backward error analysis. These two laws give rise to algebraic structures (groups and Hopf algebras of trees) that have recently received much attention also in the non-numerical literature. This article emphasizes these algebraic structures and presents interesting relationships among them. Let us consider systems of differential equationṡ y = f (y) (1) with smooth vector field f (y). Since the work of Cayley [10] and Merson [36] it is known that the expressions arising in the derivatives of its solution,ÿ = (f f )(y), ... y = (f (f, f ))(y) + (f f f )(y), are in one-to-one correspondence with rooted trees. It is therefore natural to consider formal series of the form

O O O B O B O O O O O O O O O O O O O O O O O B I O B O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O


On the value of learning from defect dense components for software defect prediction ABSTRACT BACKGROUND: Defect predictors learned from static code measures can isolate code modules with a higher than usual probability of defects. AIMS: To improve those learners by focusing on the defect-rich portions of the training sets. METHOD: Defect data CM1, KC1, MC1, PC1, PC3 was separated into components. A subset of the projects (selected at random) were set aside for testing. Training sets were generated for a NaiveBayes classifier in two ways. In sample the dense treatment, the components with higher than the median number of defective modules were used for training. In the standard treatment, modules from any component were used for training. Both samples were run against the test set and evaluated using recall, probability of false alarm, and precision. In addition, under sampling and over sampling was performed on the defect data. Each method was repeated in a 10-by-10 cross-validation experiment. RESULTS: Prediction models learned from defect dense components out-performed standard method, under sampling, as well as over sampling. In statistical rankings based on recall, probability of false alarm, and precision, models learned from dense components won 4-5 times more often than any other method, and also lost the least amount of times. CONCLUSIONS: Given training data where most of the defects exist in small numbers of components, better defect predictors can be trained from the defect dense components. It is widely believed that some internal properties of software (e.g., metrics) have relationship with the external properties (e.g., defects). Many prediction models have been proposed based on software metrics. For example, Menzies et al. [20] performed defect predictions for five NASA projects using static code metrics. In their work, probability of detection (recall) and probability of false alarm (pf) are used to measure the accuracy of a defect prediction model. Their models generate the average results of recall = 71% and pf = 25%, using a Naive Bayes classifier.. Zhang and Zhang [40] pointed out that the Menzies et al. results are not satisfactory when precision is considered. They found that high recall and low pf do not necessarily lead to high precision. In reply, Menzies et al. [19] noted that for the defect data in the PROMISE repository, the percentage of modules with defects is low. They showed that, for such data, it is difficult to achieve both high precision and high recall (that mathematical argument is reproduced in §3.1).. This paper disputes the conclusions of Menzies et al. We achieve better defect predictors with an approach that originated in the following observation:. With software projects, most of the defects occur in a minority of components.. In the general research community, this is not a new observation. It has been repeatedly demonstrated that most defects occur in a small number of components (e.g. see [9] ). However, within the PROMISE community, this is a new finding. To the best of our knowledge, this effect has not been reported previously, even though the PROMISE defect data sets have been the subject of intense scrutiny (perhaps this community has been so focused on the learner that they miss important aspects of the data).. What is new in this paper is the recognition that we can exploit this distribution to build better defect predictors. We test the speculation that if we focus more on the densely defective components, we might generate better defect predictors.. The rest of this paper explores this possibility. In the following, we say that a software project is divided into components and components have modules. In this terminology:. • The module is the smallest unit of compilation; e.g. a function in "C", or a method in "JAVA"; • A component is a large groupings of many modules.. Typically, one project contains dozens to hundreds of components, and each component contains dozens to hundreds of modules.. Using this terminology, we can summarize our findings as follows: training on densely defective components produces better defect predictors than otherwise. A previously unexplored feature of the PROMISE defect data sets are the small number of components containing most of the defects. This skewed defect distribution has implications on our data analysis of the PROMISE defect datasets. We have been reporting neg/pos ratios for those data sets as varying from 1 to 249 (see §3.1). This statistic is clearly incorrect since it is a mean value across a highly skewed distribution:. • An entire project like CM1 may have a high overall neg/pos ratio.. • This mean ratio does not characterize the neg/pos ratio of individual components.. Mathematically, this skewed distribution is an interesting region of the data since such components have lower neg/pos ratios which, according to the maths of §3.1, means that they could (in theory) yield detectors with high precision and recall.. To test this possibility, we restricted training to just the components with higher than the median number of defective modules. This was compared to training using all the data (which, according data performance all dense over under set measure components components sampling sampling CM1 precision 0 0 0 0 recall + ---pf -+ --KC1 precision 0 0 0 0 recall 0 0 0 0 pf 0 0 0 0 MC1 precision 0 0 0 0 recall --0 0 pf --0 0 PC1 precision -+ --recall -+ --pf -+ --PC3 precision 0 0 0 0 recall --0 0 Table 3 : Each treatment is assigned one of {+, 0, −} depending on if it won, tied, lost in the statistical rankings of Table 1 (based on a Mann-Whitney test at 95% confidence). Note that dense won most often, and lost the least amount of times compared to all other treatments (4/15 vs. 8/15 and 6/15).. to our understanding of the literature, is the more usual treatment). We found that training via dense sampling is useful for generating better defect prediction models. The improvements are not startlingly better -the recall and precision mean values are close to standard practice (see Table 2 ). Nevertheless, in the majority cases, training on dense components yielded statistically significantly better detectors than other methods (training on all data, over-sampling, and under-sampling). Given the simplicity of the technique (just select training data from a subset of the components), we recommended the proposed method whenever it becomes apparent that components have different defect densities. Although for the very first project, we do not know the proportions of defect dense components, the future projects can benefit from defect prediction models learned from the dense components in the first project.. This result has negative and positive implications. On the positive side, we have shown here that the skewed defect distributions within a project can be exploited to generate better defect predictors. On the negative side, it means that there are aspects of the PROMISE data sets that have not been noticed in dozens of prior publications. The PROMISE repository data is used widely in the literature, usually in papers of the form "here is a new learner applied to data sets X,Y,Z from PROMISE". Such papers may be so focused on the learner that they miss important aspects of the data. In the future, we would recommend visualizations of data before applying data miners, lest we miss other important aspects of our data. Before we present our specific results, this section reviews the general area of defect prediction.. One method for assessing software is to extrapolate the curve of post-release failures. In this reliability engineering approach, analysts use knowledge of how the frequency of failures seen in a running system changes over time [26, 15] . Given a history of defects in a running system, reliability engineers extrapolate a reliability growth curve that predicts the future probability of failure on demand of a developing system. Such curves can predict how long before a system reaches a required level of reliability.. Reliability engineering assumes that the system is running; i.e. not until the entire system is assembled. It is undesirable to delay software rework until after the system is running since the longer a defect remains in code, the more expensive it is to remove [4] .. Prior to building a fully functioning system, software engineers build modules then, usually, apply some quality assurance (QA) technique to assess the quality of those modules (those techniques include inspections, unit tests, static source code analyzers, etc). A record of the results of those QA techniques is a defect log. Note that this log can accumulate from very early in the development cycle (i.e. even before the entire system is running).. Defect predictors can be learned from these historical logs, if the logs contain tables of data. In those tables:. • Rows describe data from one module; a.k.a. "functions" or "methods" or "procedures".. • Columns describe static code features such as lines of code measures, the McCabe measures, and the Halstead measures. The class label "defective" is also a column, whose values are either true or false For these data sets, the data mining goal is to learn a binary predictor for def ective modules from past projects that can be applied to future projects.

O O O O O O B I I O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O B O O O O O O O O O O O O O O O O O O O O B I I O O O O B O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O


The emotional responses of browsing Facebook: Happiness, envy, and the role of tie strength On Facebook, users are exposed to posts from both strong and weak ties. Even though several studies have examined the emotional consequences of using Facebook, less attention has been paid to the role of tie strength. This paper aims to explore the emotional outcomes of reading a post on Facebook and examine the role of tie strength in predicting happiness and envy. Two studies -one correlational, based on a sample of 207 American participants and the other experimental, based on a sample of 194 German participants -were conducted in 2014. In Study 2, envy was further distinguished into benign and malicious envy. Based on a multi-method approach, the results showed that positive emotions are more prevalent than negative emotions while browsing Facebook. Moreover, tie strength is positively associated with the feeling of happiness and benign envy, whereas malicious envy is independent of tie strength after reading a (positive) post on Facebook.

O O O O O B B B O O O O B I O B O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O B I O O O O O O O O O O O O O B O O O O O B I O O B O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O B O O O O O O O O O O O O O O O O O O O B O B I O O O O O O O B O O B O O B O O O B I O O O O O O B


Eye movement prediction by Kalman filter with integrated linear horizontal oculomotor plant mechanical model The goal of this paper is to predict future horizontal eye movement trajectories within a specified time interval. To achieve this goal a linear horizontal oculomotor plant mechanical model is developed. The model consists of the eye globe and two extraocular muscles: lateral and medial recti. The model accounts for such anatomical properties of the eye as muscle location, elasticity, viscosity, eyeglobe rotational inertia, muscle active state tension, length tension and force velocity relationships. The mathematical equations describing the oculomotor plant mechanical model are transformed into a Kalman filter form. Such transformation provides continuous eye movement prediction with a high degree of accuracy. The model was tested with 21 subjects and three multimedia files. Practical application of this model lies with direct eye gaze input and interactive displays systems as a method to compensate for detection, transmission and processing delays. Direct eye-gaze input [Jacob 1995; Murtagh et al 2002; Komogortsev 2007a] and interactive display systems are prone to delays. The delays are comprised of detection, processing and transmission times. Depending on the specific case the delays can reduce a system's performance and introduce interaction errors. Eye movement prediction is one of the ways to compensate for the delay effects.. We explored the idea of the eye movement prediction in our previous work [Komogortsev 2007a ], a live system was created [Komogortsev 2007b ] using this concept for delay compensation.. In that system the vertical and horizontal eye movement component was predicted by a Two State Kalman Filter (TSKF), two states being eye position and velocity. This paper improves the accuracy of the eye movement prediction in the horizontal plane by building a linear Oculomotor Plant Mechanical Model (OPMM).. Oculomotor plant is defined here as an eye globe plus extraocular muscles. The model is adopted from Bahil's work [Bahill 1980 ]. There are two major contributions added to the model a) the ability to start a saccade from any eye location b) the ability to make saccade in any direction in the horizontal plane. The mathematical equations describing the OPMM are transformed into a Kalman filter form that continuously predicts the eye movement signal. Kalman filter is selected because of its ability to minimize the error between the measured and the estimated eye position [Brown and Hwang 1997] and detect the onset of saccades [Sauter 1991] . We call the resulting model Oculomotor Plant Kalman Filter (OPKF). The OPKF has six states that consist of: angular eye position, velocity, muscles' locations, and muscles' forces.. Our simulation results that consisted of 21 subjects and three test multimedia files show a 18-28% of increase in accuracy of prediction during saccades and 7-13% increase overall when OPKF model is used instead of the TSKF model. Eye tracking technology can successfully enhance already existing interaction methods. There are several issues that are needed to be resolved before this can happen. One of these issues is related to the fact that eye tracking equipment and interactive environments in general possess various types of delays.

B I I O B I O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O B I O O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I O O O O O O O O O O O O O O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O B I I O O O O O O O O B I O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O


Computer vision techniques for PDA accessibility of in-house video surveillance In this paper we propose an approach to indoor environment surveillance and, in particular, to people behaviour control in home automation context. The reference application is a silent and automatic control of the behaviour of people living alone in the house and specially conceived for people with limited autonomy (e.g., elders or disabled people). The aim is to detect dangerous events (such as a person falling down) and to react to these events by establishing a remote connection with low-performance clients, such as PDA (Personal Digital Assistant). To this aim, we propose an integrated server architecture, typically connected in intranet with network cameras, able to segment and track objects of interest; in the case of objects classified as people, the system must also evaluate the people posture and infer possible dangerous situations. Finally, the system is equipped with a specifically designed transcoding server to adapt the video content to PDA requirements (display area and bandwidth) and to the user's requests. The main issues of the proposal are a reliable real-time object detector and tracking module, a simple but effective posture classifier improved by a supervised learning phase, and an high performance transcoding inspired on MPEG-4 object-level standard, tailored to PDA. Results on different video sequences and performance analysis are discussed. Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. To copy otherwise, to republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Nowadays, video surveillance is a mature discipline aiming to define techniques and systems for processing (possibly in realtime) videos from cameras placed in a specific environment; the main goal is to extract knowledge about the environment and the actors living there, to detect objects and events of interest, and, consequently, to react by storing multimedia data, generating alarms or providing a remote access to live videos. The appeal of research activity in video-surveillance is the interesting multi-disciplinarity involved. Video surveillance needs computer vision and pattern recognition techniques for real-time video analysis, computer architecture and system integration for smart video servers, models of knowledge extraction and knowledge representation for the scene comprehension and techniques to handle communication standards used to connect networks of cameras, servers and remote clients. Moreover, in addition to the well known difficulties of computer vision tasks applied to real world non-idealities, that call for sophisticated methodologies and innovative video processing techniques, many HW/SW engineering problems arise in video-surveillance systems: in particular, problems are associated with the real-time constraint of the applications, juxtaposed to the frequent need of using off-the-shelf computing technologies only. In this case, the concept of real-time is adapted according to the need of system reactivity to detected events, the storage requirements of video servers and the QoS requests from remote users, if they exist. Thus, the video-surveillance system should find a good tradeoff between the need of processing the higher number possible of available video frames (for an accurate motion detection, a correct identification, a good video quality, ...) and, at the same time, to limit the amount of data (pixels, objects, a priori knowledge models, ...) that have to be handled.. In this work, we stress on these issues, in order to provide fast answers to events and model reactivity and, simultaneously, to cope with the limited computational power of standard network cameras and workstation servers. Moreover, we focus on the needs of remote users with very limited display and computational resources, such as the growing diffused Personal Digital Assistants (PDAs). Our proposal is specially devoted to indoor environment surveillance and to people behaviour control in home automation (or, better, domotics 1 ) context. The reference application is a silent and automatic control of the behaviour of people living alone in the house and specially conceived for people with limited autonomy (e.g., elders or disabled people). The possibility to improve their autonomy and their quality of life can be supported by fully automatic computer vision systems that could be able to see and interpret what is happening, possibly interacting with the person or providing a remote connection if some dangerous events occur. Examples of dangerous situations could be people falling down and lying on the floor, people going asleep in strange locations of the home, and so on. To this aim, we have defined models and techniques for people detection and posture interpretation.. In dangerous circumstances, a remote connection should be established with someone interested to the home guest's care. In the case of hospitals or specific health care structure, the typical connection to a control center could be guaranteed without problems of bandwidth or limited resources. Instead, in private home situation, the scenario can be that of relatives, or friends that are connected with portable devices (e.g., PDAs or smart phones) in highperformance wireless technology such as IEEE 802.11a WiFi, if they stay in other parts of the home, or by more limited phone technologies (such as GPRS), if they are out of the home, in the office or everywhere around the world.. In this paper we propose the integration of several modules to build up a complete prototype: some modules have been directly inspired to the current literature, others have been originally defined to process videos, interpret people behavior and communicate events remotely to low-power devices, such as PDAs. The novelties and the meaningful points of the work, as well the system architecture itself, can be summarized as follows:. • A fast and robust module for moving objects and people detection and tracking, working on videos from fixed cameras and based on color background modeling and background suppression, and capable of dealing with background changes and shadows. We called this approach Sakbot [3, 4] .. • A new approach to people posture classification that exploits a supervised learning paradigm to create probability masks.. • A smart video server, implementing new semantic transcoding techniques to connect directly with PDA clients. The transcoding model, using the philosophy of MPEG-4 objectbased compression, allows video streaming of part of the videos that are semantically valuable to the user: it compresses differently objects and event and operates also a temporal and size downscaling. As above mentioned, our paper reports the description of a prototype system that has three main characteristics:. 1. it allows video accessibility to low-resource devices, such as PDAs. This is obtained by applying effective transcoding policies able to keep the ratio quality/bandwidth as high as possible. Moreover, transcoding process adapts the video to the device's capabilities;. 2. it provides best quality for the defined scopes of the user.. As reference application, we used the in-house video surveillance for elders and disabled people's health care. This goal of the system requires to detect events and situations of particular relevance;. 3. it exploits computer vision techniques to extract semantics from the video. This is achieved using a fast and robust moving object detection and a supervised learning based posture classifier. In this work, we do not consider neither multiple-camera surveillance systems, nor moving or PTZ cameras. Focusing on static cameras, most of the works of video-surveillance are based on background modeling and background suppression. They generally differs in the model adopted to generate and update the background and in the way the moving pixels are connected in moving blobs. Most of non-trivial background models use statistical function over the history set of frames: Mode [18] , Median [10] , Mixture of Gaussians [23, 20] , PCA reduction [15] , and so on, have been proposed. Moreover, the background model is often selectively updated according with the knowledge extracted from previous frames: for instance, pixels or objects that have been detected in motion in previous frames are not used to update the background [7, 2] .. In indoor applications, moving objects are mostly people, furniture and other objects that can be easily discriminated from persons with very simple geometrical considerations. Instead, due to the non-rigid human motion, the presence of occluding surfaces and possibly of more actors intersecting each other, video surveillance systems have deeply considered the problem of tracking. Traditionally, Kalman-based tracking systems [11] are adopted to predict the position of the moving objects in successive frames. They assume a rigid-motion model and possibly with a predictable direction. It can be applied with success also in indoor people's scenes whenever the scene is very simple, possibly with a single moving person, with few additional assumptions. Moreover, new approaches based on probabilistic tracking allow to cope with more complex situations [21] . In our system, we adopted an approach of appearance and probabilistic tracking that is inspired to the work of Senior [17] . They proposed a method that computes the probabilistic mask and the color appearance model of tracks in a very simple, and consequently quick, way.. Another enormous amount of literature works are related to the topic of human motion capture (HMC), including body modeling and posture detection. In its survey, Moeslund [13] classifies HMC approach in three categories: model-free, active and passive model based. Model-based approaches exploit a specific knowledge about the human body parts and their relationships, and often work in 3D space [12] , or exploit very complex graph description (see, for instance, the decomposable triangulated graphs of [19] ). Instead, model-free methods adopt a general pattern recognition paradigm: appearance features are extracted in 2D images and a classifier in the feature space is constructed. In this case, the efficiency of the method is affected by the significance of the selected features and the power of the classifier. In [8] , the used feature is called Star Skeletonization and is a distance of the extremities of the silhouette from the blob's center of gravity. In [9] the vertical and horizontal projections of the blob are used to recognize people posture. For the classification of four posture classes (lying, crawling, sitting, standing), a simple nearest neighbor classifier, that compares the current projections with four manually tuned models, is adopted. Then, the system in [9] is refined with a body modeling in order to recognize salient parts of the body. The same horizontal projections have been used also in [6] to recognize parts of the body. Three projections are used: the first for head, the second for the torso and the third for the legs. We use a similar approach of [9, 6] , with some suitable modifications by means of camera calibration, and a phase of supervised learning in order to construct probability masks to recognize the posture. Then, the posture is used in a Finite State Machine to recognize a dangerous situation.. Another key aspect of this work is the implementation of a remote connection with low-cost devices by means of semantic transcoding. Semantic transcoding is often employed in streaming servers to adapt the multimedia content and, specifically, reformat video code, in order to cope with user needs and user constraints [14] . Typically, variable compression, size, and color downscaling are useful to save bandwidth and to deal with limited display resource of devices such as PDAs. The exploitation of semantics at this level means to use the knowledge of the video content to compress the video differently in the space and in the time. The MPEG-4 standard was the first structured proposal to handle differently background and foreground objects in the scene, to compress them and to send to the user for a specific encoding. At the same time, MPEG-4 Core Profile (needed for object functionalities) codec is computationally heavy and a real time decode and encode phase can now be achieved with hardware accelerator only. Thus, we proposed some simplified version that can be exploited also with software codec only [5] , and in this paper we describe a solution specially conceived for PDA clients. The valuable contribute of this proposal is to define a semantic transcoding server operating on-the-fly in cascade with the computer vision system. This is quite a different approach to VBR (Variable Bit Rate) implemented in MPEG-1 and MPEG-2 standards, because the semantics used to modify the bit rate is at an higher level and selected di- rectly by the user. In such a manner the knowledge of segmented people and objects guides the adaptive compression. In [22] , a similar approach for traffic surveillance is proposed, where objects are segmented and compressed differently in MPEG-4 standard for an offline annotated video server. Further, in [1] not only an object transcoding is discussed, but also the semantics is exploited at level of both objects and events. This unified framework is here presented in a domotic context and tailored for PDA.

O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O B O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O B


Design and design methods for unified multiplier and inverter and its application for HECC This paper describes two novel architectures for a unified multiplier and inverter (UMI) in GF(2 m ): the UMI merges multiplier and inverter into one unified data-path. As such, the area of the data-path is reduced. We present two options for hyperelliptic curve cryptography (HECC) using UMIs: an FPGAbased high-performance implementation (Type-I) and an ASIC-based lightweight implementation (Type-II). The use of a UMI combined with affine coordinates brings a smaller data-path, smaller memory and faster scalar multiplication.Both implementations use curves defined by h(x) ¼x and f ðxÞ ¼The high throughput version uses 2316 slices and 2016 bits of block RAM on a Xilinx Virtex-II FPGA, and finishes one scalar multiplication in 311 ms. The lightweight version uses only 14.5 kGates, and one scalar multiplication takes 450 ms. Hyperelliptic curve cryptography (HECC) [22] is an important candidate for public-key cryptography [13] . Like elliptic curve cryptography (ECC) [27, 21] , it uses smaller parameter sizes than RSA [29] for equivalent security level. In constrained devices, HECC enables valuable optimizations in area and speed.. Implementing HECC on a resource-constrained platform is a challenge for both area and performance. Table 1 describes the computational complexity of divisor operations in different coordinate systems [5] . Here I, M and S denote modular inversion, multiplication and squaring, respectively. Over the past few years, HECC have been implemented in both software [28, 30, 3, 4, 6] and hardware [8, 11, 17, 14] . Table 2 summarizes previous FPGA-based HECC implementations.. In 2001, Wollinger described the first hardware architecture for HECC implementations [36] . However, the architecture was only outlined. The first complete hardware implementation of HECC was presented in [8] . This work was improved by Clancy [11] . All of them use Cantor's algorithm [10] for divisor addition and doubling.. In 2002, Lange generalized the explicit formulae for HECC over finite fields with arbitrary characteristic [23] . The first hardware implementation of HECC using explicit formulae was described in [15] . In [14] an improved version is proposed. The first hardware implementation using the affine version of explicit formulae was described in [35] , which presents the fastest FPGA-based HECC coprocessor up to date.. Also some ASIC implementations of HECC using projective coordinates were proposed. For example, Sakiyama proposed an HECC coprocessor [31] using 130 nm CMOS technology. The coprocessor is able to run at 500 MHz, and it can perform one scalar multiplication of HECC over GFð2 83 Þ in 63 ms.. Previous HECC implementations often use multiple multipliers or inverters to speed up the scalar multiplication. Commonly, an architecture shown in Fig. 1 is used. The use of multiple multipliers in parallel demands a high-throughput memory and a complex data bus, which result in further area increase. In this paper, we explore the power of a unified multiplier and inverter (UMI) for area reduction and performance improvement. We consider the architecture shown in Fig. 2 more area-efficient. We show that the use of a UMI brings three main advantages. First of all, the fast inverter makes affine coordinates very efficient, thus the performance is improved. Secondly, it reduces the area of the data-path. Thirdly, using only one data-path simplifies the data-bus and reduces the size of memory.. Our contributions: The contributions of this paper are threefold. Firstly, we propose two novel architectures for a unified multiplier and inverter. We show that merging an inverter into a multiplier results in a substantial area reduction. Secondly, we propose a digit-serial UMI architecture and describe a method to adjust the digit-size. We use this method to explore the best areatime trade-off for HECC. Thirdly, using the proposed UMIs, we implement two HECC processors: a high-throughput design that outperforms all previous FPGA-based HECC implementations and a lightweight design that is suitable for passive RFID tags.. The rest of the paper is organized as follows. Section 2 gives a brief introduction to the previous work, including mathematical background of HECC and the field arithmetic. Sections 4 and 5 describe the FPGA-based, high throughput architecture and the ASIC-based, lightweight architecture for HECC coprocessors, respectively. We conclude the paper in Section 6. We explore the efficiency of a unified multiplier and inverter datapath in HECC implementations. Two types of UMI are proposed. Type-I UMI, which realizes the LSB-first multiplication and right-shift EEA algorithms, achieves a short critical path delay. Using the Type-I UMI results in a high performance HECC processor on FPGA. The Type-II UMI, which realizes the MSB-first multiplication and the leftshift EEA algorithms, achieves a low footprint. Using the Type-II UMI results in a lightweight HECC processor for constrained devices. The use of UMI brings a substantial improvement in terms of area and performance of HECC implementations.. For applications like RFIDs, physical security is very important. Known HECC implementations are either based on a binary scalar multiplication method or NAF. They might be vulnerable to side-channel attacks. In ECC implementations, Montgomery ladder is widely used for protection against simple power analysis. A recent work by Gaudry and Lubicz [16] has shown that scalar multiplication of divisors can also use the Montgomery ladder. As a future work, we will combine our architecture with the algorithm proposed by Gaudry and Lubicz.

O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O


Computing isolated roots of sparse polynomial systems in affine space We present a symbolic probabilistic algorithm to compute the isolated roots in C n of sparse polynomial equation systems. As some already known numerical algorithms solving this task, our procedure is based on polyhedral deformations and homotopies, but it amounts to solving a smaller number of square systems of equations and in fewer variables. The output of the algorithm is a geometric resolution of a finite set of points including the isolated roots of the system. The complexity is polynomial in the size of the combinatorial structure of the system supports up to a pre-processing yielding the mixed cells in a subdivision of the family of these supports. The known algorithmic methods to solve general polynomial equation systems require a large number of calculations, which results in a long computing time. This is one of the reasons why several attempts to solve particular families of polynomial equation systems (for instance, polynomials with a specific fixed structure) have been made.. Bernstein [2] , Kushnirenko [18] and Khovanskii [17] proved that the number of isolated solutions in (C * ) n of a polynomial system with n equations is bounded by a combinatorial invariant (the mixed volume) associated with the sets of exponents of the monomials with nonzero coefficients in the polynomials involved (that is, their support sets). This result may be considered as the basis for the current study of sparse polynomial systems, namely polynomials with prescribed supports, and gave rise to the development of sparse elimination theory (see [9] for foundational results on this subject).. The most efficient algorithms to solve sparse polynomial systems in (C * ) n , both numerically and symbolically, use polyhedral deformations (see, for example, [29, 13, 25, 16] ). A deformation method to compute the isolated roots of a polynomial system consists in considering the given system as a particular instance of a parametric family of generic zerodimensional systems; the isolated roots of the input system are then obtained from the zeroes of a sufficiently generic instance which is easy to solve. These techniques, originally applied for numerical solving of equations (see, for instance, [20, 27] and the references therein), have also been used in symbolic procedures by means of the so-called Newton-Hensel lifting (see, for instance, [10, 12, 19, 15] ).. Polyhedral deformations preserve the monomial structure of the polynomial system under consideration, which implies that the number of ''paths'' to track along the deformation coincides with the expected number of solutions. For sparse systems, this results in a running time shorter than that of a general algorithm.. The first bounds for the number of isolated solutions in C n of a sparse polynomial system were given in [24] and improved later in [22, 26] . The most precise bounds known up until now are given in [14] in terms of stable mixed volumes, which are also combinatorial invariants depending only on the supports of the polynomials. The effective proofs of the bounds in these papers were applied to obtain numerical algorithms to compute the isolated solutions based on the approach in [13] (see, for instance, [22, 14] ). A symbolic algorithm performing this task provided all the polynomials have nonzero constant term is given in [16] .. The algorithm in [14] requires the use of recursive liftings, which may reflect negatively in the running time of the algorithm. An improved procedure which avoids recursive liftings was shown in [7] (see also [5] ). These algorithms rely on solving a number of associated subsystems in (C * ) n obtained from the liftings used.. In this paper, we present a new symbolic algorithm to compute the isolated solutions in C n of a sparse system with n equations. As the procedure in [7] , our algorithm avoids recursive liftings; moreover, it amounts to solving a smaller number of square systems of equations and in fewer variables. It can also be seen as a generalization to the algorithm in [16] in the sense that it does not require any hypothesis on the system supports. Our main result is the following (for a precise formulation, see Theorem 9):. Theorem. Let f 1 , . . . , f n be polynomials in Q[X 1 , . . . , X n ]. There exists a probabilistic algorithm (see Algorithm AffineSolve) which computes a finite set of points containing the isolated common zeroes of f 1 , . . . , f n in C n within a complexity which (up to a pre-processing) is polynomial in the size of the combinatorial structure of the system supports.. As in [16] , our algorithm takes as input the sparse representation of the polynomials f 1 , . . . , f n and the mixed cells in a fine mixed subdivision of their supports, which are assumed to be precomputed (see, for instance, [4, 28, 21, 6] and [23] for different algorithms computing these cells). The output of the algorithm is a geometric resolution, that is, a univariate representation of a finite set of points parametrized by the values a linear form takes at them (see, for example, [11] ).. The general idea of the algorithm is to recover the solutions of the input system from the solutions of a generic system with the same supports by means of a homotopic deformation. To deal with the deformed system, we adapt the polyhedral techniques introduced in [14] and refined in [7] in order to make a more careful analysis of the situation and determine the polynomial subsystems to be solved. Finally, we apply the symbolic deformation techniques for sparse elimination shown in [16] .. The algorithm in [16] can be considered as a symbolic version of [13] , which computes the isolated roots of a sparse polynomial system in (C * ) n . Provided the origin lies in all the polynomial supports, it computes the isolated roots of the system in C n (see [22] ). In this paper, our adaptation of the combinatorial construction in [14] allows us to extend the results in [16] to arbitrary supports, obtaining a procedure with a complexity depending polynomially on stable mixed volumes associated with the input system. The theoretic results underlying the correctness of our algorithm could also be applied to design a new numerical procedure in the spirit of [14, 7] . Although there are no explicit complexity estimates for the numerical algorithms in these papers, the fact that our approach deals with a smaller number of systems and with fewer variables than theirs would result in a better running time for the new algorithm.. The paper is organized as follows: In Section 2, some basic notation is introduced and the notions of geometric resolution, mixed subdivision and stable mixed volume are recalled. Section 3 is devoted to proving the theoretic geometric and combinatorial results that lead to the correctness of our algorithm, which is described in Section 4. Finally, in Section 5, we present some examples to show how our algorithm works and to compare it to previous procedures.

O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O B O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O


Parallel incomplete factorizations with pseudo-overlapped subdomains We address the hard question of e cient use on parallel platforms, of incomplete factorization preconditioning techniques for solving large and sparse linear systems by Krylov subspace methods. A novel parallelization strategy based on pseudooverlapped subdomains is explored. This results in e cient parallelizable preconditioners. Numerical results give evidence that high performance can be achieved. Combined with suitable preconditioners, Krylov subspace methods can be powerful iterative methods for solving the large sparse linear systems that arise in many scienti c computations 6,23 . In particular, incomplete factorizations as preconditioning techniques are often e cient 31,32 . Their major drawback is that they are not easy to parallelize without seriously a ecting the convergence. Several attempts have been reported in the literature, including reordering strategies, see, e.g., 1,4,8,11,16,20,21,30,38,45 47,49 , domain decomposition type approaches 9, 10, 22, 25, 27, 36, 41, 42 , and truncated Neumann series approaches, 44, 3, 48 . This re ects the di culty of the task. Recent surveys of techniques for achieving parallelism may be found in 13,17 . We aim at designing a new and more e cient parallelization strategy. W e p a rticularize an improved version of the parallel block method proposed in 27 to the pointwise incomplete factorization preconditionings. Our approach m a y be seen as a generalized domain decomposition DD method. If necessary, it may beimplemented as a global re-ordering technique. In contrast to classical DD methods, communication between adjacent subdomains is required during the construction and during the application of the preconditioner. A special treatment of the interface gridpoints allows to alleviate the signicant decrease of the convergence rate that is characteristic for DD methods and for most of the orderings that have been suggested for general parallel computations see, e.g., 16,14 . Our exposition is organized as follows. In Section 2, we g i v e a b r i e f o verview of our terminology and notation. Section 3 consists of background material, including a description of the preconditioned conjugate gradient PCG method, and a description of the generalized incomplete factorization preconditioner. In Section 4, we i n troduce and motivate our parallelization approach. Results of numerical experiments are reported in Section 5. Section 6 summarizes some concluding remarks and future directions for investigation. We have rst identi ed reasons why the performance of parallel incomplete factorizations deteriorates with increasing numberof subdomains. To remedy this, we have designed a new family of robust variants, that compare favorably with the popular additive Schwarz AS method. A salient feature of our approach is that no overlap seems necessary. The performance may be improved by a proper choice of the possibly variable relaxation parameters i . Preliminary numerical experiments indicate that optimal values depend on the numberof subdomains, in agreement with 36 .. Our approach may be adapted to unstructured grids as well. This is relatively easy when the domain is approximately partitioned into stripes, or in such a way that each subdomain has a limited number of neighbours. In other cases, care should be taken to de ne some logical hierarchy between neighbouring subdomains. For instance, if there holds i j then processor i pseudo-overlaps processor j, or vice-versa. By logical" we mean that deadlocks have to beavoided that is when two or more processors wait for information from each other. A variant of our approach, with an ordering induced pseudo-overlapping strategy, t h a t w i l l h e l p t o t a c kle intricate geometries and partitionings, will be published elsewhere after completion of all experiments. For illustration purposes, we consider the following self-adjoint second order two-dimensional elliptic PDE ,p u xx , q u yy + t u = fx; y in = 0 ; 1 0; 1. where , denotes a portion of the boundary @ of . We assume that if t = 0 then , 6 = ;. The coe cients p and q are positive, bounded and piecewise constant, and t is nonnegative, bounded and piecewise constant. We discretize 1 over a uniform rectangular grid of mesh size h in both directions with Two basic strategies for accepting or discarding ll-in have beendevelopped. these parameters is an art rather than a science. As is well known, potential bottlenecks for PCG methods, as described above, are the construction of the preconditioner B and the preconditioning step at each PCG iteration Step 3, see e.g. 46 .. In our analysis, we shall make use of GRIC with level ll`which, according to 31 , is denoted by GRIC`. Observe that any n o d e j that is connected, with respect to the graph of L, with two nodes i and k such that j i k gives rise to a ll-in element in position k;i of L, if` 1.. To solve a linear system of the form LPL t w = r, that occurs at each PCG iteration step 3 o n F i g . 1 , one may proceed with the two steps as described in Fig. 3 . The construction of GRIC` and the preconditioning step involve recurrence relations that inhibit e cient parallel computation, most notably for lexicographical ordering. We will rst consider GRIC0, in which the sparsity structure of A is preserved. In Fig. 4 , the graph of A is depicted with a stencil graph notation 28 : a diagonal entry a i;i is represented by circle numberi; the edge fi; jg here, thin lines corresponds to a nonzero o diagonal entry a i;j . Oblique thick lines represent the discarded level 1 ll-in entries that determine the remainder matrix R = B , A. The smaller kRk, the faster the convergence. The values n x and n y denote the numberof unknowns in x and y direction, respectively. In Fig. 4 , we have taken n x = n y = 5. Except for the boundary nodes where a Dirichlet boundary condition holds, the graph of A relates directly to the discretization grid.. For simplicity, the domain will be partitioned into stripes : p rectangular boxes that are assigned to p processors as depicted in c1 processor P s+1 starts its computations at gridpoints ?" the bottom layer" of P s+1 skipping the correction from gridpoints " the top layer" of P s ; c2 immediately after the computations at the bottom layer gridpoints of P s+1 have been completed, the relevant corrections from P s+1 for the top layer gridpoints of P s can be sent to P s but these points have to wait for the nal update when all other points of P s have been completed; c3 the actual computations start from two sides: for the subdomains in the upper side of the physical domain the bottom layer and the top layer reverses see Fig. 5; c4 for each subdomain the computation starts at the bottom layer gridpoints and they have been handled before any other gridpoint and nishes at the top layer grid points; c5 the numbering decreases or increases in the same way for neighbouring points, for the bottom layer gridpoints of P s+1 and the top layer gridpoints of P s compatible nunbering. This facilitates the implementation communication. Each gridpoint at the top layer has to know" where corrections come from. Condition c1 means that, according to some implicit global ordering, all the bottomlayer gridpoints ?" have to behandled numbered prior to all the neighbouring gridpoints: so these must wait for the contribution from bottom layer gridpoints before being updated.. We introduce the following terminology.. De nition 1 Since c ommunication only involves the gridpoints in the bottom and top layer, we will call the union the pseudo-overlap. Equivalently, we will say that P s is pseudo-overlapped b y P s+1 .. The trouble with any parallelization technique, that implicitly resorts to a reordering strategy like ours, is that the convergence properties of PCG usually deteriorate as the numberof subdomains increases, see, e.g., 25,27,36,37 . In order to get some feeling why this happens, let us examine the remainder matrix R. For this purpose, we add the rejected level-1 ll-in entries to the partial graph of Accepting all the ll-in entries of any level that are induced by the parallel ordering will avoid to deteriorate the PCG convergence, but unfortunately, this will also prevent the processors from performing e ciently in parallel. Going back to the incomplete factorization philosophy 31 , we will content ourselves with weakening the in uence of the neglected ll-in by increasing the pseudo-overlap width $, as well as the ll-in level inside the pseudooverlapping region. In Fig. 7 , this means that the gridpoints marked with " are included in the bottom layer for P s+1 in which case $ = 2 h. The bottom layer should comply with our requirements c1-c4. In the terminology of Doi. is denoted by ParGRIC`; $;`$, which reads as parallel generalized relaxed i n c omplete Cholesky factorization with pseudo-overlap width $;`$ stands for the ll-in level in the pseudo-overlapping regions, and`stands for the ll-in level in the remaining part of subdomains.. In the speci cation of $, the actual mesh size h will be dropped, say, k will stand for kh, in order to include variable mesh size problems and graphs of matrices that do not arise from discretized PDEs.. Remark 1 Under Condition c5, and in contrast to the level zero parallel preconditionings discussed in 25,36 , we are able to easily consider any ll-in level in the incomplete factorization schemes:. 1. during the symbolic incomplete factorization phase, neighbouring subdomains may readily determine the same quantity and structure of information that they need to send or receive; 2. during the numeric incomplete factorization phase, each pseudo-overlapping subdomain should pack the information needed, ll-in contributions included, in a vector whose length has been computed during the symbolic incomplete factorization step.. We stress that in most realistic problems, level zero incomplete factorization methods are seldomly e cient. In particular, on parallel architectures, classical overlapping or non-overlapping domain decomposition methods, that combine ingredients of both direct methods as local solver and iterative methods as global solver, are in general more competitive. See, e.g., 39,40,15 .

O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I I O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O


An automated signalized junction controller that learns strategies by temporal difference reinforcement learning This paper shows how temporal difference learning can be used to build a signalized junction controller that will learn its own strategies though experience. Simulation tests detailed here show that the learned strategies can have high performance. This work builds upon previous work where a neural network based junction controller that can learn strategies from a human expert was developed . In the simulations presented, vehicles are assumed to be broadcasting their position over WiFi giving the junction controller rich information. The vehicle's position data are pre-processed to describe a simplified state. The state-space is classified into regions associated with junction control decisions using a neural network. This classification is the strategy and is parametrized by the weights of the neural network. The weights can be learned either through supervised learning with a human trainer or reinforcement learning by temporal difference (TD). Tests on a model of an isolated T junction show an average delay of 14.12 s and 14.36 s respectively for the human trained and TD trained networks. Tests on a model of a pair of closely spaced junctions show 17.44 s and 20.82 s respectively. Both methods of training produced strategies that were approximately equivalent in their equitable treatment of vehicles, defined here as the variance over the journey time distributions. The results presented in Section 4 show that temporal difference reinforcement learning can be used to train a junction controller from a position of no prior information, where it is changing the lights at random, to a position of high performance.. On the Simple-T junction model the temporal difference trained neural network matched the performance of the human trained neural network in terms of both delay and equitability. In previous work ) the human trained neural network has been shown to significantly outperform the auctioning agent junction controller and the MOVA junction controller (Vincent and Peirce, 1988) .. On the more complex High-Rd model TD training matched human training in terms of equitability and exhibited lower performance in terms of delay with on average 3 seconds more delay per vehicle. The High-Rd model was also subject to ∼ 6 times more training in terms of simulated hours. This is indicative of the increased complexity of the problem to be solved in the High Rd model where two closely spaced junctions must be coordinated for best performance.. The performance improvement of the neural networks during TD training was characterized by long periods of stagnation punctuated by "breakthroughs" where performance suddenly increased (Figure 11 ). This makes it difficult to know if the best possible performance under TD training has been reached and performance may improve further with more training.. The motivations behind investigating TD learning (Section 1.2) were to find an alternative to human training and to potentially outperform human training. Urban signalized road junctions are usually controlled by active systems (e.g. Vincent and Peirce (1988) ; Hunt et al. (1982) ), which use sensors to measure the state on the road. The state is then used by the control algorithm to inform decisions on which colour to set the traffic lights. Sensors such as inductive loops (Sreedevi, 2005) and microwave emitter/detectors (Wood et al., 2006) are commonplace and widely deployed in developed areas. New sensing technologies such as vehicle to infrastructure WiFi communications have been extensively investigated in recent years (Kompfner, 2008; COOPERS, 2010; SAFESPOT, 2010) leading to a Europe wide reservation of frequencies (IEEE 802.11p ) for this type of communication.. The profusion of sensing technology leads to rich data that can be used for Urban Traffic Control (UTC). This enables the development of increasingly sophisticated control systems for signalized road junctions. In particular, data hungry machine learning algorithms can be employed to develop junction control systems that can learn improved strategies through various forms of training.. Recent important work on the optimisation of traffic signals has investigated a number of approaches including dynamic programming (Heydecker et al., 2007; Heung et al., 2005) , genetic algorithms (Mikami and Kakazu, 1993) , fuzzy-neural networks (Choy et al., 2003) and reinforcement learning (Chen and Heydecker, 2009) . This work has shown how to use learning techniques to optimise parameters in signal control strategy or to select pre-defined strategies.. Here we are concerned with a pattern recognition approach where control decisions are made purely based on a classification of state space. Earlier work using this approach has shown how to use supervised learning to enable a junction controller to learn strategies from a human expert trainer . In this paper the approach is extended by the application of reinforcement learning to enable a junction controller to learn strategies through experience.

O O O B O O O O O B I B I O O O O B I O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O B B O O O B I O O O O O O O O O O O O O B I O O O O O O O O O O O O O O B I O B I O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I B I O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O B O O B I O B I O O O O O O O B I O O O O O O O O O O O O O O B I O O O O O O O O O B O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B B O O O O O O O O B O O O O O O O O O O O O O O O O O B B O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O O O O O O B O O O O O O O O O O O O O O O O O O O O O B I O O O B O O O O O O


Fast Inference with Min-Sum Matrix Product Abstract-The MAP inference problem in many graphical models can be solved efficiently using a fast algorithm for computing min-sum products of n Â n matrices. The class of models in question includes cyclic and skip-chain models that arise in many applications. Although the worst-case complexity of the minsum product operation is not known to be much better than Oðn 3 Þ, an Oðn 2:5 Þ expected time algorithm was recently given, subject to some constraints on the input matrices. In this paper, we give an algorithm that runs in Oðn 2 log nÞ expected time, assuming that the entries in the input matrices are independent samples from a uniform distribution. We also show that two variants of our algorithm are quite fast for inputs that arise in several applications. This leads to significant performance gains over previous methods in applications within computer vision and natural language processing.Index Terms-Graphical models, MAP inference, min-sum matrix product. MIN-SUM matrix product (MSP) (a.k.a. distance matrix product) is an important operation with applications in a variety of areas, including in inference algorithms for graphical models [15] , parsing with context-free grammars [23] , and shortest paths algorithms [1] .. Our main interest in MSP involves its application to MAP inference in graphical models and optimization problems that have similar form. It is well known that inference in discrete graphical models with low tree width can be done using dynamic programming and belief propagation. McAuley and Caetano [15] showed that faster inference can be done in a large class of models if we have a fast method for MSP. This class includes cyclic and skip-chain models that arise in many applications including in natural language understanding and computer vision. See Fig. 1 for some examples.. Let A and B be two n Â n matrices. The MSP of A and B is the n Â n matrix C ¼ A B defined by. Note that this is exactly matrix multiplication in the min-plus (tropical) semiring.. Standard algorithms for inference with a tree-width 2 model take Oðmn 3 Þ time, where m is the number of variables in the model and n is the number of possible values for each variable. For models that contain only pairwise factors, inference can be done in OðmfðnÞÞ time if we have an algorithm for computing MSP of n Â n matrices in OðfðnÞÞ time (see Section 2) .. The brute-force approach for computing MSP of n Â n matrices takes Oðn 3 Þ time. Unfortunately, there is no known method that improves this bound by a significant amount in the worst case. An important difference from the standard matrix product is that the minimum operation does not have an inverse. This means that fast matrix multiplication methods that rely on a ring structure, such as Strassen's algorithm [21] , cannot be directly applied to compute MSP. Our main theoretical result is an algorithm for MSP that runs in Oðn 2 log nÞ expected time, assuming that the entries of each matrix are independent samples from a uniform distribution. Our experimental results show that the method also performs well under realistic inputs that arise in several applications.. Our basic algorithm uses a Fibonacci heap (or similar structure) and is mainly of theoretical interest. The algorithm can be implemented with an integer queue to obtain a practical solution. We also describe an alternative algorithm that computes exact values using a scaling technique and avoids any complex data structure. Our experimental results show that the methods perform well in three different applications: interactive image segmentation with active contours models ("snakes"), point pattern matching with belief propagation, and text denoising with skip-chain models. The MSP operation plays an important role for inference in a large class of graphical models. Our basic algorithm runs in Oðn 2 log nÞ expected time assuming the entries in each input matrix are independent samples from a uniform distribution. Despite this strong assumption, we show that the algorithm can be made very fast for inputs that arise in practical applications, achieving significant performance gains over existing methods. An interesting open question involves showing that the algorithm has good running time bounds for more general inputs once we include the speedups described in Section 3.3. Another direction for future work involves other applications of MSP, such as parsing with context-free grammars. Our work is motivated by McAuley and Caetano [15] , who noted the application of MSP for MAP inference with graphical models and gave an Oðn 2:5 Þ expected time algorithm for MSP. The method in [15] assumes every permutation of values in the inputs occurs with equal probability. This is a weaker assumption than the one we make in our analysis and could lead to a faster method in some applications. Section 4 compares the two methods and shows that our algorithms perform better in several applications.. The worst-case complexity of the MSP operation has been heavily studied in the theoretical computer science community because of its relation to the all-pairs-shortest-paths (APSP) problem. The worst-case asymptotic complexity of computing MSP of n Â n matrices is the same as solving APSP on dense graphs with n nodes [1] . To our knowledge, the best-known algorithm for the APSP problem takes Oðn 3 = log nÞ time in the worst case [8] . The search for a truly subcubic algorithm (Oðn 3À Þ) is a significant open problem in the area.. There are several known algorithms for the APSP problem which have good expected runtime, assuming that the input graph comes from a simple distribution (e.g., [11] , [17] , [12] ). However, the usual reduction of MSP to APSP (see [1] ) leads to graphs that have deterministic structure, violating the assumptions made by the APSP algorithms designed for random graphs.. Our basic algorithm can be seen as an application of Knuth's lightest derivation method (KLD) [14] , [10] with a special stopping criterion. Felzenszwalb and McAllester [10] suggested using KLD and an A* version of it for inference in graphical models. However, there is a difference between the approach we use here and the one suggested in [10] . When doing inference on a large model, we solve several small lightest derivation problems, each defined by a single MSP computation. In contrast, Felzenszwalb and McAllester [10] suggest solving a single large lightest derivation problem. Solving a sequence of small problems leads to better performance and simplifies the implementation.. Our algorithms improve dynamic programming and message passing methods for inference in low tree-width graphs when the number of possible values for a variable is large. Another approach for inference in some classes of graphical models involves graph cuts [7] , [6] . However, these methods are typically used for models with high tree width, a relatively small number of possible values per variable, and restricted classes of potential functions. None of the applications we consider can be easily addressed with graph cuts. We implemented our algorithms and tested them in several applications by comparing them to the naive (brute force) method for MSP and the method from [15] . Note that all of these methods are guaranteed to find an exact solution to the MSP problem. Our implementation of Algorithm 1 uses an integer queue, as described in Section 3.1. Both Algorithms 1 and 2 were implemented using all speedups described in Section 3.3. All methods were implemented in C++ using the GNU C compiler on a 2.8 GHz Intel PowerMac running Mac OS X 10.5. First, we evaluate our algorithms on uniform i.i.d. matrices. Note that such matrices satisfy the random rank statistics assumption made in [15] . Fig. 3 shows the performance of the different methods with running times on the left, and the number of additions done by each method on the right. This confirms that our methods have better asymptotic complexity on random inputs. The experiments below show that results on structured inputs that arise in practical applications are similar to the random case.

O O O B I I O B I O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I B I I B I I O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O B I O B I O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O B I O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O