Skip to content

Commit

Permalink
Cost-matrix almost right, but not quite, fails due to forced test fai…
Browse files Browse the repository at this point in the history
…lure
  • Loading branch information
JosephBond committed Oct 2, 2023
1 parent b367935 commit abed919
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fluid/example/dtw/cost-matrix.fld
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
let abs x y = if x - y < 0 then negate (x - y) else (x - y);

costMatrixInit rows cols window =
let ns = [0 .. rows];
ms = [0 .. cols]
in
[| let initV = if ((abs n m )<= window) then FNum (abs n m) else Infty in initV | (n, m) in (rows, cols) |]
[| let initV = if ((abs n m )<= window) then FNum 0 else Infty
in initV | (n, m) in (rows, cols) |]
in costMatrixInit 3 4 1

0 comments on commit abed919

Please sign in to comment.