You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@opennlp.apache.org by "Aliaksandr Autayeu (Commented) (JIRA)" <ji...@apache.org> on 2012/01/22 11:51:39 UTC

[jira] [Commented] (OPENNLP-418) CrossValidator tools argument parser not working with minimun arguments

    [ https://issues.apache.org/jira/browse/OPENNLP-418?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13190644#comment-13190644 ] 

Aliaksandr Autayeu commented on OPENNLP-418:
--------------------------------------------

With the refactoring to stream factories, in some cases it is possible to have all arguments options in an interface. ArgumentParser didn't account for that. Now it allows such cases.
                
> CrossValidator tools argument parser not working with minimun arguments
> -----------------------------------------------------------------------
>
>                 Key: OPENNLP-418
>                 URL: https://issues.apache.org/jira/browse/OPENNLP-418
>             Project: OpenNLP
>          Issue Type: Bug
>          Components: Command Line Interface
>    Affects Versions: tools-1.5.3-incubating
>            Reporter: William Colen
>            Assignee: Aliaksandr Autayeu
>
> The minimun arguments to run a cross validator tool from command line are "lang" and "data", but using only these causes an exception:
> $ bin/opennlp SentenceDetectorCrossValidator -lang pt -data sent.txt
> Exception in thread "main" java.lang.IllegalArgumentException: Passed args must be valid!
> 	at opennlp.tools.cmdline.ArgumentParser.parse(ArgumentParser.java:385)
> 	at opennlp.tools.cmdline.AbstractTrainerTool.run(AbstractTrainerTool.java:46)
> 	at opennlp.tools.cmdline.sentdetect.SentenceDetectorCrossValidatorTool.run(SentenceDetectorCrossValidatorTool.java:49)
> 	at opennlp.tools.cmdline.CLI.main(CLI.java:212)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira