packages feed

crf-chain1-constrained 0.3.1 → 0.3.2

raw patch · 2 files changed

+4/−4 lines, 2 filesdep ~logfloatPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

Dependency ranges changed: logfloat

API changes (from Hackage documentation)

- Data.CRF.Chain1.Constrained.Dataset.Internal: instance (Unbox a, Binary a) => Binary (AVec a)
+ Data.CRF.Chain1.Constrained.Dataset.Internal: instance (Binary a, Unbox a) => Binary (AVec a)

Files

crf-chain1-constrained.cabal view
@@ -1,5 +1,5 @@ name:               crf-chain1-constrained-version:            0.3.1+version:            0.3.2 synopsis:           First-order, constrained, linear-chain conditional random fields description:     The library provides efficient implementation of the first-order,@@ -42,7 +42,7 @@       , array       , random       , parallel-      , logfloat+      , logfloat            >= 0.12.1   && < 0.14       , monad-codec         >= 0.2      && < 0.3       , binary       , vector-binary
src/Data/CRF/Chain1/Constrained/Model.hs view
@@ -39,6 +39,7 @@ import qualified Data.CRF.Chain1.Constrained.Dataset.Internal as A  -- | A feature index.  To every model feature a unique index is assigned.+-- It is equall to -1 if there is no corresponding feature in the model. newtype FeatIx = FeatIx { unFeatIx :: Int }     deriving ( Show, Eq, Ord, Binary ) derivingUnbox "FeatIx" [t| FeatIx -> Int |] [| unFeatIx |] [| FeatIx |]@@ -204,8 +205,7 @@ sgValue :: Model -> Lb -> L.LogFloat sgValue crf (Lb x) =      case unFeatIx (sgIxsV crf U.! x) of-        -- TODO: Is the value correct?-        -1 -> L.logToLogFloat (0 :: Float)+        -1 -> L.logToLogFloat (0 :: Double)         ix -> L.logToLogFloat (values crf U.! ix)  -- | List of labels which can be located on the first position of