Gennaio 20, 2017

VF3: The software

VF3 can be very easily integrated in your application. Indeed, it is provided together with the source code (compatible with Unix, Mac OS X and Windows operating systems) and an executable for Linux operating systems (x86_64 platform).


How to use the source code?

The C++ source code of the algorithm is provided with the related Doxygen documentation, both available by requesting it at the following link. It is important to highlight that the implementation is very general and can be easily integrated with any graphs by only defining a small set of customized functions for:

  • Loading a graph from a file
  • Classifying the attributes (both on nodes and edges)
  • Comparing the attributes, both on nodes and edges
  • Choosing a new ordering criterion for exploring the nodes of the first graph

How to use the executable?

The executable requires two parameters as input and is customized to manage labeled graphs, being the labels integer/character values:

  • Path of the file containing the query graph
  • Path of the file containing the target graph

The format of the files to take as input is defined in the following section.


File format

The format of the file containing the graph is the following:

“number of nodes”
“id_node 0” “label”
“id_node 1” “label”
“id_node 2” “label”

“number of edges”
“id_starting_node 0” “id_ending_node” “label edge”*
“id_starting_node 0” “id_ending_node” “label edge”*

“number of edges”
“id_starting_node 1” “id_ending_node” “label edge”*
“id_starting_node 1” “id_ending_node” “label edge”*

Please note that the label on the edge (identified by “label edge”*) is not mandatory.

ex_graph

For instance, in the above graphs, the format of the file is the following. Suppose that the number inside each node represents the id and there are not any labels. Thus, we can consider the same label for all the nodes of the graphs (1 in the example).

3
1 1
2 1
3 1
1
1 3
1
2 3
1
3 1


License

VF3 is provided under the MIT License (MIT).

Copyright (c) 2015 University of Salerno

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.