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

在 2 to 3 后出现 /usr/local/lib/python3.4/site-packages/tgrocery/learner/util.so.1 #12

Open
iQuick opened this issue Apr 15, 2016 · 9 comments

Comments

@iQuick
Copy link

iQuick commented Apr 15, 2016

在 2 to 3 后出现 /usr/local/lib/python3.4/site-packages/tgrocery/learner/util.so.1

这个是错误怎么解决呢?

@2shou
Copy link
Owner

2shou commented Apr 16, 2016

暂时还不支持Python3,请换用2.7再尝试

@2shou
Copy link
Owner

2shou commented Apr 16, 2016

或者你把2to3之后的源码PR一份给我?

@iQuick
Copy link
Author

iQuick commented Apr 19, 2016

util.so.1 的问题已经解决了,是没有 gcc 的原因,导致没有编译出 .so 文件,不过现在报另外个错误

from tgrocery import Grocery
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python3.4/site-packages/tgrocery/init.py", line 2, in
from .classifier import *
File "/usr/local/lib/python3.4/site-packages/tgrocery/classifier.py", line 6, in
from .learner import *
File "/usr/local/lib/python3.4/site-packages/tgrocery/learner/init.py", line 1, in
from .learner import *
File "/usr/local/lib/python3.4/site-packages/tgrocery/learner/learner.py", line 48, in
class SVMProblem(Structure):
File "/usr/local/lib/python3.4/site-packages/tgrocery/learner/learner.py", line 50, in SVMProblem
_types = [liblinear.problem, POINTER(liblinear.feature_node), c_int64]
AttributeError: 'module' object has no attribute 'problem'
@2shou

@iQuick
Copy link
Author

iQuick commented Apr 19, 2016

2 to 3 的代码是使用 PrashntS 的 https://github.com/PrashntS/TextGrocery

@jammy112
Copy link

jammy112 commented May 9, 2016

我也出现了动态加载库的问题,用的windows环境的分支版本
请问怎么解决呢? @2shou

IDE用的eclipse的pydev,操作系统是win10
测试了一条语句:from tgrocery import Grocery
报错如下:

Traceback (most recent call last):
File "C:\Users\xiaoj\workspace_luna\PythonLearn1\src\Test1__init__.py", line
3, in
from tgrocery import Grocery
File "C:\Users\xiaoj\workspace_luna\PythonLearn1\src\tgrocery__init__.py", li
ne 2, in
from classifier import *
File "C:\Users\xiaoj\workspace_luna\PythonLearn1\src\tgrocery\classifier.py",
line 6, in
from .learner import *
File "C:\Users\xiaoj\workspace_luna\PythonLearn1\src\tgrocery\learner__init__
.py", line 1, in
from .learner import *
File "C:\Users\xiaoj\workspace_luna\PythonLearn1\src\tgrocery\learner\learner.
py", line 21, in
util = CDLL(os.path.join(os.path.dirname(os.path.abspath(file)), 'util.d
ll'))
File "C:\Python27\lib\ctypes__init__.py", line 365, in init
self._handle = _dlopen(self._name, mode)
WindowsError: [Error 126]

@songhao8080
Copy link

Traceback (most recent call last):
File "C:\Users\admin\Desktop\baiwan\TextGrocery\index.py", line 8, in
from tgrocery import Grocery
File "C:\Python27\lib\site-packages\tgrocery__init__.py", line 2, in
from classifier import *
File "C:\Python27\lib\site-packages\tgrocery\classifier.py", line 6, in
from .learner import *
File "C:\Python27\lib\site-packages\tgrocery\learner__init__.py", line 1, in
from .learner import *
File "C:\Python27\lib\site-packages\tgrocery\learner\learner.py", line 21, in
util = CDLL(os.path.join(os.path.dirname(os.path.abspath(file)), 'util.so.1'))
File "C:\Python27\lib\ctypes__init__.py", line 365, in init
self._handle = _dlopen(self._name, mode)
WindowsError: [Error 126]

我也出现这个问题了,怎么解决呢windows7

@mickelfeng
Copy link

windows下还不支持

@cosmichut
Copy link

cosmichut commented Oct 12, 2017

我修订了基于2shou的 PrashntS 的版本(for python3),现在可以支持python3 和 windows平台了。。详情见:
https://github.com/cosmichut/TextGrocery

@iQuick @huahuizi 你们可以试试。

@oliverxing95
Copy link

在 2 to 3 后出现 /usr/local/lib/python3.4/site-packages/tgrocery/learner/util.so.1

这个是错误怎么解决呢?

hi 同样遇到了这个问题,请问是如何解决的呢?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants