package org.algorithm.test;

import org.algorithm.core.cnn.dataset.RelationExtractionDataSet;

/**
 * @Author: bijl
 * @Date: 2019/1/22 13:46
 * @Decription:
 */
public class RelationExtractionDataSetTest {

    public static void main(String[] args) {

        String filePath = "E:\\char2id.json";
        String sentence = "有双手麻木感，活动后好转，颈部及肩部活动度无殊";
        RelationExtractionDataSet dataSet = new RelationExtractionDataSet(filePath);
//        for (float id:dataSet.sentence2ids(sentence)) {
//            System.out.println(id); // pass
//        }
//        for (float id:dataSet.getRelativePositions(sentence, "1,2")) {
//            System.out.println(id); //pass
//        }
        for (float id:dataSet.sentence2ids(sentence)) {
            System.out.println(id);
        }
        System.out.println("...............");

        for (float id:dataSet.getRelativePositions(sentence, "1,2")) {
            System.out.println(id);
        }
    }
}
