cpqkeys

CPQ Keys is a framework for evaluating canonization algorithms

https://github.com/roanh/cpqkeys

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (14.3%) to scientific vocabulary

Keywords

canonization cpq graph
Last synced: 6 months ago · JSON representation ·

Repository

CPQ Keys is a framework for evaluating canonization algorithms

Basic Info
  • Host: GitHub
  • Owner: RoanH
  • License: gpl-3.0
  • Language: Java
  • Default Branch: master
  • Homepage: https://cpqkeys.roanh.dev
  • Size: 628 KB
Statistics
  • Stars: 1
  • Watchers: 2
  • Forks: 0
  • Open Issues: 0
  • Releases: 1
Topics
canonization cpq graph
Created over 3 years ago · Last pushed about 3 years ago
Metadata Files
Readme Funding License Citation

README.md

CPQ Keys

CPQ Keys is a project that aims to compare existing graph canonization algorithms on their suitability to canonize query graphs of conjunctive path queries (CPQ). This repository aims to provide a framework based on gMark that can be used to easily evaluate and compare various canonization algorithms. More details about the project and codebase can be found in my technical report titled CPQ Keys: a survey of graph canonization algorithms. A list of canonization algorithms set up for evaluation in this repository is given below, information for adding your own algorithms is in a section near the end of this readme.

  • Bliss (v0.77, released 2021-02-18)
  • Nauty (v2.7 from 2.7r4, released 2022-07-01)
  • Nishe (36b97d3, released 2010-07-20)
  • Scott (01d26aa, released 2020-05-10)
  • Traces (v2.2 from 2.7r4, released 2022-07-01)

Getting Started

Running the project can be done either by using docker or by compiling the project from source. Here docker is primarily provided to offer an easy way to run the project without having to worry about any dependencies. Configuring the settings used to run the evaluation should be done by changing the constants in the main class.

Docker

The repository contains a docker configuration that can be used to build an image and run it. The docker image can be built be running the following command:

sh docker build -t cpqkeys .

You can then run the created image as follows:

sh docker run --rm cpqkeys

From Source

At the moment running the project is only supported on Linux. Docker can be used to run the project on other operating systems. To compile and run the project from source it is first required to install various dependencies. The following dependencies are required:

  • Java 8 or higher: required to run the framework, make sure to install the JDK and not only a JRE.
  • CMake: required to compile Bliss, Nauty, Nishe, and Traces.
  • A compiler for C: e.g. gcc is required to compile Nauty and Traces.
  • A compiler for C++: e.g. g++ is required to compile Bliss and Nishe.
  • Python: python 3 is required to run Scott.

On a system with apt the following command can be used to install all dependencies:

sh apt install default-jdk cmake g++ gcc python3

After installing all the dependencies the JNI natives for the project can be compiled and installed by going into the CPQKeys folder and running the following script:

sh ./compileNatives.sh

Finally, the project as a whole can be compiled and executed using Gradle by running the following command:

sh ./gradlew run

Development

This repository contain an Eclipse & Gradle project with gMark as the only dependency. Development work can be done using the Eclipse IDE or using any other Gradle compatible IDE. A hosted version of the javadoc for this repository can be found at cpqkeys.docs.roanh.dev and the javadoc for gMark can be found at gmark.docs.roanh.dev. Both documentation pages should be useful when implementing your own algorithms. For compiling and running the project refer to the section on compiling from source.

Adding Algorithms

Adding an algorithm to be evaluated is a fairly straightforward process and essentially comes down to implementing the Algorithm interface and adding it to the list of algorithms in the main class. For more information refer to the technical report or one of the existing algorithm implementations. An example template is also given below. Feel free to submit pull requests to add more algorithms to this repository.

```java public class MyAlgorithm{ /** * Algorithm instance, using static instances makes it easier * to have multiple variants of the same algorithm (e.g., see nauty). */ public static final Algorithm INSTANCE = new Algorithm("MyAlgorithm", MyAlgorithm::computeCanon);

/**
 * Runs the algorithm on the given input graph.
 * @param input The input graph.
 * @return An array of time measurements containing in the first
 *         index the graph transform time, in the second index the
 *         native setup time (graph construction) and in the third
 *         index the canonization time. All times are in nanoseconds.
 */
private static long[] computeCanon(Graph<Vertex, Predicate> input){
    return new long[]{
        0, //setup time in nanoseconds
        0, //native setup in nanoseconds
        0  //canonization time in nanoseconds
    };
}

} ```

History

Project development started: 28th of April, 2022.

Owner

  • Name: Roan Hofland
  • Login: RoanH
  • Kind: user
  • Location: Japan
  • Company: alfa1 / group9 / ASML

I'm just a random programmer ^_^. At the moment I really like osu! and writing programs for it. My favorite programming language is Java. Discord: Roan#5667

Citation (CITATION.cff)

cff-version: 1.2.0
title: CPQ Keys
version: 1.0
date-released: 2022-07-17
message: "If you use this software, please cite it using the metadata from this file."
type: software
authors:
  - given-names: Roan
    family-names: Hofland
    email: roan@roanh.dev
contact:
  - given-names: Roan
    family-names: Hofland
    email: roan@roanh.dev
    website: 'https://roanh.dev'
repository-code: 'https://github.com/RoanH/CPQKeys'
abstract: "CPQ Keys is a framework for evaluating canonization algorithms"
license: GPL-3.0-or-later
year-original: 2022
references:
  - title: "CPQ Keys: a survey of graph canonization algorithms"
    authors:
    - given-names: Roan
      family-names: Hofland
      affiliation: "Eindhoven University of Technology"
      email: r.w.p.hofland@student.tue.nl
    type: report
    url: 'https://research.roanh.dev/cpqkeys/CPQ%20Keys%20v1.1.pdf'
    date-published: 2022-07-17
    department: "Department of Mathematics and Computer Science"
    institution:
      name: "Eindhoven University of Technology"
  - title: "Conjunctive Path Query Generation for Benchmarking"
    authors:
    - given-names: Roan
      family-names: Hofland
      affiliation: "Eindhoven University of Technology"
      email: r.w.p.hofland@student.tue.nl
    type: report
    url: 'https://research.roanh.dev/Conjunctive%20Path%20Query%20Generation%20for%20Benchmarking%20v2.8.pdf'
    date-published: 2022-03-21
    department: "Department of Mathematics and Computer Science"
    institution:
      name: "Eindhoven University of Technology"
  - title: "Language-aware Indexing for Conjunctive Path Queries"
    authors:
    - family-names: Sasaki
      given-names: Yuya
      affiliation: "Osaka University"
    - family-names: H. L. Fletcher
      given-names: George
      affiliation: "Eindhoven University of Technology"
    - family-names: Onizuka
      given-names: Makoto
      affiliation: "Osaka University"
    type: article
    url: 'https://arxiv.org/abs/2003.03079'
    year: 2022

GitHub Events

Total
Last Year

Dependencies

CPQKeys/build.gradle maven
  • dev.roanh.gmark:gmark 1.1 implementation
Dockerfile docker
  • openjdk 8 build