The database will be converted if the legacy database template file emuTplPath could 
be found and successfully loaded and parsed. The legacy template file usually has the extension '.tpl'. 
The UUID of the new emuDB will be randomly generated by default. If targetDir does not exist, 
the directory and its parents will be created. A new directory with the name of the database and the 
suffix '_emuDB' will be created in the targetDir. If the new database directory exists 
already, the function stops with an error. The template file is converted to a JSON file.
Some of the flags of the legacy EMU template files are ignored (lines with this syntax: "set [flagName] [flagValue]", 
known ignored flag names are: 'LabelTracks', 'SpectrogramWhiteLevel', 'HierarchyViewLevels', 'SignalViewLevels'). 
Legacy EMU utterances are reorganized to sessions and bundles. The naming of the sessions depends on the wildcard 
path pattern of the primary track: If the path contains no wildcard, only one session with the name '0000' will be created. 
If the path contains one wildcard path element, the names of the directories matching the pattern will be used as session names. 
If the path contains more than one wildcard path element, the session name is the concatenation of directory names 
separated by an underscore character.
Media files (usually WAV files) are copied, SSFF track files are rewritten using the ASSP library of package
wrassp by default (see option rewriteSSFFTracks below, see also read.AsspDataObj 
write.AsspDataObj). Annotations in EMU hierarchy (.hlb) files and ESPS label files are 
converted to one JSON file per bundle (utterance). Only those files get copied, which match the scheme 
of the template file. Additional files in the legacy database directories are ignored. The legacy EMU 
database will not be modified. For more information on the structural elements of an emuDB see vignette{emuDB}.
options is a list of key value pairs: