High-speed FAISS vector index and metadata for marine image retrieval using BioCLIP embeddings. Core component of the
OceanGPT-X
pipeline.
Repository Contents
Path
Description
faiss/index.faiss
Pre-built FAISS index containing BioCLIP feature vectors
faiss/id_map.json
Mapping between FAISS internal IDs and dataset image IDs
metadata/metadata.jsonl
Rich metadata for each indexed image (species, location, capture info)
Usage
Requires
faiss-cpu
or
faiss-gpu
.
import faiss
import json
import jsonlines
index = faiss.read_index("faiss/index.faiss")
withopen("faiss/id_map.json", "r") as f:
id_map = json.load(f)
# Query vector must match the embedding dimension of the index
query_vector = ... # Shape: (1, dim), dtype: float32
D, I = index.search(query_vector, k=5)
# Retrieve metadatawith jsonlines.open("metadata/metadata.jsonl") as reader:
metadata = {obj["id"]: obj for obj in reader}
for idx in I[0]:
img_id = id_map[str(idx)]
print(metadata.get(img_id, "Not found"))
Runs of zjunlp Ocean-FAISS on huggingface.co
0
Total runs
0
24-hour runs
0
3-day runs
0
7-day runs
0
30-day runs
More Information About Ocean-FAISS huggingface.co Model
Ocean-FAISS huggingface.co is an AI model on huggingface.co that provides Ocean-FAISS's model effect (), which can be used instantly with this zjunlp Ocean-FAISS model. huggingface.co supports a free trial of the Ocean-FAISS model, and also provides paid use of the Ocean-FAISS. Support call Ocean-FAISS model through api, including Node.js, Python, http.
Ocean-FAISS huggingface.co is an online trial and call api platform, which integrates Ocean-FAISS's modeling effects, including api services, and provides a free online trial of Ocean-FAISS, you can try Ocean-FAISS online for free by clicking the link below.
zjunlp Ocean-FAISS online free url in huggingface.co:
Ocean-FAISS is an open source model from GitHub that offers a free installation service, and any user can find Ocean-FAISS on GitHub to install. At the same time, huggingface.co provides the effect of Ocean-FAISS install, users can directly use Ocean-FAISS installed effect in huggingface.co for debugging and trial. It also supports api for free installation.