-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
new version: fixing spacy warning on version check.
This addresses #11 #8 #5. SpaCy wants the version specification to match the major.minor. Also added docker example
- Loading branch information
1 parent
c4d6691
commit d0d3c97
Showing
10 changed files
with
45 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
"python.pythonPath": "venv/bin/python3.7" | ||
"python.pythonPath": "venv/bin/python" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
set -e | ||
|
||
VERSION=0.3.2 | ||
VERSION=0.3.3 | ||
|
||
# for every model | ||
for MODEL_NAME in en_use_md en_use_lg xx_use_md xx_use_lg | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
from python | ||
|
||
RUN pip install https://github.com/MartinoMensio/spacy-universal-sentence-encoder/releases/download/v0.3.3/en_use_lg-0.3.3.tar.gz#en_use_lg-0.3.3 | ||
|
||
CMD bash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Docker instructions | ||
|
||
## Build the image | ||
```bash | ||
docker build -t use . | ||
``` | ||
|
||
## Create the container | ||
|
||
You can use pre-downloaded models from [TFHub](https://tfhub.dev/google/collections/universal-sentence-encoder/1) by using volume mapping. | ||
If you want to do so, at the same time you need to provide the environment variable `TFHUB_CACHE_DIR` which will be used by the library to find the downloaded models. | ||
|
||
```bash | ||
docker run -it --rm -v `pwd`/models/universal_sentence_encoder:/SOME_SIMPLE_PATH_HERE -e TFHUB_CACHE_DIR=/SOME_SIMPLE_PATH_HERE --entrypoint /bin/bash nlp | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
{ | ||
"lang": "en", | ||
"name": "use_lg", | ||
"version": "0.3.2", | ||
"spacy_version": ">=2.1,<2.4", | ||
"version": "0.3.3", | ||
"spacy_version": ">=2.3,<2.4", | ||
"description": "TensorFlow Hub wrapper for Universal Sentence Encoder", | ||
"author": "Martino Mensio", | ||
"email": "[email protected]", | ||
"url": "https://github.com/MartinoMensio/spacy-universal-sentence-encoder", | ||
"license": "MIT", | ||
"requirements": [ | ||
"spacy_universal_sentence_encoder==0.3.2" | ||
"spacy_universal_sentence_encoder==0.3.3" | ||
], | ||
"sources": [{ | ||
"name": "Universal Sentence Encoder - Large", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
{ | ||
"lang": "en", | ||
"name": "use_md", | ||
"version": "0.3.2", | ||
"spacy_version": ">=2.1,<2.4", | ||
"version": "0.3.3", | ||
"spacy_version": ">=2.3,<2.4", | ||
"description": "TensorFlow Hub wrapper for Universal Sentence Encoder", | ||
"author": "Martino Mensio", | ||
"email": "[email protected]", | ||
"url": "https://github.com/MartinoMensio/spacy-universal-sentence-encoder", | ||
"license": "MIT", | ||
"requirements": [ | ||
"spacy_universal_sentence_encoder==0.3.2" | ||
"spacy_universal_sentence_encoder==0.3.3" | ||
], | ||
"sources": [{ | ||
"name": "Universal Sentence Encoder", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
{ | ||
"lang": "xx", | ||
"name": "use_lg", | ||
"version": "0.3.2", | ||
"spacy_version": ">=2.1,<2.4", | ||
"version": "0.3.3", | ||
"spacy_version": ">=2.3,<2.4", | ||
"description": "TensorFlow Hub wrapper for Universal Sentence Encoder", | ||
"author": "Martino Mensio", | ||
"email": "[email protected]", | ||
"url": "https://github.com/MartinoMensio/spacy-universal-sentence-encoder", | ||
"license": "MIT", | ||
"requirements": [ | ||
"spacy_universal_sentence_encoder==0.3.2" | ||
"spacy_universal_sentence_encoder==0.3.3" | ||
], | ||
"sources": [{ | ||
"name": "Universal Sentence Encoder Multilingual - Large", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
{ | ||
"lang": "xx", | ||
"name": "use_md", | ||
"version": "0.3.2", | ||
"spacy_version": ">=2.1,<2.4", | ||
"version": "0.3.3", | ||
"spacy_version": ">=2.3,<2.4", | ||
"description": "TensorFlow Hub wrapper for Universal Sentence Encoder", | ||
"author": "Martino Mensio", | ||
"email": "[email protected]", | ||
"url": "https://github.com/MartinoMensio/spacy-universal-sentence-encoder", | ||
"license": "MIT", | ||
"requirements": [ | ||
"spacy_universal_sentence_encoder==0.3.2" | ||
"spacy_universal_sentence_encoder==0.3.3" | ||
], | ||
"sources": [{ | ||
"name": "Universal Sentence Encoder Multilingual", | ||
|