TravelLeraLone commited on
Commit
6e9a472
·
verified ·
1 Parent(s): 9c51f96

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +2 -2
README.md CHANGED
@@ -32,10 +32,10 @@ To load and run ChemDFM locally, here is an example:
32
 
33
  ```python
34
  import torch
35
- from transformers import LlamaTokenizer, LlamaForCausalLM, GenerationConfig
36
 
37
  model_name_or_id = "OpenDFM/ChemDFM-v1.5-8B"
38
- tokenizer = LlamaTokenizer.from_pretrained(model_name_or_id)
39
  model = LlamaForCausalLM.from_pretrained(model_name_or_id, torch_dtype=torch.float16, device_map="auto")
40
 
41
  input_text = "Can you please give detailed descriptions of the molecule below?\nCl.O=C1c2c(O)cccc2-c2nn(CCNCCO)c3ccc(NCCNCCO)c1c23"
 
32
 
33
  ```python
34
  import torch
35
+ from transformers import AutoTokenizer, LlamaForCausalLM, GenerationConfig
36
 
37
  model_name_or_id = "OpenDFM/ChemDFM-v1.5-8B"
38
+ tokenizer = AutoTokenizer.from_pretrained(model_name_or_id)
39
  model = LlamaForCausalLM.from_pretrained(model_name_or_id, torch_dtype=torch.float16, device_map="auto")
40
 
41
  input_text = "Can you please give detailed descriptions of the molecule below?\nCl.O=C1c2c(O)cccc2-c2nn(CCNCCO)c3ccc(NCCNCCO)c1c23"