Files changed (1) hide show
  1. README.md +2 -1
README.md CHANGED
@@ -31,6 +31,7 @@ This is the 4-bit version of InternLM-XComposer2, install the latest version of
31
 
32
  ```python
33
  import torch, auto_gptq
 
34
  from transformers import AutoModel, AutoTokenizer
35
  from auto_gptq.modeling import BaseGPTQForCausalLM
36
 
@@ -62,7 +63,7 @@ img_path_list = [
62
  images = []
63
  for img_path in img_path_list:
64
  image = Image.open(img_path).convert("RGB")
65
- image = quant_model.vis_processor(image)
66
  images.append(image)
67
  image = torch.stack(images)
68
  query = '<ImageHere> <ImageHere>please write an article based on the images. Title: my favorite animal.'
 
31
 
32
  ```python
33
  import torch, auto_gptq
34
+ from PIL import Image
35
  from transformers import AutoModel, AutoTokenizer
36
  from auto_gptq.modeling import BaseGPTQForCausalLM
37
 
 
63
  images = []
64
  for img_path in img_path_list:
65
  image = Image.open(img_path).convert("RGB")
66
+ image = model.vis_processor(image)
67
  images.append(image)
68
  image = torch.stack(images)
69
  query = '<ImageHere> <ImageHere>please write an article based on the images. Title: my favorite animal.'