mmsyn7ukr-array-0.2.0.0: A simple reduced basic interface to some SoX functionality or to produce a voice that can be used by mmsyn7h-array, dobutokO2-array and other similar packages
Copyright(c) OleksandrZhabenko 2019-2022
LicenseMIT
Maintainerolexandr543@yahoo.com
StabilityExperimental
Safe HaskellNone
LanguageHaskell2010

Processing_mmsyn7ukr_array

Description

A program and a library that can be used as a simple basic interface to some SoX functionality or for producing the approximately Ukrainian speech with your own recorded voice (actually it produces the needed sound representations).

Synopsis

Producing sound

produceSound2 :: (FilePath, FilePath) -> (String, String) -> String -> IO () Source #

Function produceSound2 is used internally in the produceSound function.

produceSound3 :: (String, String) -> (FilePath, FilePath) -> String -> (Int, Float) -> Float -> IO () Source #

Function produceSound3 is used internally in the produceSound2 function.

produceSound4 :: (FilePath, FilePath) -> FilePath -> IO () Source #

Function produceSound4 is used internally in the produceSound3 function for amplification up/down to the maximum level of the first FilePath parameter in the tuple. The second one gives a name of the resulting file and the third FilePath parameter of the function is the FilePath for the input file.

beginProcessing :: (FilePath, FilePath) -> String -> (String, String) -> IO () Source #

Function beginProcessing is used to catch the variant where the sound is fully cut by the SoX because the sound was created in inappropriate time. It returns the process to the beginning of the sound recording. For the meaning of the tuple of Sring parameters, refer to produceSound documentation. The first FilePath in the tuple of FilePath parameters is a name of the sound file in mmsyn6ukr-array package. The second one is the name of the resulting file to be produced in the current directory.

controlNoiseReduction :: String -> IO () Source #

Function controlNoiseReduction is used in the produceSound2 and beginProcessing functions to reduce the noise with the created by the tempeRa noise profile. If you specified something else than "-1" as a first command line argument, then the program will reduce the noise using the created noise profile. If the first character is one of the following, then the program will do the following actions besides. After the first character (without any spaces) you can specify the level of noise reduction by 2 next digits. They are treated by the program as a fractional part of the number "0." ++ "..." so that the last number is passed to the SoX as an amount parameter in the "noisered" effect (the greater number gives more aggressive noise reduction with the default one equal to 0.5. For more information, please, refer to the SoX documentation.

Additional functions

tempS :: String -> String -> IO (Float, Float, Bool) Source #

Function to get the (Float, Float, Bool) value. The first Float value shows in how many times you expect that your sound representation will be longer than the one provided by the mmsyn6ukr-array package. The second one specifies a duration of the pause before SoX actually starts to record the needed sound data (in seconds). The Bool value specifies whether the program uses a 'sharp' mode meaning that it does not check whether the resulting duration of the recording is at least 3 seconds long, so you can specify shorter durations. The String arguments are the Ukrainian sound representation name and the second command line argument for the program respectively.

showCoef :: String -> String Source #

Function showCoef is used to represent the duration of the sound file.

tempeRa :: Int -> IO () Source #

Function tempeRa is used to create a noise profile for all the recorded sounds. The function is used internally in the mmsyn7ukr program. While running if you provide a 5 seconds silence as needed, the program mmsyn7ukr will reduce the noise in your recordings. This will create a cleaner sound. If you would like not to reduce the noise at all, then, please, specify "-1" as the first command line argument for the program mmsyn7ukr.

recommendSharp :: String -> IO () Source #

Function recommendSharp is used to print an advice about the speech transformation for the Ukrainian sounds that you can pronounce properly continually and so it can be better to use for their producing a 'sharp' mode.

Cleaning

cleanTemp :: IO () Source #

Function cleanTemp removes all the intermediate temporary files in the directory where it is called from.

cleanTempN :: IO () Source #

Function cleanTempN removes all the intermediate temporary files produced during a noise profile creation in the directory where it is called from.