Improved and scalable online learning of spatial concepts and language models with mapping

We propose a novel online learning algorithm, called SpCoSLAM 2.0, for spatial concepts and lexical acquisition with high accuracy and scalability. Previously, we proposed SpCoSLAM as an online learning algorithm based on unsupervised Bayesian probabilistic model that integrates multimodal place categorization, lexical acquisition, and SLAM. However, our original algorithm had limited estimation accuracy owing to the influence of the early stages of learning, and increased computational complexity with added training data. Therefore, we introduce techniques such as fixed-lag rejuvenation to reduce the calculation time while maintaining an accuracy higher than that of the original algorithm. The results show that, in terms of estimation accuracy, the proposed algorithm exceeds the original algorithm and is comparable to batch learning. In addition, the calculation time of the proposed algorithm does not depend on the amount of training data and becomes constant for each step of the scalable algorithm. Our approach will contribute to the realization of long-term spatial language interactions between humans and robots.


Introduction
Robots operating in various human environments must adaptively and sequentially acquire new categories for places and unknown words related to various places as well as the map of the environment (Kostavelis and Gasteratos, 2015).It is desirable for robots to acquire place categories and vocabulary autonomously based on their experience because it is difficult to manually design spatial knowledge in advance.Related research in the fields of semantic mapping and place categorization (Kostavelis and Gasteratos, 2015;Landsiedel et al., 2017;Pronobis and Jensfelt, 2012;Rangel et al., 2018;Sünderhauf et al., 2016) has attracted considerable interest in recent years.However, conventional approaches in most of these studies are limited insofar as the robots cannot learn unknown words and unknown place categories without pre-set vocabulary and categories.In addition, the processes for Simultaneous Localization And Mapping (SLAM) (Thrun et al., 2005) and for estimating semantics related to place have been addressed as separated module processes.However, in our proposed approach, the robot can automatically and simultaneously perform place categorization and environment mapping, and it can learn unknown words without prior knowledge.Our previously proposed unsupervised Bayesian probabilistic model integrates multimodal place categorization, lexical acquisition, and SLAM.In particular, this paper focuses on the problems of estimation accuracy and computational scalability in online learning.

Online learning
/idi/ /pyoigegyushitsu/ /kyoiNkeNkiyushitsu/ /idomari/ Step 25 Step 48 "konobashogaroboqtookibadayo" (This place is the robot storage space.) I will learn it correctly by rethinking previous estimations!"kyouiNkenkyuushitsunikimashita" (We come to the faculty lab.) I will learn it quickly so I will not let you wait! /robotookiba/ /kimashita/ Fig. 1 Overview of the scenario for online learning in this study.We assume a scenario in which the user teaches the robot the name of the place using a spoken utterance while moving together in the environment.The robot learns spatial concepts, language models, and maps while sequentially correcting mistakes from previous learnings based on its interaction with the user and environment, as shown from the bottom left to the bottom right.
We define a spatial concept as a place category is autonomously learned by the robot based on multimodal perceptual information, which includes names of places, features of scene images, and position distributions.Then, we define a position distribution as the spatial extent representing a place in the environment.Our study regarding the spatial concept formation and the lexical acquisition also constitute constructive approaches to the human developmental process and symbol emergence in cognitive developmental systems (Cangelosi and Schlesinger, 2015;Taniguchi et al., 2018b).Thus, we assume that the robot has not acquired any vocabulary in advance and can recognize only phonemes or syllables.In addition, the robot does not have prior knowledge of the current environment.In this study, a scenario in which the user teaches the robot the name of a place using a spoken utterance while moving together in the environment is studied.An overview of the scenario for online learning task is shown in Fig. 1.The robot and the user move around the environment.When they come to a place where the user wishes to teach, the user speaks a sentence regarding the place to the robot.The robot recognizes the speech, including unknown words, and segments the speech into words.Then, the robot obtains the present estimated position, the scene image, and the speech signal at that time, and acquires spatial knowledge regarding the environment, such as the relationship between words and places.
In online learning, also called sequential learning or incremental learning, an increase in scalability without reducing accuracy is especially important but difficult to achieve for mobile robots.Online learning has the advantage of being performed in real-time.This means that it can be used to adapt immediately to new data by sequentially estimating parameters each time.On the other hand, batch learning takes time to collect large amounts of data and to iterate it for learning.In the case of online learning, previous knowledge can be used immediately for reasoning and tasks such as language communication.Taniguchi et al. (2017) focused on deriving and constructing an appropriate online learning algorithm mathematically based on a theory of machine learning.In our previous work, we proposed SpCoSLAM as an integrated model of nonparametric Bayesian multimodal categorization, a Bayesian filter-based SLAM, speech recognition, and word segmentation, from the standpoint of unsupervised machine learning.However, this algorithm (Taniguchi et al., 2017) had inferior accuracy in terms of categorization and word segmentation compared to batch learning, owing to a situation whereby sufficient statistical information could not be used at the early stages of learning.In addition, speech recognition and unsupervised word segmentation were not completely online, and batch learning was used as an approximation.Therefore, the computational complexity of the processes of speech recognition and unsupervised word segmentation in-creased with an increase in training data.To enable online learning based on long-term human-robot interactions with limited computational resources, the following core problems need to be solved: (i) the increase in calculation cost owing to an increase in data, and (ii) the decrease in estimation accuracy when compared with batch learning.In intelligent robotics, the framework of online learning is regarded as important.In particular, online learning, which solves the above problem, is required for robots that gain knowledge while moving in the real world.
We here describe improved and scalable algorithms to solve the above-mentioned problems.The improved algorithm mainly addresses the problems of misrecognition (misclassification) and word segmentation in online learning.The scalable algorithm mainly addresses the problem of the increase in computation time.In this study, we introduce the approach of fixed-lag rejuvenation, which is considered particularly effective at solving these problems.Regarding the problem of online lexical acquisition, the improved and scalable algorithms take two respective approaches to the solution.The improved algorithm addresses the problem of under-segmentation, whereby the phoneme sequence is insufficiently segmented, by changing the manner by which the language model is updated such that it resegments the word sequence.The scalable algorithm performs in a pseudo-online manner by introducing a fixed-lag rejuvenation approach to speech recognition and word segmentation.
One of the advantages to the proposed online learning algorithm is that spatial concepts mistakenly learned by the robot can be corrected sequentially, something that could not be achieved thus far.Moreover, with the proposed algorithm, the robot can flexibly deal with changes in the environment and the names of places.The lower part in Fig. 1 shows the progress of online learning.In the lower left of Fig. 1, clustered places and words are incorrectly estimated, as shown by the elongated purple and blue ellipses.In the lower right of Fig. 1, by contrast, more accurate estimation is achieved by correcting errors as learning progresses.This is realized by reviewing and rethinking previous estimation results when new data is obtained.
The main contributions of this paper are as follows: -We propose an improved and scalable online learning algorithm with several novel techniques such as fixed-lag rejuvenation.-The improved online algorithm achieves an accuracy of place categorization and lexical acquisition comparable to batch learning.
-The scalable online algorithm achieves faster learning compared to original algorithms by reducing the order of computational complexity.
The remainder of this paper is organized as follows.In Section 2, we discuss related work on the formation of spatial concepts and online learning that is relevant to our study.In Section 3, we present an overview of the model, along with the formulation and the original online learning algorithm, SpCoSLAM.In Section 4, we present our proposed algorithms for improved and scalable online learning.In Section 5, we discuss the effectiveness of the proposed algorithms in a real environment.In Section 6, we evaluate the performance of place categorization and lexical acquisition in various virtual home environments.Section 7 concludes the paper.

Related work
2.1 Spatial concept formation Taguchi et al. (2011) proposed an unsupervised method for simultaneously categorizing self-positions and phoneme sequences from user speech without any prior language model.Taniguchi et al. (2016Taniguchi et al. ( , 2018a) ) proposed the nonparametric Bayesian Spatial Concept Acquisition method (SpCoA) using an unsupervised word segmentation method, latticelm (Neubig et al., 2012), and SpCoA++ for highly accurate lexical acquisition as a result of updating the language model.Gu et al. (2016) proposed a method to learn relative spatial concepts, i.e., the words related to distance and direction, from the positional relationship between an utterer and objects.Isobe et al. (2017) proposed a learning method to derive the relationship between objects and places using image features obtained by a Convolutional Neural Network (CNN) (Krizhevsky et al., 2012).Hagiwara et al. (2018) implemented a hierarchical clustering method for the formation of hierarchical place concepts.However, none of the above methods can sequentially learn spatial concepts from unknown environments without a map, because they rely on batch-learning algorithms.Therefore, we developed in previous work an online algorithm, SpCoSLAM (Taniguchi et al., 2017), that can sequentially learn a map, a lexicon, and spatial concepts to integrate positions, speech signals, and scene images.In Taniguchi et al. (2017), however, the accuracy was inferior to that of SpCoA.In this paper, we also compare our proposal to the latest batch learning method, SpCoA++.Because SpCoA++ is able to achieve nearly correct lexical acquisition, if we can successfully overcome the above problems by appropriately devising the learning algo-rithm, its accuracy should improve even with online lexical acquisition.
Our approach is relevant to research integrating semantic mapping with natural language processing (Hemachandra et al., 2014;Walter et al., 2013).Walter et al. (2013) developed an algorithm that can learn semantic graphs to integrate semantic representation into metric maps from natural language descriptions of aspects such as labels and spatial relationships.Hemachandra et al. (2014) proposed a mechanism to more effectively ground natural language descriptions by integrating scene appearance observations using camera images and laser data.In these studies, a word list, place labels, and the number of category types were known in advance.However, it is challenging to sequentially acquire new words and categories efficiently from a situation in which the lists of words and categories are not provided in advance.Our study includes lexical acquisition for unknown words and formation of new categories from speech signals using spatial information.Ball et al. (2013) implemented a biologically inspired mapping system, RatSLAM, which is related to pose cells in the hippocampus of a rodent.In addition, robots called Lingodroids using RatSLAM could acquire a lexicon related to places through robot-torobot communication (Heath et al., 2016).These studies reported that robots created their own vocabulary.Ueda et al. (2016) proposed a brain-inspired method, namely, a Particle Filter on Episode (PFoE) for agent decision making.PFoE can estimate the agent's internal state based on previous events recalled at the time.All previous data is thus accumulated to construct a state space in PFoE.We believe that PFoE is unsuitable for long-term trials because the state space becomes enormous.By contrast, our approach forms concepts from episodes using resources more reasonably for calculations, insofar as the state space is reduced through clustering.Although our proposed method was not originally inspired by biology or brain science, such research is highly suggestive.SpCoSLAM is an integrated model of self-localization, mapping, concept formation, and lexical acquisition.From the point of view of the brain, it may be possible to regard SpCoSLAM as a model that imitates some functions of the hippocampus and the cerebral cortex.If we assume that the training data-i.e., the robot's experiences based on a user's utterances-is the episodic memory, and that spatial concepts are semantic memory, the proposed algorithm can be interpreted as a representation of the process of forming concepts by extracting meaning from short-term episodic memory sequentially.Such matters are not further discussed in this paper, although they remain important for future research.

Improvement of online learning based on particle filters in unsupervised Bayesian models
As an approach involving Bayesian models that is similar to our model, there are related studies on object concepts.In particular, Araki et al. (2012b) proposed online Multimodal Latent Dirichlet Allocation (oMLDA) to acquire object concepts in an online manner, and combined this with the Nested Pitman-Yor Language Model (NPYLM), making it possible to perform lexical acquisition of unknown words sequentially.Aoki et al. (2016) constructed an algorithm that can infer an approximately global optimal solution by representing it as a single integrated model.The NPYLM is an unsupervised morphological analysis method based on a statistical model that enables word segmentation exclusively from phoneme sequences (Mochihashi et al., 2009).In addition, Nishihara et al. (2017) was able to reduce phoneme recognition errors by applying PFoMDLA to inferences using a particle filter instead of oMLDA.In these studies, online learning was realized as an algorithm in unsupervised machine learning.A spatial concept requires more real-time processing than an object concept because the robot learns spatial concepts while it moves through the environment.The mobile robot should not halt its spatial movement for calculations.Therefore, a more efficient and scalable algorithm is required.Canini et al. (2009) improved the accuracy of an online algorithm based on a particle filter with the rejuvenation technique.This technique resamples some randomly selected samples of previous observation data from a conditional probabilistic distribution similar to Gibbs sampling.For a completely random choice, the robot needs to memorize all of the previous data.Rejuvenation can deal with the problem of degenerating particles in particle filters.In this study, we introduce rejuvenation into our SpCoSLAM online learning algorithm.In our algorithm, we perform resampling from some recent data.Therefore, we consider that it will be possible to improve the estimation accuracy efficiently.
As another particle filter approach, Börschinger and Johnson (2011) proposed an online algorithm based on a Bayesian model for word segmentation.In addition, Börschinger and Johnson (2012) presented an incremental learning algorithm that introduces rejuvenation to a particle filter.They improved the performance of word segmentation with higher accuracy.The studies above were premised on segmentation of sequences without phoneme recognition errors.In this study, by contrast, the online word segmentation task is particularly challenging because phoneme recognition errors are included in speech recognition results.Hyperparameters of prior distributions m 0 , κ 0 , V 0 , ν 0 Fig. 2 Left: Graphical model representation of SpCoSLAM (Taniguchi et al., 2017).Gray nodes indicate observation variables, and white nodes are unobserved latent variables.Right: Description of random variables in SpCoSLAM.
3 SpCoSLAM: Online learning for spatial concepts and lexical acquisition with mapping

Overview
SpCoSLAM has the advantage that spatial concept formation, lexical acquisition, and SLAM, can be performed simultaneously by an integrated model.Figure 2 shows the graphical model of SpCoSLAM and lists each variable of the graphical model.The details of the formulation of the generation process represented by the graphical model are described in Taniguchi et al. (2017).The method learns sequential spatial concepts for unknown environments without maps.It also learns the manyto-many correspondences between places and words via spatial concepts and can mutually complement the uncertainty of information using multimodal information.Furthermore, the proposed method estimates an appropriate number of clusters of spatial concepts and position distributions depending on the data by using the so-called online Chinese Restaurant Process (CRP) (Aldous, 1985), one of the constitutive methods of the Dirichlet Process (DP).In addition, lexical acquisition including unknown words is possible by sequentially updating the language model.
The procedure of SpCoSLAM for each step is described as follows.

Formulation of the online learning algorithm
Our previously proposed online learning algorithm, Sp-CoSLAM, introduces sequential equation updates to estimate the parameters of the spatial concepts into the formulation of a Rao-Blackwellized Particle Filter (RBPF) (Doucet et al., 2000) in the FastSLAM 2.0 algorithm, which is landmark-based SLAM (Montemerlo et al., 2003), and the technique (Grisetti et al., 2007) applied to grid-based SLAM in a similar manner to that in FastSLAM 2.0.The particle filter is advantageous in that parallel processing can be easily applied because each particle can be calculated independently.
In the formulation of SpCoSLAM, the joint posterior distribution can be factorized to the probability distributions of a language model LM , a map m, the set of model parameters of spatial concepts Θ = {W, µ, Σ, θ, φ, π}, the joint distribution of the self-position trajectory x 0:t , and the set of latent variables C 1:t = {i 1:t , C 1:t , S 1:t }.We describe the joint posterior distribution of SpCoSLAM as follows: where the set of hyperparameters is denoted by h = {α, β, γ, χ, λ, m 0 , κ 0 , V 0 , ν 0 }.It is noteworthy that the speech signal y t is not observed during all time-steps.Herein, the proposed method is equivalent to FastSLAM 2.0 when y t is not observed, i.e., when the speech signal is a trigger for the place categorization.

Particle filter algorithm
The particle filter algorithm uses Sampling Importance Resampling (SIR).The importance weight is denoted by ω for each particle, where r is the particle index.The target distribution is P t , and the proposal distribution is Q t .The number of particles is R.The following equations are also calculated for each particle r; however, the subscripts representing the particle index are omitted.
We apply two modifications related to the weighting of the original SpCoSLAM algorithm (Taniguchi et al., 2017): (i) additional weight for i t , C t , and x t (AW), and (ii) weight for selecting a language model LM (WS).These modifications are more theoretically reasonable than the original SpCoSLAM model, and our proposed SpCoSLAM 2.0 online learning algorithm is extended on their basis.
We describe the target distribution P t that modified the derivation of Taniguchi et al. (2017) as follows: where the term p( Here, the target distribution for the particle filter is the marginal joint posterior distribution of the selfpositions x 0:t and the set of latent variables C 1:t because it is based on the RBPF technique adopted in FastSLAM in the same manner.The latent variables that are local parameters are estimated by a particle filter, and the probability distributions for global parameters LM , Θ, and m are calculated and held independently for each estimated particle.
We describe the proposal distribution Q t as follows: (3) Then, p(x t | x t−1 , z t , m t−1 , u t ) is equivalent to the proposal distribution of FastSLAM 2.0.The probability distribution of i t and C t is the marginal distribution pertaining to the set of model parameters Θ.This distribution can be calculated using a formula equivalent to collapsed Gibbs sampling.The details are described in Taniguchi et al. (2017).

Sampling of words using speech recognition and word segmentation
We approximate the probability distribution of S t in (3) as speech recognition with the language model LM t−1 and unsupervised word segmentation using the WFST speech recognition results with latticelm (Neubig et al., 2012) as follows: (4) where SR() denotes the function of speech recognition, L 1:t denotes the speech recognition results in WFST format, which is a word graph representing the speech recognition results.In the original mathematical formulas, only S t should be obtained by sampling.However, latticelm is a tool originally designed for batch learning.In addition, in order to perform unsupervised word segmentation, it is necessary to extract statistical information from the observation data.Therefore, resampling is necessary using all data from 1 to t, instead of exclusively using the distribution at time-step t.

Additional weight for i t , C t , and x t (AW)
Finally, the importance weight ω t modified from Taniguchi et al. (2017) is represented as follows: Unlike the original SpCoSLAM algorithm, the marginal likelihood for i t and C t weighted by the marginal likelihood for the position distribution was added to the additional part of the first term on the right side of (5).The amount of calculations does not increase because most of the formulas for weight ω t are already calculated when i t and C t are sampled.Weight calculation in consideration of the likelihood of the entire model can be realized by (5).This is described in Algorithm 1 (Line 16) and Algorithm 2 (Line 17).

Weight for selecting a language model LM (WS)
In the formulation of (1), it is desirable to estimate the language model LM t for each particle.In other words, speech recognition of the amount of data multiplied by the number of particles for each teaching utterance must be performed.In this paper, to reduce the computational cost, we use a language model LM t of a particle with the maximum weight for speech recognition.
We also modify the weight for selecting the language model from the entire weight ω t of the model to the weight ω S related to word information: The segmentation result from all of the uttered sentences for each particle changes at every step because the word segmentation processes use all previous data.Indeed, better word segmentation results can be selected by a weight that considers not only current data but also previous data.In addition, this modified weight corresponds to mutual information used for selecting the word segmentation results in SpCoA++ (Taniguchi et al., 2018a).This is described in Algorithm 1 (Line 23) and Algorithm 2 (Line 24).
4 SpCoSLAM 2.0: Improved and scalable online learning algorithm In this section, we describe an improved and scalable online learning algorithm, SpCoSLAM 2.0, that overcomes the problems in the original algorithm.Although the generative process and graphical model for SpCoSLAM are the same, the learning algorithm is different.Sp-CoSLAM 2.0 is a novel learning algorithm proposed with a modified mathematical formulation that retains the model structure, similar to the extension from Fast-SLAM to FastSLAM 2.0.First, the algorithm is improved by introducing techniques such as rejuvenation, as explained in Section 4.1.Next, a scalable algorithm is developed to reduce the calculation time while maintaining higher accuracy than the original algorithm, as described in Section 4.2.

Improving the estimation accuracy
We now turn to the details of the improved algorithm.Here, we introduce two elements: fixed-lag rejuvenation of latent variables, and re-segmentation of word sequences.A pseudo-code for the improved algorithm is given in Algorithm 1. Online learning using FLR in the improved algorithm.The thick orange frame is estimated by sampling.In this case, the fixed-lag value T L is three.The gray boxes mean that the estimated value will never again be updated, i.e., distributions of already immobilized (fixed) latent variables by online learning.
data of all time points, all previous samples need to be held in the memory.In the proposed algorithm, we introduce Fixed-Lag Rejuvenation (FLR) inspired by the Monte Carlo fixed-lag smoother (Kitagawa, 2014).This approach is similar to the sampling strategy of fixed-lag roughening for particle filter-based SLAM in Beevers and Huang (2007).Beevers and Huang (2007) indicated that the statistical estimation error could be reduced by applying Markov Chain Monte Carlo (MCMC)-based sampling to the trajectory samples over a fixed lag at each time step.
The fixed-lag smoother is a particle smoothing method that estimates particles approximating the smoothing distribution p(C τ | D 1:t ) (τ < t), where D is observed data.It is obtained by a simple modification to the particle filter.In this algorithm, particles are saved from time-step t − T L + 1 to t and are resampled according to the weight based on newly observed data each step.Here, the value of the fixed-lag is denoted by T L .This technique means that the particles at step τ can be estimated not by using the observed data D 1:τ , but rather with D 1:τ +T L , i.e., the smoothing distribution p(C τ | D 1:τ +T L ).In general, a smoothing method such as a fixed-lag particle smoother provides more accurate estimations than naive online estimation methods such as a particle filter in estimating the joint posterior distribution of latent variables.
Figure 3 shows an overview of the FLR of i t and C t .The notation τ | t in the box in Fig. 3 is shorthand notation for the subscript representing the time-step in the conditional marginal posterior distribution, e.g., p(C τ | D 1:t ).The FLR is the process of sampling the latent variables i τ and C τ by iterating T L times from the previous step t − T L + 1 to the current step t for each particle as follows: where i {1:t|¬τ } and C {1:t|¬τ } denote sets of elements from 1 to t without the elements of step τ .In this case, the latent variables of step t − T L can be sampled using data up to step t, as described in Algorithm 1 (Lines 12-14).Equation ( 7) is the same as the conditional posterior probability distribution for marginalized (collapsed) Gibbs sampling used in batch learning.Therefore, the FLR corresponds to slightly iterate Gibbs sampling for some recent previous latent variables in online learning.

Re-segmentation of word sequences (RS)
We introduce re-segmentation of word sequences to improve the accuracy of word segmentation.In the original algorithm, we approximated the left side of (4) by registering the word sequences segmented by latticelm to the word dictionary.However, this can be considered a process of sampling a language model LM from word sequences S * 1:t and a hyperparameter λ of a language model.Therefore, we adopt NPYLM, an unsupervised word segmentation method (Mochihashi et al., 2009), to estimate a language model from the word sequences as follows: The procedure of introducing the RS is as follows: (i) word sequences S 1:t are obtained by WFST speech recognition and latticelm; (ii) word sentences S * 1:t of a maximum likelihood particle are converted into syllable Algorithm 2 SpCoSLAM 2.0: Scalable algorithm L t +1:t = SR(L t +1:t | y t +1:t , AM, LM t ) 5: for r = 1 to R do 6: x[r] t = sample motion model(u t , x [r] t−1 ) 7: x t−1 ) 8: for j = 1 to J do 9: x j = sample motion model(u t , x [r] t−1 ) 10: end for

11
: t +1:t ∼ latticelm(S t +1:t | L t +1:t , λ) 13: for τ = t + 1 to t do 14: i end for 16: t , H [r] t +1:t , ω end for 30: return X t 31: end procedure sequences, and segmented into word sequences using NPYLM; (iii) the word dictionary LM is updated using segmented words, as described in Algorithm 1 (Line 24).In this manner, we can overcome problematic words that tend to become under-segmented while taking into account the uncertainty of speech recognition errors by latticelm.Note that there is a discrepancy between the words used for spatial concept acquisition and the word set registered in the word dictionary.

Scalability for reduced computational cost
In this section, we describe the details of the scalable algorithm.Here, we introduce two elements: the sequential Bayesian update of the parameters in the posterior distribution, and unsupervised word segmentation from WFST speech recognition results using FLR.The scalable algorithm can be combined with the FLR C t , i t of the improved algorithm.The pseudo-code for the scalable algorithm is given in Algorithm 2.

Sequential Bayesian update of parameters in the posterior distribution (SBU)
We introduce a Sequential Bayesian Update (SBU) for the posterior hyperparameters H t in the posterior distribution.In the original algorithm, the model parameters Θ are estimated from all the data D 1:t = {f 1:t , y 1:t } and the set of latent variables C 1:t during each step.However, FastSLAM avoids holding all the previous data by updating a map m t from x t , z t , and m t−1 sequentially.That is, it assumes the measurement model p(z t | x 0:t , z 1:t−1 ) = p(z t | x t , m t−1 ) and the updated occupancy grid map p(m t | x 0:t , z 1:t ) = p(m t | x t , z t , m t−1 ).Similarly, the posterior hyperparameters H t can be calculated from the new data D t , latent variables C t , and posterior hyperparameters H t−1 from previous steps.Thus, both the computational and memory efficiency, crucial for long-term learning with real robots, can be significantly improved.The SBU for the posterior hyperparameters is calculated as follows: These posterior hyperparameters H t can also be used to sample C t .In the implementation, it suffices to hold values of the statistics obtained during the calculation of the posterior distribution.Here, the calculation results from the left side and the right side of ( 9) are strictly the same.The SBU approach is also said to keep track of sufficient statistics in the particle filter (Kantas et al., 2015).The SBU equation is used together with FLR as follows: where a time-step before the lag value is t = t − T L .
In this case, it is only necessary to hold the observed Fig. 4 Overview of the Fixed-Lag Rejuvenation of S t .Left: Batch learning with the original algorithm.Right: Pseudo-online learning using FLR in the scalable algorithm.The thick orange frame is estimated by sampling from the joint distribution.In this case, the fixed-lag value T L is three.The gray boxes denote that the estimated value will never be updated again, i.e., distributions of already immobilized (fixed) latent variables by online learning.
Table 1 Computational complexity of the learning algorithms Algorithm Order SpCpSLAM (Taniguchi et al., 2017) data and posterior hyperparameters of the number corresponding to the lag value T L .Equation ( 10) is applied to Algorithm 2.

WFST speech recognition and unsupervised word segmentation using FLR (FLR-S t )
We describe the proposed algorithm that combines FLR and SBU to address problems of the unsupervised online word segmentation and to reduce the computation time simultaneously.FLR can also be extended to the sampling of S t in a pseudo-online manner.Figure 4 shows an overview of the FLR of S t .The notation τ | t takes the same meaning as it does in Fig. 3.The data used for speech recognition and word segmentation is modified from that in (4) to data with a fixed-lag interval.In addition, speech recognition is performed using the initial syllable dictionary in the steps before step T L and using a word dictionary from step t in the steps proceeding step T L + 1.In this case, we can perform word segmentation based on the statistical information collected from the WFSTs recognized using the number of data for the lag value T L .FLR performs simultane-ous sampling of word sequences S t +1:t of time-steps from t + 1 to the current step t as follows: Therefore, this approach can address the problem in the original algorithm by which incorrect word segmentation in early learning stages was propagated to the following learning stages.
Here, the amount of calculations is constant throughout each step, irrespective of the total amount of data.This property of the FLR of S t is an important advantage in scalability.However, there is a concern that word segmentation using FLR becomes inaccurate compared to batch learning because of the limited availability of statistical information.Essentially, the scalable algorithm is a trade-off between calculation time and word segmentation accuracy.In the language model update, the word dictionary LM t holds information regarding words S t +1:t segmented from steps t + 1 to t and the previous word dictionary LM t .This is described in Algorithm 2 (Lines 4,12,and 25).
Table 1 shows the order of computational complexity for each learning algorithm.The data number is denoted N , the number of particles R, the value of fixedlag T L , the number of iterations for Gibbs sampling in batch learning G, the number of candidates of word segmentation results for updating the language model in SpCoA++ M , and the number of iterations for the parameter estimation in SpCoA++ I. Variables without N are constants that can be preset by the user.Among these algorithms, therefore, only the scalable algorithm does not depend on the number of data N .In this case, the computational efficiency of the scalable algorithm is better than the original SpCoSLAM algorithm when T L < N .

Experiment I
We performed experiments to demonstrate online learning of spatial concepts in a novel environment.In addition, we performed evaluations of place categorization and lexical acquisition related to places.We compared the performance of the following methods: (A) SpCoSLAM (Taniguchi et al., 2017 (Taniguchi et al., 2018a) Methods (A) and (B) used the original and modified SpCoSLAM algorithms.Methods (C) and (D) used the proposed improved algorithms under different conditions.In methods (C) and (D), the lag value for FLR was set to T L = 10.Method (E) used the proposed scalable algorithm under three different conditions: the lag values for the FLR were set to T L = 1, 10, and 20 for (E1), (E2), and (E3), respectively.Batch-learning methods (F) was estimated by Gibbs sampling based on a weak-limit approximation (Fox et al., 2011) of the Stick-Breaking Process (SBP) (Sethuraman, 1994), one of the constitutive methods of the Dirichlet Process (DP).The upper limits of the spatial concepts and position distributions were set to L = 50 and K = 50, respectively.We set the number of iterations for Gibbs sampling to G = 100.In method (F), we set the number of candidate word segmentation results for updating the language model to M = 6, and the number of iterative estimation procedures to I = 10.In addition, (F) did not use image features in the same manner as the original model setting.Note that SpCoA++ (F) was not evaluated in Taniguchi et al. (2017) because it is the latest batch-learning method.

Online learning
We conducted experiments of online spatial concept acquisition in a real environment.We implemented Sp-CoSLAM 2.0 based on the open-source SpCoSLAM 1 , extending the gmapping package and implementing gridbased FastSLAM 2.0 (Grisetti et al., 2007) in the Robot Operating System (ROS).We used an open dataset, 1 https://github.com/a-taniguchi/SpCoSLAM2albert-b-laser-vision, i.e., a rosbag file containing the odometry, laser range data, and image data.This dataset was obtained from the Robotics Data Set Repository (Radish) (Howard and Roy, 2003).We prepared Japanese speech data corresponding to the movement of the robot from the above-mentioned dataset because speech data was not initially included.The total number of taught utterances was N = 50, including 10 types of phrases.The robot learned 10 places and 9 place names.The microphone was a SHURE PG27-USB.Julius dictationkit-v4.4(DNN-HMM decoding) (Lee and Kawahara, 2009) was used as a speech recognizer.The initial word dictionary contained 115 Japanese syllables.The unsupervised word segmentation system used latticelm (Neubig et al., 2012).The image feature extractor was implemented with Caffe, a deep-learning framework (Jia et al., 2014).We used a pre-trained CNN model, Places365-ResNet, trained with 365 scene categories from the Places2 Database with 1.8 million images (Zhou et al., 2018).The number of particles was R = 30.The hyperparameters for online learning were set as follows: , and ν 0 = 3.The above-mentioned parameters were set such that all online methods were tested under the same conditions.The hyperparameters for batch learning were set as follows: α = 10, γ = 10, β = 0.1, m 0 = [0, 0] T , κ 0 = 0.001, V 0 = diag(2, 2), and ν 0 = 3.The hyperparameters were determined manually and empirically according to each method.Note that the speech recognition decoder, the image feature extractor, and the hyperparameters were changed from Taniguchi et al. (2017).
Figure 5 (top) shows the position distributions in the environmental maps at steps 15, 30, and 50 with (D).This figure visualizes how spatial concepts are acquired during sequential mapping of the environment.The position distributions were appropriately formed for places uttered by a user each time.In step 15, the map covers only 2 rooms (in the upper right) and a corridor, with 5 position distributions.The map obtained at step 50 covers the entire environment, and there were eventually 11 estimated position distributions.Figure 5 (bottom) shows an example of the correct phoneme sequence of the place name, and the three best words estimated by the probability distribution p(S t | i t , Θ t , LM t ) at step t.The left side shows an example of the scene images observed in the i t -th position distribution corresponding to the name of each place.As the steps proceed, it can be seen that the words corresponding to the places were stably learned as phoneme sequences closer to the correct answers.For example, in /kyouyuuseki/ (shared desk ), in step 15, the correspondence between the place and phoneme se-   quence was insufficiently learned: e.g., /bawakyoo/ and /yuseki/.However, by step 50, the word was learned correctly: /kyouyuseki/.The index of the position distribution of /roboqtookiba/ (robot storage space) was changed from 4 to 6.This change means that the label number switched as a result of the previous estimate values being modified while learning progressed.Details of the online learning experiment can be found in video online 2 .

Evaluation metrics
We evaluated the different algorithms according to the following metrics: the Adjusted Rand Index (ARI) (Hubert and Arabie, 1985) of the classification results of spatial concepts C 1:N and position distribution i 1:N ; the Estimation Accuracy Rate (EAR) of the estimated total numbers of spatial concepts L and position distributions K; and the Phoneme Accuracy Rate (PAR) of uttered sentences and words related to places.We conducted six learning trials under each algorithm condi-2 https://youtu.be/H5yztfmxGbc tion.The details of the evaluation metrics are described in the following sections.

Estimation accuracy of spatial concepts
We compared the matching rate for the estimated indices C 1:N of the spatial concept and the classification results of the correct answers given by a person.In this experiment, the evaluation metric adopts the ARI, which is a measure of the similarity between two clustering results.The matching rate for the estimated indices i 1:N of the position distributions was evaluated in the same manner.
In addition, we evaluated the estimated number of spatial concepts L and position distributions K using the EAR.The EAR was calculated as follows: where n C t is the correct number and n E t is the estimated number at time-step t.

PAR of uttered sentences
We next compared the accuracy rate of phoneme recognition and word segmentation for all the recognized sentences.However, it was difficult to separately weigh the ambiguous phoneme recognition and the unsupervised word segmentation.Therefore, the experiment considered the position of a delimiter as a single letter.The correct phoneme sequence was suitably segmented into Japanese morphemes using MeCab (Kudo, 2006), an off-the-shelf Japanese morphological analyzer that is widely used for natural language processing.However, the name of the place was considered a single word.
We calculated the PAR of the uttered sentences with the correct phoneme sequence s P t , and a phoneme sequence s R t of the recognition result of each uttered sentence.The PAR was calculated as follows: where LD() was calculated using the Levenshtein distance between s P t and s R t .Here, n P denotes the number of phonemes of the correct phoneme sequence.

PAR of words related to places
We also evaluated whether a phoneme sequence has learned the properly segmented place names.This experiment assumed a request for the best phoneme sequence, s * t , representing the self-position x t of the robot.We compared the PAR of words with the correct place name and a selected word for each teaching place.The PAR was calculated using (13).
The selection of a word s * t,b was calculated as follows: In this experiment, we used the self-position x t that was not included in the training data to evaluate the PAR of words.Here, the robot can perform sufficiently accurate self-localization using a laser range finder.Therefore, in this experiment, we assume that x t is given an accurate coordinate value without errors.
The more a method accurately recognized words and acquired spatial concepts, the higher is the PAR.We consider this evaluation metric to be an overall measure of the proposed method.

Evaluation results and discussion
In this section, we discuss the improvement and scalability of the proposed learning algorithms.Table 2 lists the averages of the evaluation values calculated using the metrics ARI, EAR, and PAR at step 50.

ARI and EAR results
In terms of categorization accuracy, the proposed algorithms that introduced FLR tended to show higher ARI values than the original algorithms (A) and (B) of SpCoSLAM.Figure 6  Table 3 Examples of word segmentation results of uttered sentences.
English "This place is the shared desk." Figure 7 shows the results of the EAR values with spatial concepts and position distributions, i.e., the accuracy of the estimated number of clusters, for each step.The EAR values were not stable in the steps during the first half, although they converged stably to high values in the latter half.In the result at step 50, (D) showed the highest EAR value L and (E1) showed the highest EAR value K.However, for both L and K, looking at all the steps on average, (A) and (B) yielded relatively low values overall, and (C) and (D) yielded relatively high values.(E1) -(E3) tended to show values between original algorithms, (A) and (B), and improved algorithms with FLR, (C) and (D).From the results of (C) and (D), EAR values improved considerably by introducing the FLR of C t and i t .

PAR sentence and word results
From the results of the improved algorithm (D), the PAR values (sentence and word) improved markedly by adding the re-segmentation of the word sequences.These results show that the robot can accurately segment the names of places and learn the relationship between places and words more precisely.In particular, method (D), which combines the FLR and RS, achieved an overall improvement comparable to the other online algorithms.Some trial results showed PAR values comparable to those of SpCoA++ (F). Figure 8 shows the PAR of words for each step.The PAR tended to increase as a whole.Therefore, it can be expected that the PAR values will further increase as the number of steps advances.Table 3 presents examples of word segmentation results with the four methods.The correct phoneme sequence, i.e., ground truth, was segmented into Japanese morphemes using MeCab (Kudo, 2006), where " | " denotes a delimiter, i.e., a word segment position.The parts in bold correspond to the name for each place.SpCoSLAM (A) showed undersegmentation results in many cases.On the other hand, it can be seen that SpCoSLAM 2.0 (D) and (E3) properly segmented the phoneme sequences representing the name of the place.Comparing (D) and (E3), (D) obtained segmentation results close to those of the batch learning method (F), and (E3) sometimes slightly oversegmented words.Therefore, SpCoSLAM 2.0 can mitigate under-segmentation when the word segmentation of the batch learning method is applied in a pseudoonline manner.

Original and modified SpCoSLAM algorithms
Although the modified SpCoSLAM (B) is theoretically more appropriate than the original algorithm (A), few differences were found between them.In the proposed algorithms, the time-driven process, i.e., SLAM part, and the event-driven process, i.e., spatial concept formation and lexical acquisition, were estimated by the same particle filter.Although self-localization and mapping were performed each time the robot moved in an environment, latent variables for the spatial concepts and lexicon are updated only upon the user's utterance.Thus, particles can fluctuate as a result of resampling due to movement in the absence of the user's utterance.Consequently, the weight for self-localization might be influential, rather than the weight for the spatial concept and lexicon.This will be investigated in future work.

Calculation time and scalable algorithm
Figure 9 shows the calculation times between online learning algorithms.With batch learning, SpCoA++'s overall calculation time including the runtime of rosbag for SLAM was 13,850.873s, and the calculation times per iteration for the iterative estimation procedure and Gibbs sampling were 1,318.954s and 1.833 s, respectively.In the original SpCoSLAM algorithm, (A) and (B), and the improved SpCoSLAM 2.0 algorithm, (C) and (D), the calculation time increased with the number of steps, i.e., as the amount of data increased.However, the scalable SpCoSLAM 2.0 algorithm (E1) -(E3) retained a constant calculation time regardless of an increase in the amount of data.Therefore, we can exert particularly powerful effects for long-term learning.
In the scalable algorithm (E1) -(E3), the evaluation values of ARI and PAR tended to improve overall when the lag value increased.In particular, when the lag value was 20, relatively high evaluation values are seen to approach those of the improved algorithm.
Owing to a trade-off between the fixed-lag size and accuracy, the algorithm needs to be set appropriately according to both the computational power embedded in the robot and the duration requirements for actual operation.In this experiment, we did not evaluate the scalability of the algorithm with parallel processing.However, we considered that the proposed algorithm could be executed even faster by parallelizing the particle process and by using Graphics Processing Units (GPUs).As such, we consider that the robot would be able to move within the environment while learning in real-time.

Experiment II
In this experiment, it is investigated whether trends similar to the evaluation results of the real environmental dataset in Section 5 can be stably obtained across different environments.Place categorization and lexical acquisition related to places in virtual home environments were evaluated, and the evaluation metrics ARI, EAR, and PAR for the methods (A) -(F) were compared in the same manner as in Section 5.

Condition
Online spatial concept acquisition experiments were conducted in various virtual home environments.The simulator environment was SIGVerse version 3.0 (Inamura et al., 2010), a client-server based architecture that can connect the ROS and Unity.The virtual robot in SIG-Verse was Toyota's Human Support Robot (HSR), and we used 10 different home environments 3 created using Sweet Home 3D 4 , which is a free software for interior design application.Figure 10 shows examples of the home environments.For each place, 10 training data were provided on average.The total number of taught utterances was N = 60, including 10 types of phrases.The robot learned six places and their respective names.The microphone and speech recognizer were the same as those in Section 5.1.The image feature extractor was a pre-trained BVLC CaffeNet model (Jia et al., 3 3D models of home environments are available in https: //github.com/a-taniguchi/SweetHome3D_rooms. 4 Sweet Home 3D: http://www.sweethome3d.com/2014).The number of particles was R = 10.The hyperparameters for learning were set as follows: α = 10.0, γ = 1.0, β = 0.1, χ = 0.1, m 0 = [0, 0] T , κ 0 = 0.001, V 0 = diag(2, 2), and ν 0 = 3.The hyperparameters were determined manually and empirically.The abovementioned parameters were set such that all methods were tested under the same conditions.In method (F), the upper limits of the spatial concepts and position distributions were set to L = 20 and K = 20, respectively.The other settings were identical to those in Section 5.
The main target of the evaluation in this study is the accuracy of place clustering and lexical acquisition, i.e., extended points in SpCoSLAM 2.0.Therefore, in this experiment, it is assumed that sufficiently accurate mapping and self-localization are possible with a highprecision distance sensor, and using an online learning algorithm which separates and omits the SLAM process was executed.The true values obtained by the simulator were used as the self-position data.

Result
In this section, the improvement and scalability of the proposed learning algorithms in home environments are discussed.Table 4 lists the averages of the evaluation values calculated using the metrics ARI, EAR, and PAR at step 60.
The ARI showed a similar trend as the result of real environmental data.However, compared to the original algorithms (A) and (B), there was almost no difference in the values in algorithms that introduced FLR.In addition, the EAR showed a slightly different trend than the real environmental data.In the improved algorithms (C) and (D), the number L of categories of  spatial concepts smaller than the true value was estimated compared to other algorithms.We consider that this reason was due to the fact that it was re-combined into the same category by FLR.Because the dataset was obtained in the simulator environment, for example, the image features could be insufficiently obtained for place categorization, i.e., similar features might be found in different places.Such a problem did not occur when using real environmental data.
The PAR had the same tendency as the result of real environment data.Similar to Section 5.3, the improved algorithm with RS (D) showed lexical acquisition accuracy comparable to batch learning (F).In addition, the scalable algorithms with FLR of S t (E2) and (E3) showed higher values than the original algorithms.Figure 11 shows the average values of the PAR of words for each step in different environments.Similar to Fig. 8, the PAR tended to increase overall.Thus, it can be seen that RS and FLR of S t work effectively in virtual home environments.
In the comparison of the original and modified Sp-CoSLAM algorithms (A) and (B), the modified algorithm (B) showed higher overall values in the evalu-ation values of ARI and PAR.We consider that the weight for the spatial concept and lexicon acted more directly in this experiment than in the experiment in Section 5, because it was not affected by the weight for self-localization.
In scalable algorithms (E1) -(E3), as the FLR value increased, the tendency for the overall evaluation values to increase appeared more prominently than for the results of real environment data.
Figure 12 shows the average calculation times between online learning algorithms in simulator environments.We confirmed that the result was similar to Fig. 9, which was the result using the real environment data.With batch learning, SpCoA++'s overall average calculation time was 8,076.288s, and the calculation times per iteration for the iterative estimation procedure and Gibbs sampling were 807.623 s and 1.346 s, respectively.
The following are the common inferences from the results of both the simulation and real-world environments.For the online learning, if the user requires the performance of lexical acquisition even at an increased time cost, they can execute the improved algorithm (D) or scalable algorithm with a larger lag value, e.g., (E2) and (E3).If the user requires high-speed calculation, they can obtain better results faster than the conventional algorithm (A) by executing a scalable algorithm such as (E1) and (E2).

Conclusion
This paper proposed an improved and scalable online learning algorithm to address the problems encountered by our previously proposed SpCoSLAM algorithm.Specifically, we proposed online learning algorithm, called Sp-CoSLAM 2.0, for spatial concepts and lexical acquisition, for higher accuracy and scalability.In experiments, we conducted online learning with a robot in a novel environment without any pre-existing lexicon and map.In addition, we compared the proposed algorithm to the original online algorithm and to batch learning in terms of the estimation accuracy and calculation time.The results demonstrate that the proposed algorithm is more accurate than the original algorithm and of comparable accuracy to batch learning.Moreover, calculation time of the proposed scalable algorithm becomes constant for each step, regardless of the amount of training data.We expect this work to contribute to the realization of long-term spatial language interactions between humans and robots.
In the future, we shall experiment with long-term online learning of spatial concepts in large-scale environments based on the scalable algorithm proposed in this paper.Furthermore, with additional development, it will be possible to introduce a forgetting mechanism to the proposed algorithm as with Araki et al. (2012a).When a robot continues to operate over a long period of time it will encounter changes in the environment, such as the names of places and areas.Consequently, the robot will benefit from using the latest observation data as opposed to the previous observation data.We believe that such a mechanism will be especially effective for long-term learning.
The proposed method constructs spatial concepts on a metric map; however, it can also be extended to learning the topological structure of places as with Karaoguz and Bozma (2016); Luperto and Amigoni (2018).We explore whether this facilitates navigation tasks with human-robot linguistic interactions.In addition, loopclosure detection has been studied actively in recent years, as is evident from long-term visual SLAM (Han et al., 2018).The generative model of SpCoSLAM is connected to SLAM and lexical acquisition via latent variables related to the spatial concepts.Therefore, we shall also explore loop-closure detection based on speech signals and investigate whether spatial concepts can positively affect mapping.
We will explore whether the SpCoSLAM model proposed herein can be integrated with other probabilistic models to form a large-scale cognitive model for general-purpose autonomous intelligent robots using a SERKET architecture (Nakamura et al., 2018).However, applications of the SERKET architecture are limited due to its computational cost for learning the enormous parameters of the whole model.Even in such a case, we consider that our proposed approach to online learning will be extensively useful because it can be applied to various other Bayesian models.
(a) The robot obtains Weighted Finite-State Transducer (WFST) speech recognition results from the user's speech signals using a language model.(b) The robot obtains the likelihood of self-localization by performing FastSLAM.(c) The robot segments the WFST speech recognition results using an unsupervised word segmentation approach called latticelm (Neubig et al., 2012).(d) The robot obtains the latent variables of spatial concepts by sampling.(e) The robot obtains the marginal likelihood of the observed data as the importance weight.(f) The robot updates the environmental map.(g) The robot estimates the set of model parameters of the spatial concepts from the observed data and the sampled variables.(h) The robot updates the language model of the maximum weight for the next step.(i) The particles are resampled according to their weights.Steps (b) -(g) are performed for each particle.

Fig. 3
Fig.3Overview of the Fixed-Lag Rejuvenation of i t and C t .Left: Naive online learning in the original algorithm.Right: Online learning using FLR in the improved algorithm.The thick orange frame is estimated by sampling.In this case, the fixed-lag value T L is three.The gray boxes mean that the estimated value will never again be updated, i.e., distributions of already immobilized (fixed) latent variables by online learning.

Fig. 5
Fig. 5 Top: Learning results of position distributions in a generated map.Ellipses denote the position distributions drawn on the map at steps 15, 30, and 50.The colors of the ellipses were randomly determined for each index number i t = k.Bottom: Examples of scene images captured by the robot.The correct word (in English) and estimated words are shown for each position distribution at steps 15, 30, and 50.

Fig. 7
Fig. 7 Change in the EAR regarding the estimated total number of spatial concepts L (top) and position distributions K (bottom) for each step.

Fig. 8
Fig.8Change in the PAR of words for each step.

Fig. 9
Fig.9Calculation times par step for evaluating scalability.

Fig. 10
Fig. 10 Examples of home environments in SIGVerse.

Fig. 11
Fig. 11 Change in PAR of words for each step in simulator environments.

Table 2
Evaluation results in a real environment.

Table 4
Evaluation results in simulator environments