11.07.2015 Views

Knjiga apstrakata - Mathematical Institute of the Serbian Academy of ...

Knjiga apstrakata - Mathematical Institute of the Serbian Academy of ...

Knjiga apstrakata - Mathematical Institute of the Serbian Academy of ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

The natural question here is how to find decomposition which minimizes <strong>the</strong> average time <strong>of</strong> calculation for function f.But before that, we have to find a way to efficiently find <strong>the</strong> average time for one particular decomposition ∆(f). Themain issue is how to divide <strong>the</strong> available memory resource among functions f i in <strong>the</strong> optimal way. The next section givesanswer to that question.3 Optimal resource distributionThe average time for evaluating <strong>the</strong> function f is given by formulaWe are looking to maximise ω(D), whereE f,∆ [T ] = T c (∆(f)) −ω(q) =q∑j=1D∑j=1P (X (j,mj)M)(T c (f j (x j )) − T M ) (4)P (X (j,mj)M)(T c (f j (x j )) − T M ) (5)Each function f j from a decomposition ∆(f) can count on m j memory locations and ∑ Dj=1 m jM, 0m j M. Since P (X (j,mj)M)depends on m j , finding minimal average time E f,∆ [T ] requires optimal configuration [m 1 , m 2 , ..., m D ]. One way to solvethis is by brute force, but <strong>the</strong> problem with this approach is exponential complexity. Here, we will propose <strong>the</strong> algorithmbased on dynamic programming which solves <strong>the</strong> problem in polynomial time.Step 1. For each 1jD calculate P ij = P (X (j,i)M) where m j = i, 0il j and l j = min{M, length <strong>of</strong> vector x j }. Once again,this can be done by brute force, but exponential complexity can be avoided by reducing this problem to finding M + 1best paths in a trellis. Therefore, <strong>the</strong> complexity <strong>of</strong> this procedure is O(DMK 2 N).Step 2. Let’s define Q ij = P ij (T c (f j (x j )) − T M ). Let’s define matrix Ω and its element Ω[i, j, k] as max{ω(j)} such thatm j = i and ∑ ja=1 m a = k. Now we can find max{ω(D)} by <strong>the</strong> following procedure with complexity O(M 3 D).Initialization. For 0il 1 , 0kM{Q i1 if i = kΩ[i, 1, k] =(6)0 o<strong>the</strong>rwise.Recursion. For 2jD, 0il j , ikMStopping. Let’s define M ′ as M ′ = min{M, ∑ Da=1 l a}. Then, max{ω(D)} = maxM ′Reconstruction. For D − 1j1ReferencesΩ[i, j, k] = Q ij + max0i ′ i Ω[i′ , j − 1, k − i] (7)Ψ[i, j, k] = argmaxΩ[i ′ , j − 1, k − i] (8)i ′ ,0i ′ iΩ[i, D, M ′ ], m D = maxΩ[i, D, M ′ ], k D =0il D i,0il Dm j = Ψ[m j+1 , j + 1, k j+1 ], k j = k j+1 − m j+1 (9)[1] L. Huang, D. Chiang, Better k-best Parsing, Proceedings <strong>of</strong> <strong>the</strong> 9th International Workshop on Parsing Technologies,2005.[2] D. Brown, D. Golod, Decoding HMMs Using <strong>the</strong> k Best Paths: Algorithms and Applications, APBC, 2010.[3] W. Powell, Approximate Dynamic Programming: Solving <strong>the</strong> Curses <strong>of</strong> Dimensionality, Wiley Series in Probabilityand Statistics, 2007.27

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!