首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >在执行treetagger命令标记-eng时出错

在执行treetagger命令标记-eng时出错
EN

Stack Overflow用户
提问于 2014-03-21 16:22:56
回答 1查看 896关注 0票数 0

我正在用java做一个使用treetagger.的应用程序,所以在eclipse上点击了这个

代码语言:javascript
复制
String commande="cmd /c  C:\Program Files (x86)\tree-tagger-windows-3.2\TreeTagger\bin\\tag-english"+" "+path;

 Process p=Runtime.getRuntime().exec(commande);

但这不管用。

我对TreeTagger不太了解,我要测试是否在windows下安装TreeTagger,我在命令提示符cd C: \ Program Files (x86) \ tree-tagger-windows-3.2 \ TreeTagger \ bin上输入了这些命令,然后

tag-English nom_de_fichier_à_tagger,但cmd显示此错误消息'perl' is not recognized as an internal or external command, executable program or batch file.

我安装的TreeTagger是我提取到一个文件夹的压缩文件,我把它放在C: \ Program Files (x86)中就是我所做的。

如果我在安装过程中犯了错误,你能帮我吗?因为我也在网上搜索,我什么也不懂。

EN

回答 1

Stack Overflow用户

发布于 2014-03-22 03:10:41

听起来你需要在windows上安装一个perl。我建议你使用Strawberry Perl

我没有使用TreeTagger的经验,但是在谷歌上搜索一下这个引用:TreeTagger - a language independent part-of-speech tagger。向下滚动有一个zip形式的Windows版本,其中包含一个INSTALL.txt,它声明:

代码语言:javascript
复制
Installation
------------

1. Install a Perl interpreter (if you have not already installed one).
   You can download a Perl interpreter for Windows for free at
   http://www.activestate.com/activeperl/

2. Move the TreeTagger directory to the root directory of drive C:.

3. Download the PC parameter files for the languages you need, decompress
   them (e.g. using Winzip or 7zip) and move them to the subdirectory lib.
   Rename the parameter files to <language>.par
   Example: Rename french-par-linux-3.1.bin to french.par

   The UTF8 versions of the parameter files are not supported yet, but
   see below some hints on how to build tagging scripts for the UTF8
   parameter files.

4. Add the path C:\TreeTagger\bin to the PATH environment variable.

5. Open a shell and type the command
   set PATH=C:\TreeTagger\bin;%PATH%

6. Change to the directory C:\TreeTagger

7. Now you can test the tagger, e.g. by analyzing this file with the command
   tag-english INSTALL.txt

显然您已经跳过了步骤1. :),您可以像他们建议的那样使用ActiveState,但是在我看来,草莓perl是一个更好的选择。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/22564136

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档