pszemraj commited on
Commit
480a198
1 Parent(s): 3915d16

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +1 -2
README.md CHANGED
@@ -27,10 +27,9 @@ load the model into a `pipeline` object:
27
  ```
28
  from transformers import pipeline
29
  import torch
30
- device = 'cuda' if torch.cuda.is_available() else 'cpu'
31
  my_chatbot = pipeline('text-generation',
32
  'pszemraj/gpt-peter-2.7B',
33
- device=0 if device == 'cuda' else -1,
34
  )
35
  ```
36
 
 
27
  ```
28
  from transformers import pipeline
29
  import torch
 
30
  my_chatbot = pipeline('text-generation',
31
  'pszemraj/gpt-peter-2.7B',
32
+ device=0 if torch.cuda.is_available() else -1,
33
  )
34
  ```
35