package org.diagbot.common.push.naivebayes;

import org.diagbot.common.push.naivebayes.core.AlgorithmNaiveBayesExecutor;

import java.util.HashMap;
import java.util.Map;

/**
 * @Description:
 * @Author: HUJING
 * @Date: 2019/10/11 14:30
 */
public class NaiveBayesTest {
    public static void main(String[] args) {
        AlgorithmNaiveBayesExecutor a = new AlgorithmNaiveBayesExecutor();
        Map<String, Map<String, String>> inputs = new HashMap<>();
        inputs.put("咽部异物感",new HashMap<>());
//        inputs.put("腹胀",new HashMap<>());
//        inputs.put("乏力",new HashMap<>());
        Map<String, Float> softmax = a.execute(inputs);
        double i = 0.00;
        for (Map.Entry<String, Float> s:softmax.entrySet()) {
            i += s.getValue();
            if (s.getValue() == 0){
                System.out.println(s.getKey());
            }
        }
        System.out.println(i);
    }
}
