mirror of
https://github.com/M66B/FairEmail.git
synced 2025-01-03 13:44:40 +00:00
Added logging
This commit is contained in:
parent
43438e0f21
commit
a59ddba2d5
1 changed files with 6 additions and 2 deletions
|
@ -227,12 +227,16 @@ public class MessageClassifier {
|
||||||
List<Chance> chances = new ArrayList<>();
|
List<Chance> chances = new ArrayList<>();
|
||||||
for (String clazz : classStats.keySet()) {
|
for (String clazz : classStats.keySet()) {
|
||||||
Integer messages = classMessages.get(account).get(clazz);
|
Integer messages = classMessages.get(account).get(clazz);
|
||||||
if (messages == null || messages == 0)
|
if (messages == null || messages == 0) {
|
||||||
|
Log.w("Classifier no messages class=" + account + ":" + clazz);
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
EntityFolder folder = db.folder().getFolderByName(account, clazz);
|
EntityFolder folder = db.folder().getFolderByName(account, clazz);
|
||||||
if (folder == null)
|
if (folder == null) {
|
||||||
|
Log.w("Classifier no folder class=" + account + ":" + clazz);
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
Stat stat = classStats.get(clazz);
|
Stat stat = classStats.get(clazz);
|
||||||
double chance = (double) stat.totalFrequency / messages / maxMatchedWords;
|
double chance = (double) stat.totalFrequency / messages / maxMatchedWords;
|
||||||
|
|
Loading…
Reference in a new issue