Safetensors
jiangchengchengNLP commited on
Commit
922e797
·
verified ·
1 Parent(s): 082a230

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +3 -3
README.md CHANGED
@@ -44,7 +44,7 @@ import torch
44
 
45
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
46
  image = Image.open("./bird.jpeg")
47
- input_ = processor("please identify the animal in the image", image)
48
  input_ = {k: v.to(device) for k, v in input_.items()}
49
  model.to(device)
50
  image_idx = torch.tensor(input_['input_ids'].shape[1] - 1).unsqueeze(0)
@@ -56,5 +56,5 @@ generated_ids = generated_ids[0][input_['input_ids'].size(1):]
56
  response = processor.tokenizer.decode(generated_ids, skip_special_tokens=True)
57
  print(response)
58
 
59
- ```output
60
- "The bird is perched on a branch, possibly a branch, with its head partially visible."
 
44
 
45
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
46
  image = Image.open("./bird.jpeg")
47
+ input_ = processor("please describe the image", image)
48
  input_ = {k: v.to(device) for k, v in input_.items()}
49
  model.to(device)
50
  image_idx = torch.tensor(input_['input_ids'].shape[1] - 1).unsqueeze(0)
 
56
  response = processor.tokenizer.decode(generated_ids, skip_special_tokens=True)
57
  print(response)
58
 
59
+
60
+ "The image features a small bird, possibly a cockatoo or a cockatoo, sitting on a branch in a forest. The bird appears to be looking up, possibly observing its surroundings or scanning for potential prey. The bird is surrounded by leaves and flowers on the branches, adding a sense of natural beauty to the scene. The image captures the beauty of the bird and its environment, highlighting the harmony between nature and human-made objects."