mecoaoge2 commited on
Commit
4cc3454
1 Parent(s): ba8448b

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +15 -1
README.md CHANGED
@@ -23,4 +23,18 @@ The general architecture and experimental results of ViSoBERT can be found in ou
23
  }
24
 
25
 
26
- **Please CITE** our paper when ViSoBERT is used to help produce published results or is incorporated into other software.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
23
  }
24
 
25
 
26
+ **Please CITE** our paper when ViSoBERT is used to help produce published results or is incorporated into other software.
27
+
28
+ **Installation** Install `transformers` with pip: `pip install transformers` and `SentencePiece` with `pip install SentencePiece`
29
+
30
+ **Example usage**
31
+ from transformers import AutoModel,AutoTokenizer
32
+ import torch
33
+
34
+ model= AutoModel.from_pretrained('uitnlp/visobert')
35
+ tokenizer = AutoTokenizer.from_pretrained('uitnlp/visobert')
36
+
37
+ encoding = tokenizer('dau xanh rau ma',return_tensors='pt')
38
+
39
+ with torch.no_grad():
40
+ output = model(**encoding)