Update README.md
Browse files
README.md
CHANGED
@@ -6,14 +6,12 @@ license: apache-2.0
|
|
6 |
|
7 |
More details to come...
|
8 |
|
|
|
9 |
```python
|
10 |
import os, torch, transformers
|
11 |
from PIL import Image
|
12 |
from torchvision import transforms
|
13 |
|
14 |
-
os.environ['TRANSFORMERS_CACHE'] = '/scratch1/nic261/hf_cache'
|
15 |
-
os.environ['HUGGINGFACE_HUB_CACHE'] = '/scratch1/nic261/hf_cache'
|
16 |
-
|
17 |
ckpt_name = 'aehrc/mimic-cxr-report-gen-single'
|
18 |
|
19 |
encoder_decoder = transformers.AutoModel.from_pretrained(ckpt_name, trust_remote_code=True)
|
|
|
6 |
|
7 |
More details to come...
|
8 |
|
9 |
+
## Example:
|
10 |
```python
|
11 |
import os, torch, transformers
|
12 |
from PIL import Image
|
13 |
from torchvision import transforms
|
14 |
|
|
|
|
|
|
|
15 |
ckpt_name = 'aehrc/mimic-cxr-report-gen-single'
|
16 |
|
17 |
encoder_decoder = transformers.AutoModel.from_pretrained(ckpt_name, trust_remote_code=True)
|