When running render.show() ,I am getting an error

#5
by RoshanJoe - opened

Error: no "view" rule for type "image/png" passed its test case
(for more information, add "--debug=1" on the command line)
/usr/bin/xdg-open: 882: www-browser: not found
/usr/bin/xdg-open: 882: links2: not found
/usr/bin/xdg-open: 882: elinks: not found
/usr/bin/xdg-open: 882: links: not found
/usr/bin/xdg-open: 882: lynx: not found
/usr/bin/xdg-open: 882: w3m: not found
xdg-open: no method available for opening '/tmp/tmpj0ui6bix.PNG'

I am getting this error please look into it.

FODUU org

Hello, can you share the code snippet to help me understand the issue better? because it seems like the issue is related to tmp path.

Thank you!

from ultralyticsplus import YOLO, render_result

load model

model = YOLO('foduucom/table-detection-and-extraction')

set model parameters

model.overrides['conf'] = 0.25 # NMS confidence threshold
model.overrides['iou'] = 0.45 # NMS IoU threshold
model.overrides['agnostic_nms'] = False # NMS class-agnostic
model.overrides['max_det'] = 1000 # maximum number of detections per image

set image

image = 'image1.png'

perform inference

results = model.predict(image)

observe results

print(results[0].boxes)
render = render_result(model=model, image=image, result=results[0])
render.show()

Sign up or log in to comment