Compare commits

...

4 Commits

Author SHA1 Message Date
Andrew Kane
ddd873f369 Version bump to 0.2.2 [skip ci] 2022-01-15 14:23:32 -05:00
Andrew Kane
8735c4782a Fixed compilation on Mac ARM - #22 2022-01-14 01:18:33 -05:00
Andrew Kane
17ec3f3852 Moved test 2022-01-02 19:24:50 -05:00
Andrew Kane
8df12a62e7 Updated changelog [skip ci] 2022-01-02 19:20:00 -05:00
10 changed files with 30 additions and 15 deletions

View File

@@ -1,4 +1,8 @@
## 0.2.1 (unreleased)
## 0.2.2 (2022-01-15)
- Fixed compilation error on Mac ARM
## 0.2.1 (2022-01-02)
- Fixed `operator is not unique` error

View File

@@ -2,7 +2,7 @@
"name": "vector",
"abstract": "Open-source vector similarity search for Postgres",
"description": "Supports L2 distance, inner product, and cosine distance",
"version": "0.2.1",
"version": "0.2.2",
"maintainer": [
"Andrew Kane <andrew@ankane.org>"
],
@@ -20,7 +20,7 @@
"vector": {
"file": "sql/vector.sql",
"docfile": "README.md",
"version": "0.2.1",
"version": "0.2.2",
"abstract": "Open-source vector similarity search for Postgres"
}
},

View File

@@ -1,5 +1,5 @@
EXTENSION = vector
EXTVERSION = 0.2.1
EXTVERSION = 0.2.2
MODULE_big = vector
DATA = $(wildcard sql/*--*.sql)
@@ -11,6 +11,13 @@ REGRESS_OPTS = --inputdir=test
OPTFLAGS = -march=native
# Mac ARM doesn't support -march=native
ifeq ($(shell uname -s), Darwin)
ifeq ($(shell uname -p), arm)
OPTFLAGS =
endif
endif
# For auto-vectorization:
# - GCC (needs -ftree-vectorize OR -O3) - https://gcc.gnu.org/projects/tree-ssa/vectorization.html
# - Clang (could use pragma instead) - https://llvm.org/docs/Vectorizers.html

View File

@@ -17,7 +17,7 @@ Supports L2 distance, inner product, and cosine distance
Compile and install the extension (supports Postgres 9.6+)
```sh
git clone --branch v0.2.1 https://github.com/ankane/pgvector.git
git clone --branch v0.2.2 https://github.com/ankane/pgvector.git
cd pgvector
make
make install # may need sudo
@@ -196,7 +196,7 @@ This adds pgvector to the [Postgres image](https://hub.docker.com/_/postgres).
You can also build the image manually
```sh
git clone --branch v0.2.1 https://github.com/ankane/pgvector.git
git clone --branch v0.2.2 https://github.com/ankane/pgvector.git
cd pgvector
docker build -t pgvector .
```

View File

@@ -0,0 +1,2 @@
-- complain if script is sourced in psql, rather than via CREATE EXTENSION
\echo Use "ALTER EXTENSION vector UPDATE TO '0.2.2'" to load this file. \quit

View File

@@ -42,3 +42,10 @@ SELECT '[1,2,3]'::vector::real[];
SELECT array_agg(n)::vector FROM generate_series(1, 1025) n;
ERROR: vector cannot have more than 1024 dimensions
-- ensure no error
SELECT ARRAY[1,2,3] = ARRAY[1,2,3];
?column?
----------
t
(1 row)

View File

@@ -54,9 +54,3 @@ SELECT cosine_distance('[1,2]', '[0,0]');
SELECT cosine_distance('[1,2]', '[3]');
ERROR: different vector dimensions 2 and 1
SELECT ARRAY[1,2,3] = ARRAY[1,2,3];
?column?
----------
t
(1 row)

View File

@@ -12,3 +12,6 @@ SELECT '{-Infinity}'::real[]::vector;
SELECT '{}'::real[]::vector;
SELECT '[1,2,3]'::vector::real[];
SELECT array_agg(n)::vector FROM generate_series(1, 1025) n;
-- ensure no error
SELECT ARRAY[1,2,3] = ARRAY[1,2,3];

View File

@@ -16,5 +16,3 @@ SELECT inner_product('[1,2]', '[3]');
SELECT round(cosine_distance('[1,2]', '[2,4]')::numeric, 5);
SELECT cosine_distance('[1,2]', '[0,0]');
SELECT cosine_distance('[1,2]', '[3]');
SELECT ARRAY[1,2,3] = ARRAY[1,2,3];

View File

@@ -1,4 +1,4 @@
comment = 'vector data type and ivfflat access method'
default_version = '0.2.1'
default_version = '0.2.2'
module_pathname = '$libdir/vector'
relocatable = true