Coder Social home page Coder Social logo

ImportError: No module named _emd about wmd HOT 6 OPEN

bwang482 avatar bwang482 commented on August 21, 2024
ImportError: No module named _emd

from wmd.

Comments (6)

serenayj avatar serenayj commented on August 21, 2024 1

I've got the same issue. I traced back to wmd.py, it turned out that the Python.h is not found in emd.h. Someone could help?

from wmd.

2ayan avatar 2ayan commented on August 21, 2024

me too.

wmd> python wmd.py SMERP_only_text.pk SMERP_only_text_wmd.pk
Traceback (most recent call last):
File "wmd.py", line 4, in
from emd import emd
File "python-emd-master/emd.py", line 25, in
_emd = swig_import_helper()
File "python-emd-master/emd.py", line 17, in swig_import_helper
import _emd
ImportError: No module named _emd

from wmd.

YuTingLiu avatar YuTingLiu commented on August 21, 2024

you can use pyemd instead, which gensim using this package too.
pip install pyemd

from wmd.

zimengq avatar zimengq commented on August 21, 2024

you should first build emd in python-master-emd

from wmd.

rebecca-zhang avatar rebecca-zhang commented on August 21, 2024

Has anyone come across a solution to this? When I run build in python-emd-master, I get the error
Linking wrapper library '_emd.so'. -n ld -shared -o _emd.so emd.o emd_wrap.o ld: unknown option: -shared make: *** [_emd.so] Error 1 rm emd_wrap.o emd.o emd_wrap.c
So it looks like emd isn't being built properly

from wmd.

gocen avatar gocen commented on August 21, 2024

I've installed swig and build emd with 'make' command
but it still gives the error

ImportError: No module named _emd

from wmd.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.