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

README.md is out of date #70

Open
arthurp opened this issue Feb 9, 2021 · 16 comments
Open

README.md is out of date #70

arthurp opened this issue Feb 9, 2021 · 16 comments
Labels
bug Something isn't working documentation Improvements or additions to documentation

Comments

@arthurp
Copy link
Contributor

arthurp commented Feb 9, 2021

README.md needs to be updated for Katana world.

@arthurp arthurp added bug Something isn't working documentation Improvements or additions to documentation labels Feb 9, 2021
@narendrachaudhary51
Copy link

Hi @arthurp. When the README will be updated. I am having some installation difficulties. I get the following error during cmake. I also got the version error before but I was able to fix it.

Could not find a package configuration file provided by "benchmark" with
any of the following names:

benchmarkConfig.cmake
benchmark-config.cmake

Add the installation prefix of "benchmark" to CMAKE_PREFIX_PATH or set
"benchmark_DIR" to a directory containing one of the above files. If
"benchmark" provides a separate development package or SDK, be sure it has
been installed.

@arthurp
Copy link
Contributor Author

arthurp commented Apr 22, 2021

@narendrachaudhary51 What build environment are you using? Conan or Conda?

@narendrachaudhary51
Copy link

narendrachaudhary51 commented Apr 22, 2021

I got the error during cmake. The following command.
cmake -S $SRC_DIR -B $BUILD_DIR -DCMAKE_BUILD_TYPE=Release

I get this error when I follow python.md and reach to similar cmake command.

katana/scripts/katana_version/version.py", line 188, in get_config_version
with open(repo.dir / CONFIG_VERSION_PATH, "rt") as version_file:
AttributeError: 'NoneType' object has no attribute 'dir'

@arthurp
Copy link
Contributor Author

arthurp commented Apr 22, 2021

Are you building in a git checkout or did you download the source as an archive and just decompress it and build it that way? If the latter there may be a bug in scripts/katana_version that is not handling non-git source trees properly. If so I definitely need to fix that.

@arthurp
Copy link
Contributor Author

arthurp commented Apr 22, 2021

Yes. IT's a bug. I should have just checked before messaging. I'll push a PR soon to fix this. Would you be willing to test and review it?

@narendrachaudhary51
Copy link

I did "git clone https://github.com/KatanaGraph/katana.git" to download the project and after that followed the instructions. I will be happy to test and review the new changes.

arthurp added a commit to arthurp/katana that referenced this issue Apr 22, 2021
@arthurp
Copy link
Contributor Author

arthurp commented Apr 22, 2021

That's weird. If you cloned that way this shouldn't have been an issue. You can look at the PR I created at #174 and see if it fixes things for you. You are external, so I cannot have you formally review it, but I would love you to test it.

I will run some tests to see if I reproduce what you saw. Was your build directory inside or outside the source directory?

@narendrachaudhary51
Copy link

narendrachaudhary51 commented Apr 22, 2021

SRC_DIR=/katana/
BUILD_DIR=/katana/build/
So build directory inside the source directory. The new PR also doesn't seem to work. I get the same error.
Just to confirm, I used: "git clone https://github.com/arthurp/katana.git" for the new PR.

@arthurp
Copy link
Contributor Author

arthurp commented Apr 22, 2021

Just to confirm, I used: "git clone https://github.com/arthurp/katana.git" for the new PR.

That just cloned the master branch on my repo. You will want to clone the branch associated with the PR. To clone a PR see: https://stackoverflow.com/questions/14947789/github-clone-from-pull-request

@narendrachaudhary51
Copy link

I was able to run the following step from python.md file. I cloned the new PR code.
"cmake -S $SRC_DIR -B $BUILD_DIR -DCMAKE_BUILD_TYPE=Release -DKATANA_LANG_BINDINGS=python -DBUILD_SHARED_LIBS=ON"

However, I got the version error during the following command.
"conda build -c conda-forge $SRC_DIR/conda_recipe/"

Error - anaconda3/lib/python3.8/site-packages/conda/models/version.py", line 164, in init
raise InvalidVersionSpec(vstr, "empty version string")
conda.exceptions.InvalidVersionSpec: Invalid version '': empty version string

@arthurp
Copy link
Contributor Author

arthurp commented Apr 23, 2021

Hmm. I didn't think that would be an issue. For normal builds. I'll look into it.

For the time being, do you actually need to build the conda packages? You can just to a normal build within conda and then use python_env.sh in the build directory to run stuff. I'll get the conda package buil fixed next week. Also there are packages in anaconda if you want to use those: https://anaconda.org/katanagraph

@narendrachaudhary51
Copy link

I want to convert an adjacency matrix based graph into .gr format and then apply louvain and leiden clustering algorithms on it. I can use the C++ binaries to run the louvain and leiden algorithms but I want to use those functions inside my python program. Will I be able to apply these algorithms in python if I use these packages (https://anaconda.org/katanagraph) ? Also, if you can send me a link to a tutorial than that would be great too.

@arthurp
Copy link
Contributor Author

arthurp commented Apr 23, 2021

There is no tutorial yet for this, sadly. Let me work on getting the Python API reference posted for easy reading. What you can already do is install those packages and us pydoc or help to look at the documentation. It's not a tutorial, but there are doc strings on most things.

Currently, graph conversion is not supported from inside Python. You will need to use graph-convert a CLI tool. It's in the katana-tools conda package.

Louvain clustering is not yet wrapped for use from Python. But it should be available soon: #177. I'm not aware of any Leiden clustering support. You might need to implement that yourself. That is possible from Python using the currently available conda packages.

arthurp added a commit that referenced this issue Apr 25, 2021
@narendrachaudhary51
Copy link

narendrachaudhary51 commented Apr 26, 2021

I tried installing these (https://anaconda.org/katanagraph) but got the following error. I try to install in an empty enviroment.
**Found conflicts! Looking for incompatible packages.
This can take several minutes. Press CTRL-C to abort.
failed

UnsatisfiableError:**

I also cannot run python_env.sh.tmp as I get premission denied error. I don't have python_env.sh in the build folder. I also get the version error when I try to run "make -j" in the build directory (after cmake -S $SRC_DIR -B $BUILD_DIR -DCMAKE_BUILD_TYPE=Release -DKATANA_LANG_BINDINGS=python -DBUILD_SHARED_LIBS=ON).

Do you know a way to do the following? What process do you guys follow?
"You might need to implement that yourself. That is possible from Python using the currently available conda packages."
The existing leiden and louvain clustering algorithms from other python packages are extremely slow. That is why I wanted to use katana graph.

It seems leiden clustering was present in the previous version (git clone https://github.com/IntelligentSoftwareSystems/Galois). Did you remove it in the current version?

@arthurp
Copy link
Contributor Author

arthurp commented Apr 26, 2021

**Found conflicts! Looking for incompatible packages.
This can take several minutes. Press CTRL-C to abort.
failed

UnsatisfiableError:**

Can you create a separate issue for this and provide more details about the environment and a complete error message? I cannot really debug it with what you include here since I have not seen this error myself.

I also cannot run python_env.sh.tmp as I get premission denied error. I don't have python_env.sh in the build folder. I also get the version error when I try to run "make -j" in the build directory (after cmake -S $SRC_DIR -B $BUILD_DIR -DCMAKE_BUILD_TYPE=Release -DKATANA_LANG_BINDINGS=python -DBUILD_SHARED_LIBS=ON).

python_env.sh is only created once the python extension modules have actually been built. What version error are you referring too? Can you create a separate issue for this? (Talking about everything here is getting confusing.)

The existing leiden and louvain clustering algorithms from other python packages are extremely slow. That is why I wanted to use katana graph.

When I say "implement from Python" I mean using the special features of KatanaGraph which enable writing Python kernels which are compiled and run within the Katana scheduler. It should be nearly as fast as C. I am working on a tutorial on this, so hopefully I can link you to that soon. In the mean time you can look at this example: https://github.com/KatanaGraph/katana/blob/master/python/katana/lonestar/analytics/jaccard.py

It seems leiden clustering was present in the previous version (git clone https://github.com/IntelligentSoftwareSystems/Galois). Did you remove it in the current version?

I wasn't aware of that. It appears we did have an experimental implementation and that it was removed. I don't know why. Sadly, I don't have the time at the moment to figure out. Please file an issue requesting the algorithm and linking to the existing version in galois (or even better in the the git history of katana). We'll look into it as we have time.

@narendrachaudhary51
Copy link

narendrachaudhary51 commented Apr 27, 2021

I filed a separate issue (#185) for the invalid version error.
Also filed issue for Leiden clustering (#186).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants