andito HF staff commited on
Commit
5d9cb65
1 Parent(s): 74ee333

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -13,8 +13,8 @@ processor = AutoProcessor.from_pretrained("HuggingFaceM4/Idefics3-8B-Llama3")
13
 
14
  model = Idefics3ForConditionalGeneration.from_pretrained("HuggingFaceM4/Idefics3-8B-Llama3",
15
  torch_dtype=torch.bfloat16,
16
- #_attn_implementation="flash_attention_2",
17
- trust_remote_code=True).to("cuda")
18
 
19
  BAD_WORDS_IDS = processor.tokenizer(["<image>", "<fake_token_around_image>"], add_special_tokens=False).input_ids
20
  EOS_WORDS_IDS = [processor.tokenizer.eos_token_id]
 
13
 
14
  model = Idefics3ForConditionalGeneration.from_pretrained("HuggingFaceM4/Idefics3-8B-Llama3",
15
  torch_dtype=torch.bfloat16,
16
+ #_attn_implementation="flash_attention_2"
17
+ ).to("cuda")
18
 
19
  BAD_WORDS_IDS = processor.tokenizer(["<image>", "<fake_token_around_image>"], add_special_tokens=False).input_ids
20
  EOS_WORDS_IDS = [processor.tokenizer.eos_token_id]