packages feed

phonetic-languages-simplified-properties-array 0.5.0.0 → 0.6.0.0

raw patch · 3 files changed

+46/−10 lines, 3 filesdep ~phonetic-languages-rhythmicityPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: phonetic-languages-rhythmicity

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -40,3 +40,9 @@  * Fifth version. Changed the behavior for the new recent properties added so that they are now more linearized. Changed the dependency boundaries for the package phonetic-languages-rhythmicity.++## 0.6.0.0 -- 2021-08-14++* Sixth version. Added new properties lines of "C", "N", "W", "X", "Y", "Z" and updated some previous ones to+use the possibilities of the weighted improtance of lines (just some experimental functions at the moment).+Changed the dependency boundaries of phonetic-languages-rhythmicity.
Phonetic/Languages/Array/Ukrainian/PropertiesSyllablesG2.hs view
@@ -120,7 +120,7 @@ rhythmicityG f g xs  | null xs = 0.0  | otherwise = g . f . createSyllablesUkrS $ xs-{-# INLINE rhythmicityG #-} +{-# INLINE rhythmicityG #-}  ------------------------------------------------------- @@ -198,7 +198,29 @@  rhythmicity :: Double -> String -> Coeffs2 -> String -> Double rhythmicity k choice CF0 =- case take 1 choice of + case take 1 choice of+  "C" -> let just_probe = readRhythmicity choice in+           case just_probe of+             Just (P1 ch rh 1) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD . createSyllablesUkrS+             Just (P1 ch rh 2) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD2 . createSyllablesUkrS+             Just (P1 ch rh 3) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD3 . createSyllablesUkrS+             Just (P1 ch rh 4) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD4 . createSyllablesUkrS+             Just (P2 ch rh r 1) -> rhythmicityPolyWeightedF2 1.0 r ch rh . mconcat . syllableDurationsD . createSyllablesUkrS+             Just (P2 ch rh r 2) -> rhythmicityPolyWeightedF2 1.0 r ch rh . mconcat . syllableDurationsD2 . createSyllablesUkrS+             Just (P2 ch rh r 3) -> rhythmicityPolyWeightedF2 1.0 r ch rh . mconcat . syllableDurationsD3 . createSyllablesUkrS+             Just (P2 ch rh r 4) -> rhythmicityPolyWeightedF2 1.0 r ch rh . mconcat . syllableDurationsD4 . createSyllablesUkrS+             _ -> rhythmicity04+  "N" -> let just_probe = readRhythmicity choice in+           case just_probe of+             Just (P1 ch rh 1) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD . createSyllablesUkrS+             Just (P1 ch rh 2) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD2 . createSyllablesUkrS+             Just (P1 ch rh 3) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD3 . createSyllablesUkrS+             Just (P1 ch rh 4) -> rhythmicityABC 1.0 2.0 0.125 ch rh . mconcat . syllableDurationsD4 . createSyllablesUkrS+             Just (P2 ch rh r 1) -> rhythmicityPolyWeightedF3 1.0 r ch rh . mconcat . syllableDurationsD . createSyllablesUkrS+             Just (P2 ch rh r 2) -> rhythmicityPolyWeightedF3 1.0 r ch rh . mconcat . syllableDurationsD2 . createSyllablesUkrS+             Just (P2 ch rh r 3) -> rhythmicityPolyWeightedF3 1.0 r ch rh . mconcat . syllableDurationsD3 . createSyllablesUkrS+             Just (P2 ch rh r 4) -> rhythmicityPolyWeightedF3 1.0 r ch rh . mconcat . syllableDurationsD4 . createSyllablesUkrS+             _ -> rhythmicity04   "0" -> case choice of           "0y" -> rhythmicity0           "02y" -> rhythmicity02@@ -256,8 +278,16 @@              Just (P2 ch rh r 4) -> rhythmicityPoly 1.0 r ch rh . mconcat . syllableDurationsD4 . createSyllablesUkrS              _ -> rhythmicity04   _ -> if-    | (take 1 choice == "u" || take 1 choice == "v" || take 1 choice == "s" || take 1 choice == "t") && (drop 2 . take 3 $ choice) >= "1" && (drop 2 . take 3 $ choice) <= "4" ->+    | (take 1 choice `elem` ["u","v","s","t","U","V","S","T","W","X","Y","Z"]) && (drop 2 . take 3 $ choice) >= "1" && (drop 2 . take 3 $ choice) <= "4" ->         case take 1 choice of+          "W" -> g rhythmicityPolyWeightedF3 5 1+          "X" -> g rhythmicityPolyWeightedF30 5 1+          "Y" -> g rhythmicityPolyWeightedF3 6 2+          "Z" -> g rhythmicityPolyWeightedF30 6 2+          "U" -> g rhythmicityPolyWeightedF2 5 1+          "V" -> g rhythmicityPolyWeightedF20 5 1+          "S" -> g rhythmicityPolyWeightedF2 6 2+          "T" -> g rhythmicityPolyWeightedF20 6 2           "u" -> g rhythmicityPoly 5 1           "v" -> g rhythmicityPoly0 5 1           "s" -> g rhythmicityPoly 6 2@@ -316,12 +346,12 @@               where x1F f ch rh = rhythmicityABC0 1.0 (fromMaybe 2.0 x) (fromMaybe 0.125 y) ch rh . mconcat . f . createSyllablesUkrS                     xxF xs = let (Just n) = readMaybe xs::Maybe Int in                       case n `rem` 4 of-                       1 -> x1F syllableDurationsD -                       2 -> x1F syllableDurationsD2 -                       3 -> x1F syllableDurationsD3 -                       _ -> x1F syllableDurationsD4 +                       1 -> x1F syllableDurationsD+                       2 -> x1F syllableDurationsD2+                       3 -> x1F syllableDurationsD3+                       _ -> x1F syllableDurationsD4                     {-# INLINE x1F #-}                     {-# INLINE xxF #-}   _ -> if-     | take 1 choice `elem` ["c","u","v","s","t"] -> rhythmicity k choice CF0+     | take 1 choice `elem` ["c","u","v","s","t","C","N","S","T","U","V","W","X","Y","Z"] -> rhythmicity k choice CF0      | otherwise -> rhythmicityK4 (fromMaybe 1.0 x) (fromMaybe 1.0 y)
phonetic-languages-simplified-properties-array.cabal view
@@ -2,7 +2,7 @@ -- For further documentation, see http://haskell.org/cabal/users-guide/  name:                phonetic-languages-simplified-properties-array-version:             0.5.0.0+version:             0.6.0.0 synopsis:            A generalization of the uniqueness-periods-vector-properties package. description:         Is a simplified version of the functionality of the former one. Uses lists and arrays as main processment data types. Uses Double whenever applicable. homepage:            https://hackage.haskell.org/package/phonetic-languages-simplified-properties-array@@ -20,6 +20,6 @@   exposed-modules:     Phonetic.Languages.Array.Ukrainian.PropertiesFuncRepG2, Phonetic.Languages.Array.Ukrainian.PropertiesSyllablesG2   -- other-modules:   other-extensions:    BangPatterns, CPP, MultiWayIf-  build-depends:       base >=4.8 && <4.15, phonetic-languages-rhythmicity >=0.6 && <1, phonetic-languages-simplified-base >=0.1 && <1, ukrainian-phonetics-basic-array >=0.1.2 && <1+  build-depends:       base >=4.8 && <4.15, phonetic-languages-rhythmicity >=0.7 && <1, phonetic-languages-simplified-base >=0.1 && <1, ukrainian-phonetics-basic-array >=0.1.2 && <1   -- hs-source-dirs:   default-language:    Haskell2010