Module hnsw_rs::hnswio[][src]

Expand description

This file provides io dump/ reload of computed graph.

A dump is constituted of 2 files. One file stores just the graph (or topology) with id of points.
The other file stores the ids and vector in point. The graph file is suffixed by “hnsw.graph” the other is suffixed by “hnsw.data”

An example of dump and reload of structure Hnsw is given in the tests (see test_dump_reload)

Structs

structure describing main parameters for hnsnw data and written at the beginning of a dump file.

Enums

Traits

The main interface for dumping struct Hnsw.

Functions

This method is a preliminary to do a full reload from a dump. The method load_hnsw needs to know the typename , distance used, and construction parameters. So the reload is made in two steps.

The reload is made in two steps. First a call to load_description must be used to get basic information about structure to reload (Typename, distance type, construction parameters).
Cf fn load_description(io_in: &mut dyn Read) -> io::Result