Hi Armin, die XWriter uses the default UIMA XMI and XCAS serializers. These are meant to persist a complete CAS. I had a brief look at them and it seems that they are not meant to work on a single view (there are several calls to getBaseCas() in them). However, we could easily add an option to write only selected views in the uimaFIT CasDumpWriter.
Cheers, -- Richard Am 22.12.2011 um 13:40 schrieb [email protected]: > Hi Torsten, > > I got the idea. The easiest way would be to use > org.uimafit.component.xwriter.XWriter as a kind of visualizer. But that does > not work. XWriter does always write the whole CAS instead of the mapped view. > I tried > > CollectionReaderDescription reader = CollectionReaderFactory... > AggregateBuilder builder = new AggregateBuilder(); > AnalysisEngineDescription writer = > AnalysisEngineFactory.createPrimitiveDescription(XWriter.class, > XWriter.PARAM_OUTPUT_DIRECTORY_NAME, outputDirectoryName); > builder.add(writer, CAS.NAME_DEFAULT_SOFA, "viewName"); // viewName is the > name of the view that should be serialized > SimplePipeline.runPipeline(reader, builder.createAggregateDescription()); > > Regards, > > Armin -- ------------------------------------------------------------------- Richard Eckart de Castilho Technical Lead Ubiquitous Knowledge Processing Lab (UKP-TUD) FB 20 Computer Science Department Technische Universität Darmstadt Hochschulstr. 10, D-64289 Darmstadt, Germany phone [+49] (0)6151 16-7477, fax -5455, room S2/02/B117 [email protected] www.ukp.tu-darmstadt.de Web Research at TU Darmstadt (WeRC) www.werc.tu-darmstadt.de -------------------------------------------------------------------
