• 沒有找到結果。

Derivation of Optimal Motion Index

3.1 Intention Deduction

3.1.2 Derivation of Optimal Motion Index

From the motion generation process discussed above, we can take the intention de-duction process as that of finding proper motion index M I. To find the optimal M I among all M I candidates, we introduce first the process for M I evaluation, shown in Fig. 3.5(a). This process evaluates the fitness of the M I candidates de-rived from the demonstrated motion, based on a reasoning that proper M I should lead to a generated motion very similar to the human demonstrated motion, which includes all the delicate motions. In Fig. 3.5(a), from the demonstrated motions, we select one demonstrated motion as the validating motion and the rest as the training motions. We will discuss the selection of validating and training motions later. For an M I candidate derived from the validating motion, the motion gen-eration module, described above, generates motions based on the training motions and the environmental state corresponding to the validating motion; the generated motions, with their lengths set to be equal to that of the validating motion, are then compared with the validating motion via the motion comparison module, yielding the differences between them (marked as errors). Because the operator may per-form the demonstrations in different speeds and possibly with different orders for the events involved, the corresponding delicate motions are likely to be with various sampling rates, or to appear in different portions of the demonstrated trajectories.

To tackle this, our strategy is to let each of the delicate motions of the validating motion be compared with every portion of the training motion, accompanied by altering sampling rates, showing in Fig. 3.5(b). Through this comparison process, the generated motion, whose delicate motions lead to the minimum difference when compared with those of the validating motion, is determined as the output and sent to the motion comparison module for the following comparison. As a high search complexity is expected, we come up with an approach analogous to that of dynamic time warping (DTW) in execution [56]. Details of this strategy will be explained in next section.

We go on with the process for M I generation, shown in Fig. 3.6. In Fig. 3.6, among all the demonstrated motions, one demonstrated motion is first selected as

Select

Figure 6: Selection of validating and training motions from demonstrated motions.

Validating motion MI Generation

Figure 3.6: Process for M I generation.

: multiple I/O

Figure 7:

The complete process for deriving the optimal motion index (MI).

Figure 3.7: Process for optimal M I derivation.

the validating motion, denoted as QV, and the rest as the training motions, QT, for each sequence of the process. The process will be repeated until each of the demonstrated motions serves as the validating motion once. In next step, the M I generator will locate all possible M I candidates from QV. Because the proposed approach does not constrain the human operator to perform the task with certain motion speed or motion type, and also allows the order of the events to be altered during demonstration, there is in fact not a priori knowledge for the selection of M I.

The criterion for M I generation is thus to let M I candidate correspond to every portion of QV with a duration longer than 0.3 second, as human cannot cognize an event until it happens 0.3 second later [59]. It can be expected that there will be a huge number of M I candidates. That is why we employ the method of dynamic programming for the search of the optimal M I.

With the M I evaluation process in Fig. 3.5(b) and M I generation process in Fig. 3.6, Fig. 3.7 shows the entire process for optimal M I derivation. For the

of them serves as the validating motion once. Via the M I generation process, M I candidates along with the validating and training motions are sent into the M I evaluation process to determine which M I candidate leads to the minimum error, identified as an optimal M I candidate. As each validating motion corresponds to one optimal M I candidate, the outputs of the outer dotted block are the optimal M I candidates for each of them. Finally, the optimal M I is determined to be the one with the minimum error among all optimal M I candidates.

3.1.3 Implementation of Intention Deduction

For mathematical formulation of this optimal M I derivation process, we start with the description of M I for a given validating motion QV, denoted as M IV:

M IV = {dV1, dV2, .., dVN} (3.4) with

dVj = {nVj, lVj, sVj} (3.5) where dVj indexes the delicate motion DVj with nVj, lVj, and sVj the starting time, end time, and number of the operated object. According to M IV, QV can then be expressed as the combination of a series of delicate and move motions:

QV = {MV1, DV1, MV2, DV2, ..., DVN, MVN +1} (3.6) On the other hand, with the same M IV, the generated motion QiG for each training motion QiT can be formulated as

QiG = {MGi1, DiG1, MGi2, DiG2, ..., DiGN, MGiN +1} (3.7) where DiGj and MGij are its delicate and move motion, respectively. DGij can be determined via the M I evaluation process above, of which the minimization between DGij and DVj is dealt with a DTW-like method:

DGij = similar(QiT, DVj) (3.8)

In the similar function, the training motion QiT is transformed to match the environment of the validating motion according to the possible operated object sVj,

and generated delicate motion DiG

j is searched from the transformed motion to be similar to DVj as close as possible. Therefore, the search can use a DTW-like method to minimize the difference between DGi

j and DVj [56]. Details of this method will be explained in next section.

After the generated delicate motions are generated, MGi

j determined by func-tion MG, which utilizes the cubic polynomial to smoothly connect the two delicate motions, DGij−1 and DiGj:

MGij = MG(DGij−1, DGij) (3.9)

To determine the optimal motion index M IV, QV will be compared with all QG generated according to every M IV. Because we are looking for an M IV that may induce all the necessary delicate motions, M IV should not induce too much deviation between the delicate motions for QV and QG, and consequently between the move motions for them. By taking Emax as the maximum difference between the delicate and move motions for QV and those QG generated for all the training motions corresponding to some M IV, we determine M IV, among all M IV, to be the one that leads to the smallest Emax:

M IV = arg min Here, ED computes the difference between the respective delicate motions for QV and those QG, and EM that for the move motions, with MV as a function which outputs the move motion part between two delicate motions of the validating motion, DVa and DVb. Because each demonstrated motion serves as the validating motion once, the final optimal motion index M I∗∗ for all demonstrated motions will be further

Emax, demoted as E. As the length LV for each QV may not be the same, E needs to be normalized before the comparison. M I∗∗ is then formulated as

M I∗∗= arg min

M IV E/LV (3.14)

The search for M I∗∗ is of high complexity, as exhibited in Eqs. (3.10)-(3.14) above.

As an attempt to enhance search efficiency, we employ the method of dynamic programming [60] and let the computation of E in Eq. (3.14) be expressed into a recursive formulation:

E = min

dVk ER(DVk) + EM(DVk, DVN +1) (3.15) with

ER(DVk) = min

dVk−1(ER(DVk−1) + EM(DVk−1, DVk)) + ED(DVk) (3.16) where ER(DVk) stands for the minimum difference between the motions from the first move motion to a given delicate motion; dVk and dVk−1, described in Eq. (3.5), index the delicate motions DVk and DVk−1; and 1 ≤ k ≤ N . Because the number of delicate motions is not known in advance, N and k are not specific numbers. Also note that, the first move motion is generated between DV0 and DV1, and the last one between DVN and DVN +1, with DV0 and DVN +1 taken as the first and last point of the trajectory, respectively. In Eq. (3.15), E is derived as the minimum one for all ER(DVk) with ER(DVk) computed recursively via Eq. (3.16). With Eqs. (3.15) and (3.16), dynamic programming can take advantage of the table generated for ER(DVk) to simplify the computation in deriving E.

Based on the discussions above, the algorithm for intention derivation algorithm is formulated in Algorithm 1. Time complexity for this optimal M I derivation pro-cess is related to the number (R) and length (LV) of the demonstrated motions and the number (S) of objects involved in the task. Here, the lengths of the demon-strated motions are assumed to be close. In Eqs. (3.15) and (3.16), the generation of the table for ER(DVk) takes up most of the time consumed. The table has O(LV2·S) elements, and each element deals with the complexity of the order of O(R · LV3· S).

During the entire process, the table needs to be generated R times. The final time complexity is thus computed to be in the order of O(R2· LV5· S2).

The divide-and-conquer method [60] may also be an alternate to solve Eq.

(3.14). However, because our proposed approach takes every portion of the trajec-tory of the validation demonstration as the candidate for a possible delicate motion, it is not that straightforward to divide the trajectory properly. Consequently, the search for the optimal solution may demand a large number of divisions, leading to high computational load.

Algorithm 1 Find the intention of the task through R times of demonstrations Input: the demonstrated trajectories Qi (1 ≤ i ≤ R) for the R times of

demonstra-tions

Output: the optimal M I∗∗

1: for i = 1 to n do

2: Select Qi among the R recorded trajectories as the validating motion QV and the rest as the training demonstrations QT

3: Apply the method of dynamic programming, based on Eq. (3.10), to deter-mine the optimal M I for QV

4: end for

5: Utilize Eq. (3.14) to determine the optimal M I∗∗ for the demonstrator among those M I for the R validating motions

6: return M I∗∗

相關文件