Skip to content

Commit 67709bc

Browse files
committed
CU-8699rvhe9 Refer to PyPI medcat v2 (#46)
* CU-8699rvhe9: Update README with correct (PyPI) installation instructions * CU-8699rvhe9: Update main docs with correct (PyPI) installation instructions * CU-8699rvhe9: Update v2 tutorials with correct (PyPI) dependency/install * CU-8699rvhe9: Update medcat-service with correct (PyPI) dependency/install * CU-8699rvhe9: Update medcat demo web app with correct (PyPI) dependency/install * CU-8699rvhe9: Update rel-cat tutorial with correct (PyPI) dependency/install * CU-8699rvhe9: Remove git install from MedCAT service - should no longer be needed
1 parent a38bca3 commit 67709bc

File tree

9 files changed

+23
-33
lines changed

9 files changed

+23
-33
lines changed

medcat-demo-app/webapp/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ Django==3.2.25
22
django-dbbackup==4.0.0b0
33
django-storages[boto3]==1.12.3
44
django-cron==0.5.1
5-
medcat[meta-cat,spacy] @ git+https://github.com/CogStack/cogstack-nlp.git@refs/tags/medcat/v0.11.2#subdirectory=medcat-v2
5+
medcat[meta-cat,spacy]~=2.0.0b
66
urllib3==1.26.18

medcat-service/Dockerfile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@ ENV CRYPTOGRAPHY_DONT_BUILD_RUST=1
66
WORKDIR /cat
77
COPY ./requirements.txt /cat
88

9-
# NOTE: need git for URL based installs
10-
RUN apt-get update && apt-get install -y git
11-
129
# Install Python dependencies
1310
ARG USE_CPU_TORCH=true
1411
# NOTE: Allow building without GPU so as to lower image size (GPU is disabled by default)

medcat-service/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ setuptools==78.1.1
66
simplejson==3.19.3
77
werkzeug==3.1.3
88
setuptools-rust==1.11.0
9-
medcat[meta-cat,spacy,deid] @ git+https://github.com/CogStack/cogstack-nlp.git@refs/tags/medcat/v0.13.5#subdirectory=medcat-v2
9+
medcat[meta-cat,spacy,deid]~=2.0.0b
1010
# pinned because of issues with de-id models and past models (it will not do any de-id)
1111
transformers>=4.34.0,<5.0.0
1212
requests==2.32.4

medcat-v2-tutorials/notebooks/introductory/meta/1._Add_a_MetaCat_to_a_Model.ipynb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@
7676
}
7777
],
7878
"source": [
79-
"! pip install \"medcat[meta-cat] @ git+https://github.com/CogStack/cogstack-nlp@medcat/v0.11.2#subdirectory=medcat-v2\" # NOTE: VERSION-STRING"
79+
"! pip install medcat[meta-cat]~=2.0.0b # NOTE: VERSION-STRING"
8080
]
8181
},
8282
{
@@ -330,7 +330,7 @@
330330
],
331331
"metadata": {
332332
"kernelspec": {
333-
"display_name": ".venv",
333+
"display_name": ".venv_v2_tut",
334334
"language": "python",
335335
"name": "python3"
336336
},
@@ -344,7 +344,7 @@
344344
"name": "python",
345345
"nbconvert_exporter": "python",
346346
"pygments_lexer": "ipython3",
347-
"version": "3.10.13"
347+
"version": "3.11.12"
348348
}
349349
},
350350
"nbformat": 4,

medcat-v2-tutorials/notebooks/introductory/migration/1._Migrate_v1_model_to_v2.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@
131131
}
132132
],
133133
"source": [
134-
"! pip install \"medcat[meta-cat,spacy,deid] @ git+https://github.com/CogStack/cogstack-nlp@medcat/v0.11.2#subdirectory=medcat-v2\""
134+
"! pip install medcat[meta-cat,spacy,deid]~=2.0.0b"
135135
]
136136
},
137137
{

medcat-v2-tutorials/notebooks/introductory/relcat/1._Supervised_Training_Relation_Extraction.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@
101101
],
102102
"source": [
103103
"# Install medcat\n",
104-
"! pip install \"medcat[spacy,rel-cat,meta-cat] @ git+https://github.com/CogStack/cogstack-nlp@medcat/v0.11.2#subdirectory=medcat-v2\" # NOTE: VERSION-STRING"
104+
"! pip install medcat~=2.0.0b # NOTE: VERSION-STRING"
105105
]
106106
},
107107
{

medcat-v2-tutorials/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
medcat @ git+https://github.com/CogStack/cogstack-nlp@medcat/v0.11.2#subdirectory=medcat-v2
1+
medcat~=2.0.0b
22
ipykernel
33
pytest-xdist~=3.6.0
44
nbmake<1.6

medcat-v2/README.md

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -42,38 +42,26 @@ If you wish you can also convert the v1 models into the v2 format (see tutorial
4242
## Installation
4343

4444
Currently MedCAT v2 is in Beta.
45-
As such, we're not yet pushing to PyPI.
46-
And because of that the current installation command for (only) core MedCAT v2 is:
45+
As such, you need to explicitly specify the beta release.
4746
```
48-
pip install "medcat @ git+https://github.com/CogStack/cogstack-nlp.git@refs/tags/medcat/v0.10.0#subdirectory=medcat-v2"
47+
pip install medcat~=2.0.0b
4948
```
5049
Do note that **this installs only the core MedCAT v2**.
5150
**It does not necessary dependencies for `spacy`-based tokenizing or MetaCATs or DeID**.
5251
However, all of those are supported as well.
5352
You can install them as follows:
5453
```
55-
pip install "medcat[spacy] @ git+https://github.com/CogStack/cogstack-nlp.git@refs/tags/medcat/v0.10.0#subdirectory=medcat-v2" # for spacy-based tokenizer
56-
pip install "medcat[meta-cat] @ git+https://github.com/CogStack/cogstack-nlp.git@refs/tags/medcat/v0.10.0#subdirectory=medcat-v2" # for MetaCAT
57-
pip install "medcat[deid] @ git+https://github.com/CogStack/cogstack-nlp.git@refs/tags/medcat/v0.10.0#subdirectory=medcat-v2" # for DeID models
58-
pip install "medcat[spacy,meta-cat,deid,rel-cat,dict-ner] @ git+https://github.com/CogStack/cogstack-nlp.git@refs/tags/medcat/v0.10.0#subdirectory=medcat-v2" # for all of the sbove
54+
pip install medcat[spacy]~=2.0.0b # for spacy-based tokenizer
55+
pip install medcat[meta-cat]~=2.0.0b # for MetaCAT
56+
pip install medcat[deid]~=2.0.0b # for DeID models
57+
pip install medcat[spacy,meta-cat,deid,rel-cat,dict-ner]~=2.0.0b # for all of the above
5958
```
6059

6160
PS:
6261
For in the above example, we're installing the MedCAT v2 BETA version of `v0.8.0`.
6362
The README is unlikely to change after every new release.
6463
If another version is available / required, substitute the version tag as appropriate.
6564

66-
<!--
67-
To install the latest version of MedCAT run the following command:
68-
```
69-
pip install medcat
70-
```
71-
Normal installations of MedCAT will install torch-gpu and all relevant dependancies (such as CUDA). This can require as much as 10 GB more disk space, which isn't required for CPU only usage.
72-
73-
To install the latest version of MedCAT without torch GPU support run the following command:
74-
```
75-
pip install medcat --extra_index_url https://download.pytorch.org/whl/cpu/
76-
``` -->
7765
## Demo
7866

7967
The MedCAT v2 demo web app is available [here](https://medcatv2.sites.er.kcl.ac.uk/).

medcat-v2/docs/main.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,15 @@ Some guides on how to use MedCAT v2 are available at [MedCAT Tutorials](https://
4444
## Install using PIP (Requires Python 3.9+)
4545
Installation instructions are to follow upon a release of this version on PyPI.
4646
Though installation is likely to be simply `pip install "medcat>=2.0"` at that time.
47-
<!-- 0. Upgrade pip `pip install --upgrade pip`
48-
1. Install MedCAT
49-
- For macOS/linux: `pip install --upgrade medcat`
50-
- For Windows (see [PyTorch documentation](https://pytorch.org/get-started/previous-versions/)): `pip install --upgrade medcat -f https://download.pytorch.org/whl/torch_stable.html` -->
47+
Currently the installation for the 2.0 beta release is simply:
48+
```
49+
pip install medcat~=2.0.0b
50+
```
51+
Though note the extras you might need (e.g `spacy`, `meta-cat`, `rel-cat`, `deid`).
52+
If you need them, they need to be specified in brackets, e.g:
53+
```
54+
pip install medcat[spacy,meta-cat,rel-cat,deid]~=2.0.0b
55+
```
5156

5257
2. Quickstart (MedCAT v2+):
5358
```python

0 commit comments

Comments
 (0)