Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

执行from pyhanlp import * 报错”A fatal error has been detected by the Java Runtime Environment:“ #1236

Closed
1 task done
ferrior30 opened this issue Jul 9, 2019 · 3 comments
Labels

Comments

@ferrior30
Copy link

ferrior30 commented Jul 9, 2019

注意事项

请确认下列注意事项:

  • 我已仔细阅读下列文档,都没有找到答案:
  • 我已经通过Googleissue区检索功能搜索了我的问题,也没有找到答案。
  • 我明白开源社区是出于兴趣爱好聚集起来的自由社区,不承担任何责任或义务。我会礼貌发言,向每一个帮助我的人表示感谢。
  • 我在此括号内输入x打钩,代表上述事项确认完毕。

版本号

当前最新版本号是:hanlp-1.7.4
我使用的版本是:hanlp-1.7.4

执行 :from pyhanlp import * “ 导入pyhanlp时报错

我的问题

Python 3.6.3 |Anaconda, Inc.| (default, Oct 6 2017, 12:04:38)
[GCC 4.2.1 Compatible Clang 4.0.1 (tags/RELEASE_401/final)] on darwin
Type "help", "copyright", "credits" or "license" for more information.

from pyhanlp import *

复现问题

步骤

  1. 首先 在mac的终端Terminater输入”python3“
  2. 然后执行”from pyhanlp import *“

触发代码

  from phhanlp import *

期望输出

程序正常执行,无错误提示

实际输出

A fatal error has been detected by the Java Runtime Environment:

SIGSEGV (0xb) at pc=0x00000001124355c0, pid=20972, tid=775

JRE version: Java(TM) SE Runtime Environment (7.0_79-b15) (build 1.7.0_79-b15)

Java VM: Java HotSpot(TM) 64-Bit Server VM (24.79-b02 mixed mode bsd-amd64 compressed oops)

Problematic frame:

V [libjvm.dylib+0x30f5c0] jni_invoke_nonstatic(JNIEnv_, JavaValue, _jobject*, JNICallType, _jmethodID*, JNI_ArgumentPusher*, Thread*)+0x1b

Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again

An error report file with more information is saved as:

/Users/www/hs_err_pid20972.log

实际输出

其他信息

image

@hankcs
Copy link
Owner

hankcs commented Jul 9, 2019

应该是jpype不兼容,试试pip3 install pyhanlp==0.1.48

@hankcs hankcs added the bug label Jul 9, 2019
@dabao0903
Copy link

python3.6有问题,更新到3.7就正常使用了

@hankcs
Copy link
Owner

hankcs commented Jan 1, 2020

感谢您对HanLP1.x的支持,我一直为没有时间回复所有issue感到抱歉,希望您提的问题已经解决。或者,您可以从《自然语言处理入门》中找到答案。

时光飞逝,HanLP1.x感谢您的一路相伴。我于东部标准时间2019年12月31日发布了HanLP1.x在上一个十年最后一个版本,代号为最后的武士。此后1.x分支将提供稳定性维护,但不是未来开发的焦点。

值此2020新年之际,我很高兴地宣布,HanLP2.0发布了。HanLP2.0的愿景是下一个十年的前沿NLP技术。为此,HanLP2.0采用TensorFlow2.0实现了最前沿的深度学习模型,通过精心设计的框架支撑下游NLP任务,在海量语料库上取得了最前沿的准确率。作为第一个alpha版本,HanLP 2.0.0a0支持分词、词性标注、命名实体识别、依存句法分析、语义依存分析以及文本分类。而且,这些功能并不仅限中文,而是面向全人类语种设计。HanLP2.0提供许多预训练模型,而终端用户仅需两行代码即可部署,深度学习落地不再困难。更多详情,欢迎观看HanLP2.0的介绍视频,或参与论坛讨论

展望未来,HanLP2.0将集成1.x时代继承下来的高效率务实风范,同时冲刺前沿研究,做工业界和学术界的两栖战舰,请诸君继续多多指教,谢谢。

@hankcs hankcs closed this as completed Jan 1, 2020
@hankcs hankcs added ignored and removed bug labels Jan 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants