Skip to content

Commit

Permalink
fix test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
SeanLee97 committed Jul 28, 2024
1 parent 6cd6442 commit 8d30e59
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/test_loadding.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ def test_loadding():
assert isinstance(vecs, np.ndarray)


def test_2dmse_loadding():
def test_ese_loadding():
import numpy as np
from angle_emb import AnglE

angle = AnglE.from_pretrained('WhereIsAI/UAE-Large-V1')
vecs = angle.encode('hello world', layer_index=20)
angle = AnglE.from_pretrained('WhereIsAI/UAE-Large-V1').truncate_layer(20)
vecs = angle.encode('hello world')
assert isinstance(vecs, np.ndarray)
vecs = angle.encode(['hello world', 'hi there👋'], layer_index=20, embedding_size=512)
vecs = angle.encode(['hello world', 'hi there👋'], embedding_size=512)
assert isinstance(vecs, np.ndarray)


Expand Down

0 comments on commit 8d30e59

Please sign in to comment.