Upload google_embeddinggemma-300m_2.py with huggingface_hub
Browse files
google_embeddinggemma-300m_2.py
CHANGED
|
@@ -44,7 +44,8 @@ except Exception as e:
|
|
| 44 |
|
| 45 |
with open('google_embeddinggemma-300m_2.txt', 'a', encoding='utf-8') as f:
|
| 46 |
import traceback
|
| 47 |
-
f.write('
|
|
|
|
| 48 |
# The sentences to encode
|
| 49 |
sentence_high = [
|
| 50 |
"The chef prepared a delicious meal for the guests.",
|
|
@@ -67,7 +68,7 @@ for sentence in [sentence_high, sentence_medium, sentence_low]:
|
|
| 67 |
print("`-> 🤖 score: ", similarities.numpy()[0][0])
|
| 68 |
```
|
| 69 |
ERROR:
|
| 70 |
-
')
|
| 71 |
traceback.print_exc(file=f)
|
| 72 |
|
| 73 |
finally:
|
|
|
|
| 44 |
|
| 45 |
with open('google_embeddinggemma-300m_2.txt', 'a', encoding='utf-8') as f:
|
| 46 |
import traceback
|
| 47 |
+
f.write('''
|
| 48 |
+
```CODE:
|
| 49 |
# The sentences to encode
|
| 50 |
sentence_high = [
|
| 51 |
"The chef prepared a delicious meal for the guests.",
|
|
|
|
| 68 |
print("`-> 🤖 score: ", similarities.numpy()[0][0])
|
| 69 |
```
|
| 70 |
ERROR:
|
| 71 |
+
''')
|
| 72 |
traceback.print_exc(file=f)
|
| 73 |
|
| 74 |
finally:
|