Update README.md
Browse files
README.md
CHANGED
|
@@ -38,7 +38,7 @@ Findings: Head/Neck: xxx Chest: xxx Abdomen/Pelvis: xxx Extremities/Musculoskele
|
|
| 38 |
Indication: The patient is a [AGE]-year old [SEX] with a history of xxx
|
| 39 |
"""
|
| 40 |
|
| 41 |
-
inputs = tokenizer(findings_info, padding="max_length", truncation=True, max_length=1024, return_tensors="pt")
|
| 42 |
input_ids = inputs.input_ids.to("cuda")
|
| 43 |
attention_mask = inputs.attention_mask.to("cuda")
|
| 44 |
outputs = model.generate(input_ids, attention_mask=attention_mask, max_new_tokens=512,
|
|
|
|
| 38 |
Indication: The patient is a [AGE]-year old [SEX] with a history of xxx
|
| 39 |
"""
|
| 40 |
|
| 41 |
+
inputs = tokenizer(findings_info.replace('\n', ' '), padding="max_length", truncation=True, max_length=1024, return_tensors="pt")
|
| 42 |
input_ids = inputs.input_ids.to("cuda")
|
| 43 |
attention_mask = inputs.attention_mask.to("cuda")
|
| 44 |
outputs = model.generate(input_ids, attention_mask=attention_mask, max_new_tokens=512,
|