GithubHelp home page GithubHelp logo

Comments (11)

KiddoZhu avatar KiddoZhu commented on May 13, 2024

For the yaml format, please refer to the document page.

The pickled object is a dict that contains all embeddings, and their index mappings to the original node names. The following lines may help you understand what is in the pickled object.

with open("line_blogcatalog.pkl", "rb") as fin:
    blogcatalog = pickle.load(fin)
print(blogcatalog.keys())

names = blogcatalog.id2name
embeddings = blogcatalog.vertex_embeddings
print(names[1024], embddings[1024])

from graphvite.

PJthunder avatar PJthunder commented on May 13, 2024

Thank you for your prompt reply. The document is helpful but a little bit confusing to me. So if I want to specify a edge_link file to run. I need to create a single yaml file and change the global yaml file to indicate the dataset path? Also, I am not pretty sure which data format is acceptable for your project.

This information may be stored somewhere in the document. An easy start point in the readme file may still be very helpful for people who only want to calculate the embedding in a short run.

from graphvite.

KiddoZhu avatar KiddoZhu commented on May 13, 2024

The dataset path in the global yaml file is for downloading/caching standard datasets. You don't necessarily need to modify it in most cases.

To run your own dataset,

  • Fork an existing yaml.
  • Change dataset paths in graph, evaluation. It's better to use absolute paths.
  • Change hyperparameters if necessary.

For all applications, the dataset format is strings separated by delimiters. There can be some comment at the end of each line. By default, delimiters are any blank characters, and comment prefix is "#". For node embeddings, the following examples are valid.

  • # this is a comment line
  • xxx yyy 1.5 # some comment
  • xxx yyy # some comment

The edge weight is optional.

If you're using Python, you can also pass list of (string, string, float) to the interface.

Sorry for not clarifying the data formats. We will add documentation of dataset format.

from graphvite.

PJthunder avatar PJthunder commented on May 13, 2024

Thanks for your explanation!
Looks like I just need to provide a common edge list to it.
I have opened another issue about the evaluation file format. I hope it will be easy for you to add a simple documents for that one as well.

from graphvite.

kalufinnle avatar kalufinnle commented on May 13, 2024

I also found it a bit confusing of what the desired dataset format should be. Could you add some simple examples in the readme file. Or maybe tutorials on how we can run the codes on our own data? Thank you

from graphvite.

PJthunder avatar PJthunder commented on May 13, 2024

sorry to brother you again. But I don't know what's the input format for LargeViz? I know it should be vectors for nodes, but do not know exactly how the vector should be formatted.

from graphvite.

KiddoZhu avatar KiddoZhu commented on May 13, 2024

That's good. I will add it to the document.

If you call LargeVis from yaml, there are two formats, depending on the task. For graph visualization, it's an edge list. For vector visualization, it's an n*d text matrix, i.e. n lines of d-dimensional samples.

The command line graphvite visualize is only designed for vector visualization, but you can also pass a numpy dump of n*d matrix as input, with .npy suffix.

from graphvite.

PJthunder avatar PJthunder commented on May 13, 2024

Thank you for the quick reply!

from graphvite.

PJthunder avatar PJthunder commented on May 13, 2024

Want to double check. The label file for largevis is just an array (length = n) of string or integer right?

from graphvite.

KiddoZhu avatar KiddoZhu commented on May 13, 2024

Yes. It can be either n lines of strings (*.txt) or a 1d numpy array (*.npy).

from graphvite.

KiddoZhu avatar KiddoZhu commented on May 13, 2024

Added in v0.2.0

from graphvite.

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.