pg.ddx.io  pgvector/pgvector GitHub issues and pull requests  
help / color / mirror / Atom feed
From: ankane (@ankane) <noreply+ankane@github.com>
To: pgvector/pgvector <noreply+pgvector-pgvector@github.com>
Subject: Re: [pgvector/pgvector] issue #844: Questions on HNSW graph memory usage and size estimation
Date: Sun, 25 May 2025 19:50:21 +0000
Message-ID: <gh-pgvector-pgvector-844-c2908043852@github.com> (raw)
In-Reply-To: <gh-pgvector-pgvector-844@github.com>
References: <gh-pgvector-pgvector-844@github.com>

There are two sizes:

1. The size of the in-memory graph during the index build
2. The size of the final index

A quick way to estimate 1 is to set `maintenance_work_mem` to 100MB, see how many tuples fit (from the notice), and extrapolate.

A quick way to estimate 2 is to create an index with the first 10k rows, check the size with `pg_relation_size`, and extrapolate.


view thread (6+ messages)  latest in thread

Message-ID: <gh-pgvector-pgvector-844-c2908043852@github.com>
Permalink:  ../gh-pgvector-pgvector-844-c2908043852@github.com/

 · 


This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox