Oss Opencv Lens Undistort Camera Pose
by OpenCV Undistort + Camera Pose in Other
Lens undistortion plus camera pose estimation in one paid call (OpenCV 4.13). Send the same fields as /v1/oss-opencv-calibrated-lens-undistort and /v1/oss-opencv-landmark-camera-pose: grayscale image, camera matrix, five distortion coefficients, 3D object points and their pixel positions. Returns the undistorted image plus rotation, translation and reprojection RMSE of the camera pose (solvePnP). 0.0035 USDC instead of 0.004 for both single calls.
https://medien.halowerk.com/v1/oss-opencv-lens-undistort-camera-pose- Price
- $0.0035
- per call in USDC
- Uptime
- 84.6%
- last 30 days
- Response time
- 130 ms
- 176 ms slowest 5%
- Last check
- Passed
- 8 h ago, next any minute now
Reliability
Status and outage history · Atom feed · Watch with other listings
How to call it
POST https://medien.halowerk.com/v1/oss-opencv-lens-undistort-camera-pose
Each call costs $0.0035 in USDC on Base, paid with the request over x402.
Run a free test callOne unpaid request, the way an agent sends it. You see the payment challenge it gets back. Nothing is charged.
Example request
From the listing.
POST https://medien.halowerk.com/v1/oss-opencv-lens-undistort-camera-pose
content-type: application/json
{
"camera_matrix": [
[
45,
0,
7.5
],
[
0,
45,
7.5
],
[
0,
0,
1
]
],
"distortion": [
0.2,
0.01,
0,
0,
0
],
"image": [
[
0,
2,
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30
],
[
1,
3,
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31
],
[
2,
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32
],
[
3,
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33
],
[
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34
],
[
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35
],
[
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36
],
[
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37
],
[
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38
],
[
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39
],
[
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40
],
[
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41
],
[
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40,
42
],
[
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
43
],
[
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40,
42,
44
],
[
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
43,
45
]
],
"image_points": [
[
4.089635,
0.052715
],
[
15.28601,
1.247651
],
[
13.939933,
12.229251
],
[
3.055042,
11.534801
],
[
4.17277,
5.477471
],
[
11.507841,
7.529774
],
[
8.221936,
0.786991
],
[
11.242104,
10.102808
]
],
"object_points": [
[
-0.1,
-0.1,
0
],
[
0.1,
-0.1,
0
],
[
0.1,
0.1,
0
],
[
-0.1,
0.1,
0
],
[
-0.08,
0,
0.1
],
[
0.1,
0.04,
0.2
],
[
0,
-0.1,
0.15
],
[
0.07,
0.08,
0.09
]
]
}Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
camera_matrix | array of array of number | Yes | |
distortion | array of number | Yes | |
image | array of array of integer | Yes | |
image_points | array of array of number | Yes | |
object_points | array of array of number | Yes |
Example response
The provider's example. We can't check it without paying.
Example response, 71 lines
{
"operation": "lens-undistort-camera-pose",
"pose": {
"operation": "landmark-camera-pose",
"result": {
"reprojection_rmse_pixels": 3.0171708189510797e-7,
"rotation": [
[
0.9806970724960888,
-0.1007034489923423
],
[
0.07862354243995694,
0.9879206144678995
]
],
"translation": [
0.030000000640771046,
-0.02000000487000844
],
"warnings": [
"The transform maps object coordinates into camera coordinates; ambiguous scenes may admit other poses."
]
},
"runtime_ms": 0.824,
"upstream": {
"binary_sha256": "1fd4eb220f9986baa0ea0492cbcbedf85b868e792cbcac5f69e10d067a2f956c",
"components": [
"solvePnP",
"Rodrigues"
],
"numpy_version": "2.5.0",
"package_version": "4.13.0.92",
"project": "OpenCV",
"version": "4.13.0"
}
},
"price_note": "One call at 0.0035 USDC replaces /v1/oss-opencv-calibrated-lens-undistort (0.002) plus /v1/oss-opencv-landmark-camera-pose (0.002).",
"runtime_ms": 558,
"undistort": {
"operation": "calibrated-lens-undistort",
"result": {
"height": 16,
"image": [
[
0,
2
],
[
1,
3
]
],
"warnings": [
"The original camera matrix and dimensions are retained; pixels mapped outside the source image are zero."
],
"width": 16
},
"runtime_ms": 0.515,
"upstream": {
"binary_sha256": "1fd4eb220f9986baa0ea0492cbcbedf85b868e792cbcac5f69e10d067a2f956c",
"components": [
"undistort"
],
"numpy_version": "2.5.0",
"package_version": "4.13.0.92",
"project": "OpenCV",
"version": "4.13.0"
}
}
}Call it from code
The curl command shows the payment challenge. The JavaScript and Python versions pay and call, and never pay more than $0.0035.
curl: see the payment challenge
# bash or zsh: see the payment challenge. Nothing is charged.
curl -sS -g -i -X POST 'https://medien.halowerk.com/v1/oss-opencv-lens-undistort-camera-pose' \
-H 'content-type: application/json' \
--data-raw '{"camera_matrix":[[45,0,7.5],[0,45,7.5],[0,0,1]],"distortion":[0.2,0.01,0,0,0],"image":[[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30],[1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31],[2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32],[3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33],[4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34],[5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35],[6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36],[7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37],[8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38],[9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39],[10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40],[11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41],[12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42],[13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43],[14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44],[15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45]],"image_points":[[4.089635,0.052715],[15.28601,1.247651],[13.939933,12.229251],[3.055042,11.534801],[4.17277,5.477471],[11.507841,7.529774],[8.221936,0.786991],[11.242104,10.102808]],"object_points":[[-0.1,-0.1,0],[0.1,-0.1,0],[0.1,0.1,0],[-0.1,0.1,0],[-0.08,0,0.1],[0.1,0.04,0.2],[0,-0.1,0.15],[0.07,0.08,0.09]]}'
# x402 v2 sends the challenge base64-encoded in the PAYMENT-REQUIRED header (v1 sends it in the body).
# To read the header:
curl -sS -g -o /dev/null -D - -X POST 'https://medien.halowerk.com/v1/oss-opencv-lens-undistort-camera-pose' \
-H 'content-type: application/json' \
--data-raw '{"camera_matrix":[[45,0,7.5],[0,45,7.5],[0,0,1]],"distortion":[0.2,0.01,0,0,0],"image":[[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30],[1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31],[2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32],[3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33],[4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34],[5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35],[6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36],[7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37],[8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38],[9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39],[10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40],[11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41],[12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42],[13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43],[14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44],[15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45]],"image_points":[[4.089635,0.052715],[15.28601,1.247651],[13.939933,12.229251],[3.055042,11.534801],[4.17277,5.477471],[11.507841,7.529774],[8.221936,0.786991],[11.242104,10.102808]],"object_points":[[-0.1,-0.1,0],[0.1,-0.1,0],[0.1,0.1,0],[-0.1,0.1,0],[-0.08,0,0.1],[0.1,0.04,0.2],[0,-0.1,0.15],[0.07,0.08,0.09]]}' \
| grep -i '^payment-required:' | cut -d' ' -f2 | tr -d '\r' | base64 --decodeJavaScript: pay and call
// npm i @x402/fetch @x402/evm viem
import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
// Pays at most $0.0035 per call.
const client = new x402Client().setSpendControls({ maxAmountPerPayment: "$0.0035" });
registerExactEvmScheme(client, { signer: privateKeyToAccount(process.env.EVM_PRIVATE_KEY) });
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? ToolVet checks it first for $0.005. Pay for that from a separate
// client: this one is capped at $0.0035 per payment. GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fmedien.halowerk.com%2Fv1%2Foss-opencv-lens-undistort-camera-pose&method=POST
const res = await pay("https://medien.halowerk.com/v1/oss-opencv-lens-undistort-camera-pose", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({
"camera_matrix": [
[
45,
0,
7.5
],
[
0,
45,
7.5
],
[
0,
0,
1
]
],
"distortion": [
0.2,
0.01,
0,
0,
0
],
"image": [
[
0,
2,
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30
],
[
1,
3,
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31
],
[
2,
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32
],
[
3,
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33
],
[
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34
],
[
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35
],
[
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36
],
[
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37
],
[
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38
],
[
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39
],
[
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40
],
[
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41
],
[
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40,
42
],
[
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
43
],
[
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40,
42,
44
],
[
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
43,
45
]
],
"image_points": [
[
4.089635,
0.052715
],
[
15.28601,
1.247651
],
[
13.939933,
12.229251
],
[
3.055042,
11.534801
],
[
4.17277,
5.477471
],
[
11.507841,
7.529774
],
[
8.221936,
0.786991
],
[
11.242104,
10.102808
]
],
"object_points": [
[
-0.1,
-0.1,
0
],
[
0.1,
-0.1,
0
],
[
0.1,
0.1,
0
],
[
-0.1,
0.1,
0
],
[
-0.08,
0,
0.1
],
[
0.1,
0.04,
0.2
],
[
0,
-0.1,
0.15
],
[
0.07,
0.08,
0.09
]
]
}),
});
console.log(res.status, await res.text());Python: pay and call
# pip install "x402[requests,evm]"
import os
from eth_account import Account
from x402 import x402ClientSync
from x402.http.clients import x402_requests
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact.register import register_exact_evm_client
# Pays at most $0.0035 per call.
client = x402ClientSync().set_spend_controls({"max_amount_per_payment": "$0.0035"})
register_exact_evm_client(client, EthAccountSigner(Account.from_key(os.environ["EVM_PRIVATE_KEY"])))
with x402_requests(client) as session:
res = session.post(
"https://medien.halowerk.com/v1/oss-opencv-lens-undistort-camera-pose",
json={
"camera_matrix": [
[
45,
0,
7.5,
],
[
0,
45,
7.5,
],
[
0,
0,
1,
],
],
"distortion": [
0.2,
0.01,
0,
0,
0,
],
"image": [
[
0,
2,
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
],
[
1,
3,
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
],
[
2,
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
],
[
3,
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
],
[
4,
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
],
[
5,
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
],
[
6,
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
],
[
7,
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
],
[
8,
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
],
[
9,
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
],
[
10,
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40,
],
[
11,
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
],
[
12,
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40,
42,
],
[
13,
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
43,
],
[
14,
16,
18,
20,
22,
24,
26,
28,
30,
32,
34,
36,
38,
40,
42,
44,
],
[
15,
17,
19,
21,
23,
25,
27,
29,
31,
33,
35,
37,
39,
41,
43,
45,
],
],
"image_points": [
[
4.089635,
0.052715,
],
[
15.28601,
1.247651,
],
[
13.939933,
12.229251,
],
[
3.055042,
11.534801,
],
[
4.17277,
5.477471,
],
[
11.507841,
7.529774,
],
[
8.221936,
0.786991,
],
[
11.242104,
10.102808,
],
],
"object_points": [
[
-0.1,
-0.1,
0,
],
[
0.1,
-0.1,
0,
],
[
0.1,
0.1,
0,
],
[
-0.1,
0.1,
0,
],
[
-0.08,
0,
0.1,
],
[
0.1,
0.04,
0.2,
],
[
0,
-0.1,
0.15,
],
[
0.07,
0.08,
0.09,
],
],
},
)
print(res.status_code, res.text)Security scan
No findings
We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 8 h ago | Passed | 402 | 124 ms | $0.0035 |
| 17 h ago | Passed | 402 | 130 ms | $0.0035 |
| 28 h ago | Passed | 402 | 176 ms | $0.0035 |
| 44 h ago | Timed out | - | - | - |
| 4 days ago | Timed out | - | - | - |
Show 8 older checks
| 5 days ago | Passed | 402 | 170 ms | $0.0035 |
| 5 days ago | Passed | 402 | 151 ms | $0.0035 |
| 6 days ago | Passed | 402 | 124 ms | $0.0035 |
| 6 days ago | Passed | 402 | 163 ms | $0.0035 |
| 7 days ago | Passed | 402 | 120 ms | $0.0035 |
| 7 days ago | Passed | 402 | 146 ms | $0.0035 |
| 7 days ago | Passed | 402 | 128 ms | $0.0035 |
| 8 days ago | Passed | 402 | 120 ms | $0.0035 |