opennlp.maxent.io
Class OldFormatGISModelReader

java.lang.Object
  extended by opennlp.model.AbstractModelReader
      extended by opennlp.maxent.io.GISModelReader
          extended by opennlp.maxent.io.PlainTextGISModelReader
              extended by opennlp.maxent.io.OldFormatGISModelReader

public class OldFormatGISModelReader
extends PlainTextGISModelReader

A reader for GIS models stored in the format used in v1.0 of Maxent. It extends the PlainTextGISModelReader to read in the info and then overrides the getParameters method so that it can appropriately read the binary file which stores the parameters.


Constructor Summary
OldFormatGISModelReader(String modelname)
          Constructor which takes the name of the model without any suffixes, such as ".mei.gz" or ".mep.gz".
 
Method Summary
static void main(String[] args)
          Convert a model created with Maxent 1.0 to a format used with Maxent 1.2.
 
Methods inherited from class opennlp.maxent.io.GISModelReader
checkModelType, constructModel
 
Methods inherited from class opennlp.model.AbstractModelReader
getModel, readDouble, readInt, readUTF
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OldFormatGISModelReader

public OldFormatGISModelReader(String modelname)
                        throws IOException
Constructor which takes the name of the model without any suffixes, such as ".mei.gz" or ".mep.gz".

Throws:
IOException
Method Detail

main

public static void main(String[] args)
                 throws IOException
Convert a model created with Maxent 1.0 to a format used with Maxent 1.2.

Usage: java opennlp.maxent.io.OldFormatGISModelReader model_name_prefix (new_model_name)");

If the new_model_name is left unspecified, the new model will be saved in gzipped, binary format as ".bin.gz".

Throws:
IOException


Copyright © 2013 The Apache Software Foundation. All Rights Reserved.