rv2307 commited on
Commit
69635eb
1 Parent(s): 84cf34f

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +6 -1
README.md CHANGED
@@ -54,11 +54,16 @@ Use the code below to get started with the model.
54
 
55
  ```
56
  from transformers import AutoModelForTokenClassification, AutoTokenizer
 
57
 
58
  model = AutoModelForTokenClassification.from_pretrained("rv2307/electra-small-ner")
59
  tokenizer = AutoTokenizer.from_pretrained("rv2307/electra-small-ner")
60
 
61
- nlp = pipeline("ner", model=model, tokenizer=tokenizer,device=device,aggregation_strategy = "max")
 
 
 
 
62
  ```
63
 
64
  ## Training Details
 
54
 
55
  ```
56
  from transformers import AutoModelForTokenClassification, AutoTokenizer
57
+ from transformers import pipeline
58
 
59
  model = AutoModelForTokenClassification.from_pretrained("rv2307/electra-small-ner")
60
  tokenizer = AutoTokenizer.from_pretrained("rv2307/electra-small-ner")
61
 
62
+ nlp = pipeline("ner",
63
+ model=model,
64
+ tokenizer=tokenizer,device="cpu",
65
+ aggregation_strategy = "max")
66
+
67
  ```
68
 
69
  ## Training Details