public static GISModel train ( File inFile , int iterations , int cut , EndOfSentenceScanner scanner ) throws IOException { EventStream es ; DataStream ds ; Reader reader ; reader = new BufferedReader ( new FileReader ( inFile ) ) ; ds = new PlainTextByLineDataStream ( reader ) ; es = new SDEventStream ( ds , scanner ) ; return GIS . trainModel ( es , iterations , cut ) ; }
Use this training method if you wish to supply an end of sentence scanner which provides a different set of ending chars other than the default ones . They are \\ . |!| \\ ?| \\\ | \\ ) .