YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
1 Overview
- Backend API for Barcode Scanner Project.
2. Run demo
2.1 Simple demo
from algorithm import Algorithm
with open("config.json", "r") as f:
config = json.load(f)
algorithm = Algorithm(config=config)
ori_img = cv2.imread("images/1.jpg")
camera_id = "0"
list_infer_imgs = [[ori_img, camera_id]]
list_results = algorithm.process(list_infer_imgs)
2.2 Input/Output format
- Input format: a list of image and camera_id.
- Output format: json. Example:
```
"returned_result"[
[
{
"bbox":[
79.375,
533.125,
1795.0,
806.875
],
"score":0.9345703125,
"keypoints":[
69.375,
548.75,
1.0,
1770.0,
555.625,
0.9990234375,
1767.5,
785.625,
0.99267578125,
78.125,
788.125,
0.9990234375
],
"texts":[
{
"bbox":[
1379.19140625,
111.03955078125,
1602.31640625,
135.966796875
],
"score":0.9638671875,
"text":"DIFFUSEDINJAPAN"
},
{
"bbox":[
611.1533203125,
99.796142578125,
697.265625,
132.48046875
],
"score":0.95703125,
"text":"2500pcs."
}
],
"barcodes":[
{
"bbox":[
706.330078125,
39.1776123046875,
889.7109375,
229.0517578125
],
"score":0.98486328125,
"text":""
},
{
"bbox":[
899.47265625,
161.329833984375,
1628.8125,
230.96923828125
],
"score":0.9716796875,
"text":"Y38106966002500XTSC6DP5"
}
]
}
]
]
```
3 Update Log
4 Test
PYTHONPATH=. pytest -v -m "unit" PYTHONPATH=. python tests/benchmark/benchmark_japan_workflow.py PYTHONPATH=. python tests/benchmark/benchmark_dataset.py
- Downloads last month
- 5
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support