better warning and error messages in case of dictionary training failure (#292)
This commit is contained in:
+5
-5
@@ -204,11 +204,11 @@ int DiB_trainFromFiles(const char* dictFileName, unsigned maxDictSize,
|
||||
if ((!fileSizes) || (!srcBuffer) || (!dictBuffer)) EXM_THROW(12, "not enough memory for DiB_trainFiles"); /* should not happen */
|
||||
g_displayLevel = params.notificationLevel;
|
||||
if (nbFiles < 5) {
|
||||
DISPLAYLEVEL(2, "! Warning : nb of samples too low for proper processing \n");
|
||||
DISPLAYLEVEL(2, "! Please provide one file per sample \n");
|
||||
DISPLAYLEVEL(2, "! Avoid concatenating multiple samples into a single file \n");
|
||||
DISPLAYLEVEL(2, "! otherwise, dictBuilder will be unable to find the beginning of each sample \n");
|
||||
DISPLAYLEVEL(2, "! resulting in distorted statistics \n");
|
||||
DISPLAYLEVEL(2, "! Warning : nb of samples too low for proper processing ! \n");
|
||||
DISPLAYLEVEL(2, "! Please provide _one file per sample_. \n");
|
||||
DISPLAYLEVEL(2, "! Do not concatenate samples together into a single file, \n");
|
||||
DISPLAYLEVEL(2, "! as dictBuilder will be unable to find the beginning of each sample, \n");
|
||||
DISPLAYLEVEL(2, "! resulting in poor dictionary quality. \n");
|
||||
}
|
||||
|
||||
/* init */
|
||||
|
||||
Reference in New Issue
Block a user