juanpablomesa
commited on
Commit
·
a0a72c0
1
Parent(s):
c45d9fe
Removed normalization of embeddings
Browse files- handler.py +2 -2
handler.py
CHANGED
@@ -122,8 +122,8 @@ class EndpointHandler:
|
|
122 |
batch_emb = batch_emb.cpu().detach().numpy()
|
123 |
|
124 |
# NORMALIZE
|
125 |
-
self.logger.info("Normalizing numpy array")
|
126 |
-
batch_emb = batch_emb.T / np.linalg.norm(batch_emb, axis=1)
|
127 |
# transpose back to (21, 512)
|
128 |
|
129 |
self.logger.info("Converting to list")
|
|
|
122 |
batch_emb = batch_emb.cpu().detach().numpy()
|
123 |
|
124 |
# NORMALIZE
|
125 |
+
# self.logger.info("Normalizing numpy array")
|
126 |
+
# batch_emb = batch_emb.T / np.linalg.norm(batch_emb, axis=1)
|
127 |
# transpose back to (21, 512)
|
128 |
|
129 |
self.logger.info("Converting to list")
|