AntonisZks / Information-Systems-Software-Development-Project

A university project implementing Vamana-Indexing-Algorithm (VIA) for Approximate-Nearest-Neighbors (ANN) problem.
2 stars 0 forks source link

Convert Vamana to a class #55

Open AntonisZks opened 1 day ago

AntonisZks commented 1 day ago

I suggest we convert our Vamana Index to a class. Since the whole idea of the Vamana is actually a modified graph data structure, I believe that building a suitable class for the Vamana would be a great idea, and will help us later on.

Further more I've been thinking about some extra functionalities about the Vamana that can be implemented inside the class above, which are:

The class should be something like the following:

template <typename vamana_t>
class VamanaIndex{
private:
  Graph<vamana_t> graph; // The graph index of the vamana

public:
  ...
  void createGraph(void) {
    // Here the graph of the vamana is being created.
    // We follow the algorithm we already have.
  }

  void saveGraph(const std::string& filepath) {
    // Here we are saving the graph data to a file.
  }

  void loadGraph(const std::string& filepath) {
    // Here we are loading a graph from a file and construct it.
    this->graph = ...
  }
};

Of course these are some examples of what we can do with the Vamana and make our work more convenient and easy. I can work on that but feel free to write down any other suggestion you come across.

StavrosJKw commented 4 hours ago

Excellent suggestion @AntonisZks! this implementation responds to several of the needs we might come across in the development of pt2 of the Project.