We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0e0994a commit 54b888fCopy full SHA for 54b888f
chromadb/api/types.py
@@ -143,7 +143,7 @@ def normalize_embeddings(
143
144
if len(target) == 0:
145
raise ValueError(
146
- f"Expected Embeddings to be non-empty list or numpy array, got {target}"
+ f"Expected embeddings to be non-empty list or numpy array, got {target}"
147
)
148
149
if isinstance(target, list):
@@ -152,6 +152,8 @@ def normalize_embeddings(
152
return [np.array(target, dtype=np.float32)]
153
# List of PyEmbeddings
154
if isinstance(target[0], list):
155
+ if len(target[0]) == 0:
156
+ raise ValueError("Expected embeddings to be at least 1-dimensional")
157
if isinstance(target[0][0], (int, float)) and not isinstance(
158
target[0][0], bool
159
):
0 commit comments