Add negative prompts to segment-anything. (#1000)

This commit is contained in:
Laurent Mazare
2023-09-30 07:17:42 +02:00
committed by GitHub
parent 34842fb234
commit 6203ced495
3 changed files with 34 additions and 18 deletions

View File

@ -94,7 +94,7 @@ impl Model {
&embeddings.data,
embeddings.height as usize,
embeddings.width as usize,
&[(x, y)],
&[(x, y, true)],
false,
)?;
let iou = iou_predictions.flatten(0, 1)?.to_vec1::<f32>()?[0];