Skip to content

Commit

Permalink
tmp save
Browse files Browse the repository at this point in the history
  • Loading branch information
Sanhaoji2 committed Nov 27, 2024
1 parent 09dda84 commit ebcf946
Show file tree
Hide file tree
Showing 4 changed files with 167 additions and 215 deletions.
12 changes: 6 additions & 6 deletions include/index.h
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ template <typename T, typename TagT = uint32_t, typename LabelT = uint32_t> clas
DISKANN_DLLEXPORT void load(AlignedFileReader &reader, uint32_t num_threads, uint32_t search_l);
#else
// Reads the number of frozen points from graph's metadata file section.
DISKANN_DLLEXPORT static size_t get_graph_num_frozen_points(const std::string &graph_file);
// DISKANN_DLLEXPORT static size_t get_graph_num_frozen_points(const std::string &graph_file);

DISKANN_DLLEXPORT void load(const char *index_file, uint32_t num_threads, uint32_t search_l);
#endif
Expand Down Expand Up @@ -291,7 +291,7 @@ template <typename T, typename TagT = uint32_t, typename LabelT = uint32_t> clas

// repositions frozen points to the end of _data - if they have been moved
// during deletion
DISKANN_DLLEXPORT void reposition_frozen_point_to_end();
// DISKANN_DLLEXPORT void reposition_frozen_point_to_end();
DISKANN_DLLEXPORT void reposition_points(uint32_t old_location_start, uint32_t new_location_start,
uint32_t num_locations);

Expand Down Expand Up @@ -358,7 +358,7 @@ template <typename T, typename TagT = uint32_t, typename LabelT = uint32_t> clas

// generates 1 frozen point that will never be deleted from the graph
// This is not visible to the user
void generate_frozen_point();
// void generate_frozen_point();

// determines navigating node of the graph by calculating medoid of datafopt
uint32_t calculate_entry_point();
Expand Down Expand Up @@ -423,7 +423,7 @@ template <typename T, typename TagT = uint32_t, typename LabelT = uint32_t> clas
// graph, mode = _consolidated_order in case of lazy deletion and
// _compacted_order in case of eager deletion
DISKANN_DLLEXPORT void compact_data();
DISKANN_DLLEXPORT void compact_frozen_point();
// DISKANN_DLLEXPORT void compact_frozen_point();

// Remove deleted nodes from adjacency list of node loc
// Replace removed neighbors with second order neighbors.
Expand Down Expand Up @@ -476,8 +476,8 @@ template <typename T, typename TagT = uint32_t, typename LabelT = uint32_t> clas
// externally and won't be returned by search. At least 1 frozen point is
// needed for a dynamic index. The frozen points have consecutive locations.
// See also _start below.
size_t _num_frozen_pts = 0;
size_t _frozen_pts_used = 0;
// size_t _num_frozen_pts = 0;
// size_t _frozen_pts_used = 0;
size_t _node_size;
size_t _data_len;
size_t _neighbor_len;
Expand Down
2 changes: 1 addition & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ else()
linux_aligned_file_reader.cpp math_utils.cpp natural_number_map.cpp
in_mem_data_store.cpp in_mem_graph_store.cpp
natural_number_set.cpp memory_mapper.cpp partition.cpp pq.cpp
pq_flash_index.cpp scratch.cpp logger.cpp utils.cpp filter_utils.cpp index_factory.cpp abstract_index.cpp pq_l2_distance.cpp pq_data_store.cpp)
pq_flash_index.cpp scratch.cpp logger.cpp utils.cpp filter_utils.cpp index_factory.cpp abstract_index.cpp pq_l2_distance.cpp pq_data_store.cpp neighbor_list.cpp in_mem_static_graph_store.cpp)
if (RESTAPI)
list(APPEND CPP_SOURCES restapi/search_wrapper.cpp restapi/server.cpp)
endif()
Expand Down
2 changes: 1 addition & 1 deletion src/dll/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
add_library(${PROJECT_NAME} SHARED dllmain.cpp ../abstract_data_store.cpp ../partition.cpp ../pq.cpp ../pq_flash_index.cpp ../logger.cpp ../utils.cpp
../windows_aligned_file_reader.cpp ../distance.cpp ../pq_l2_distance.cpp ../memory_mapper.cpp ../index.cpp
../in_mem_data_store.cpp ../pq_data_store.cpp ../in_mem_graph_store.cpp ../math_utils.cpp ../disk_utils.cpp ../filter_utils.cpp
../ann_exception.cpp ../natural_number_set.cpp ../natural_number_map.cpp ../scratch.cpp ../index_factory.cpp ../abstract_index.cpp)
../ann_exception.cpp ../natural_number_set.cpp ../natural_number_map.cpp ../scratch.cpp ../index_factory.cpp ../abstract_index.cpp ../neighbor_list.cpp ../in_mem_static_graph_store.cpp)

set(TARGET_DIR "$<$<CONFIG:Debug>:${CMAKE_LIBRARY_OUTPUT_DIRECTORY_DEBUG}>$<$<CONFIG:Release>:${CMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE}>")

Expand Down
Loading

0 comments on commit ebcf946

Please sign in to comment.