Updated indexes to use l2_normalize functions

This commit is contained in:
Andrew Kane
2024-04-15 13:56:50 -07:00
parent c282627ce5
commit 10dacfd991
4 changed files with 12 additions and 37 deletions

View File

@@ -1,6 +1,8 @@
#ifndef VECTOR_H
#define VECTOR_H
#include "fmgr.h"
#define VECTOR_MAX_DIM 16000
#define VECTOR_SIZE(_dim) (offsetof(Vector, x) + sizeof(float)*(_dim))
@@ -19,5 +21,6 @@ typedef struct Vector
Vector *InitVector(int dim);
void PrintVector(char *msg, Vector * vector);
int vector_cmp_internal(Vector * a, Vector * b);
Datum l2_normalize(PG_FUNCTION_ARGS);
#endif