AbstractModel m = new PerceptronModelReader(new File(args[0])).getModel();
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
DecimalFormat df = new java.text.DecimalFormat(".###");
for (String line = in.readLine(); line != null; line = in.readLine()) {
String[] context = line.split(" ");
double[] dist = m.eval(context);
for (int oi=0;oi<dist.length;oi++) {
System.out.print("["+m.getOutcome(oi)+" "+df.format(dist[oi])+"] ");
}
System.out.println();
}