Giter Site home page Giter Site logo

Comments (3)

palash1992 avatar palash1992 commented on May 28, 2024

To compile the graph factorization code, you need the command "bjam toolset=gcc cxxflags="-std=c++11"". I didn't need to rename the Jamfile but if renaming worked for you, it's fine. You can write one line in "graphFacLoad.py", "import graphFace_ext" and the above bjam command would verify if it can be imported from Python. Also, did you place the graphFac_ext.so in the c_ext folder where GEM is installed? Otherwise it will use the file already in the folder which was compiled on my PC.

Yes, the current implementation of HOPE is for small networks as scipy doesn't support GSVD as of now. For large networks, you can use MATLAB's gsvd implementation to get the embedding and GEM's functions to evaluate it. I am planning to implement a memory efficient version of HOPE in Python but it might take a bit of time.

from gem.

jeetu-raj avatar jeetu-raj commented on May 28, 2024

I created a graphFacLoad.py which just had import graphFac_ext . I got the following error while compiling.
image

I commented the line in Jamfile again and was able to compile the code. To test whether I am able to include graphFac_ext I simply tried to run "python graphFacLoad.py"

I got the following error on doing this , Can you please take a look into the issue.
graphFac_ext.so: undefined symbol: _ZNK5boost6python7objects21py_function_impl_base9max_arityEv

Thanks

from gem.

palash1992 avatar palash1992 commented on May 28, 2024

Can you check to see if you are able to compile a sample program using boost and use it in Python (for e.g., hello world)? I believe your Boost is not configured properly and thus you are getting this error. You can checkout this link to see if it helps, https://stackoverflow.com/questions/1780003/import-error-on-boost-python-hello-program.
Alternatively, if you cannot get Boost to work, you can avoid using Boost and pass the arguments as command line arguments to the C++ file (comment out the boost part and add main function) and use system call from Python to call the C++ executable.

from gem.

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.