From 31821d043827b4c2aa91afbe2312764f6caf10b8 Mon Sep 17 00:00:00 2001 From: Riccardo Balbo Date: Sun, 21 Apr 2024 00:25:36 +0200 Subject: [PATCH] fix --- src/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.py b/src/main.py index bb54edb..4d437f6 100644 --- a/src/main.py +++ b/src/main.py @@ -52,8 +52,8 @@ def deserializeFromJSON( self, data, marker, index_vectors ,index_content, searc data=json.loads(data) for part in data: [text,embeddings_b64,_dtype,_shape] = part - part_marker=part[4] if len(part)>3 else None - + part_marker=part[4] if len(part)>4 else None + if dtype is None: dtype = _dtype elif dtype != _dtype: raise Exception("Data type mismatch") if shape is None: shape = _shape